[Gammaray-interest] Qt Internals problem
Kevin Funk
kevin.funk at kdab.com
Tue Oct 29 14:02:37 CET 2013
On Tuesday 29 October 2013, 11:54, Stefano Cordibella wrote:
> Hi Kevin,
> I remove the build directory and recreate it, I change shell in
> order to use a clean $PATH var.
> I export the directory:
> export PATH=/home/juba/Qt/qt-everywhere-opensource-src-4.8.4/bin:$PATH
Hey again,
Are you really doing an in-source build? Build and source directory are equal
in this case. This is required at the moment to be able to enable the private-
header feature in GammaRay.
> I am sure that the only qmake found in my path is the rigth one, because
> before the export command no qmake was found using the shell completion.
>
> I run CMake, but the result was the same:
> -- The C compiler identification is GNU
> -- The CXX compiler identification is GNU
> -- Check for working C compiler: /usr/bin/gcc
> -- Check for working C compiler: /usr/bin/gcc -- works
> -- Detecting C compiler ABI info
> -- Detecting C compiler ABI info - done
> -- Check for working CXX compiler: /usr/bin/c++
> -- Check for working CXX compiler: /usr/bin/c++ -- works
> -- Detecting CXX compiler ABI info
> -- Detecting CXX compiler ABI info - done
> -- Building GammaRay 1.3.2 in Release mode
> -- Looking for Q_WS_X11
> -- Looking for Q_WS_X11 - found
> -- Looking for Q_WS_WIN
> -- Looking for Q_WS_WIN - not found.
> -- Looking for Q_WS_QWS
> -- Looking for Q_WS_QWS - not found.
> -- Looking for Q_WS_MAC
> -- Looking for Q_WS_MAC - not found.
> -- Found Qt4: /home/juba/Qt/qt-everywhere-opensource-src-4.8.4/bin/qmake
> (found suitable version "4.8.4", required is "4.7.0")
> -- Looking for clock_gettime in rt
> -- Looking for clock_gettime in rt - found
> -- Looking for include files HAVE_STDINT_H
> -- Looking for include files HAVE_STDINT_H - found
> -- Performing Test HAVE_GCC_UNUSED_BUT_SET
> -- Performing Test HAVE_GCC_UNUSED_BUT_SET - Success
> -- Performing Test HAVE_GCC_LOGICAL_OP
> -- Performing Test HAVE_GCC_LOGICAL_OP - Success
> -- Looking for include files HAVE_GRAPHVIZ_VERSION_H
> -- Looking for include files HAVE_GRAPHVIZ_VERSION_H - found
> -- Found Graphviz version 2.26.3
> -- Found Graphviz: /usr/lib/libcdt.so /usr/lib/libgvc.so
> /usr/lib/libcgraph.so /usr/lib/libgraph.so /usr/lib/libpathplan.so
>
> ----------------------------------------------------------------------------
> - -- The following external packages were located on your system.
> -- This installation will have the extra features provided by these
> packages.
> ----------------------------------------------------------------------------
> - * Script engine debugger in Qt - A debugger for QtScript
> * WebKit in Qt - A Qt-based web browser engine
> * Qt SVG - Qt SVG renderer and generator
> * Qt Designer Library - Qt graphical widget editor
> * Qt Print Support - Qt PDF generation
> * librt - High resolution clock for the timer profiler plugin.
> * Graphviz - Graph visualization software
> * VTK - Visualization Toolkit
>
> ----------------------------------------------------------------------------
> - -- The following OPTIONAL packages could NOT be located on your system. --
> Consider installing them to enable more features from this software.
> ---------------------------------------------------------------------------
> -- * Qt internals (4.7.0 or higher) <http://developer.qt.nokia.com/> Private
> Qt headers, necessary for painter debugging/profiling. You must have a
> build version of Qt available. Make sure the qmake found first in your
> execute comes from this build version.
> * KDE4 <http://www.kde.org/>
> KDE libraries
> Required for the KJob tracker plug-in
>
> ----------------------------------------------------------------------------
> -
>
> -- Configuring done
> -- Generating done
> -- Build files have been written to: /home/juba/Qt/GammaRay-1.3.2/build
>
> As before I set the QT_PRIVATE_INCLUDE_DIR to:
> /home/juba/Qt/qt-everywhere-opensource-src-4.8.4/include/QtCore
> using make edit_cache. Note that I must double configure ("c") and then
> I can generate makefiles, but I don't know why.
You don't need to, even shouldn't set this variable manually.
I just successfully build GammaRay with the private-header feature enabled.
All I had to do was the following:
* Build Qt4 in-source with './configure -developer-build' (let's say in ~/foo)
* Add ~/foo/bin to PATH
* Then just configure (no extra parameters needed) and build GammaRay
That's about it,
Greets
> Unfortunately as before I have the same error (now I report the long
> output build, so you can check if all the targets are right):
> juba at Jell:~/Qt/GammaRay-1.3.2/build$ make
> Scanning dependencies of target man
> [ 0%] Generating gammaray.1
> [ 0%] Built target man
> [ 1%] Generating qrc_gammaray.cxx
> [ 1%] Generating krecursivefilterproxymodel.moc
> [ 2%] Generating kfilterproxysearchline.moc
> [ 2%] Generating resourcemodel.moc
> [ 2%] Generating aboutpluginsdialog.moc
> [ 3%] Generating mainwindow.moc
> [ 3%] Generating metaobjecttreemodel.moc
> [ 3%] Generating metapropertymodel.moc
> [ 4%] Generating probe.moc
> [ 4%] Generating proxydetacher.moc
> [ 4%] Generating objectlistmodel.moc
> [ 5%] Generating objectpropertymodel.moc
> [ 5%] Generating objectdynamicpropertymodel.moc
> [ 5%] Generating objectstaticpropertymodel.moc
> [ 6%] Generating objecttreemodel.moc
> [ 6%] Generating connectionmodel.moc
> [ 6%] Generating connectionfilterproxymodel.moc
> [ 7%] Generating methodinvocationdialog.moc
> [ 7%] Generating methodargumentmodel.moc
> [ 7%] Generating multisignalmapper.moc
> [ 8%] Generating toolmodel.moc
> [ 8%] Generating proxytoolfactory.moc
> [ 8%] Generating sidepane.moc
> [ 9%] Generating palettemodel.moc
> [ 9%] Generating propertywidget.moc
> [ 9%] Generating propertycoloreditor.moc
> [ 10%] Generating propertydoublepaireditor.moc
> [ 10%] Generating propertyextendededitor.moc
> [ 10%] Generating propertyfonteditor.moc
> [ 11%] Generating propertyintpaireditor.moc
> [ 11%] Generating propertypaletteeditor.moc
> [ 11%] Generating palettedialog.moc
> [ 12%] Generating modeltester.moc
> [ 12%] Generating modeltest.moc
> [ 12%] Generating modelmodel.moc
> [ 13%] Generating modelcellmodel.moc
> [ 13%] Generating graphicsview.moc
> [ 13%] Generating graphicssceneview.moc
> [ 14%] Generating scenemodel.moc
> [ 14%] Generating metatypesmodel.moc
> [ 15%] Generating fontmodel.moc
> [ 15%] Generating localemodel.moc
> [ 15%] Generating localedataaccessor.moc
> [ 16%] Generating localeaccessormodel.moc
> [ 16%] Generating codecmodel.moc
> [ 16%] Generating textdocumentmodel.moc
> [ 17%] Generating textdocumentformatmodel.moc
> [ 17%] Generating textdocumentcontentview.moc
> [ 17%] Generating messagehandler.moc
> [ 18%] Generating messagemodel.moc
> [ 18%] Generating codecbrowser.moc
> [ 18%] Generating connectioninspector.moc
> [ 19%] Generating fontbrowser.moc
> [ 19%] Generating localeinspector.moc
> [ 19%] Generating metaobjectbrowser.moc
> [ 20%] Generating metatypebrowser.moc
> [ 20%] Generating modelinspector.moc
> [ 20%] Generating modelinspectorwidget.moc
> [ 21%] Generating objectinspector.moc
> [ 21%] Generating resourcebrowser.moc
> [ 21%] Generating resourcefiltermodel.moc
> [ 22%] Generating sceneinspector.moc
> [ 22%] Generating selectionmodelinspector.moc
> [ 22%] Generating textdocumentinspector.moc
> [ 23%] Generating widgetinspector.moc
> [ 23%] Generating overlaywidget.moc
> [ 23%] Generating widgettreemodel.moc
> [ 24%] Generating widgetpreviewwidget.moc
> [ 24%] Generating styleinspector.moc
> [ 24%] Generating pixelmetricmodel.moc
> [ 25%] Generating standardiconmodel.moc
> [ 25%] Generating primitivemodel.moc
> [ 25%] Generating controlmodel.moc
> [ 26%] Generating abstractstyleelementmodel.moc
> [ 26%] Generating abstractstyleelementstatetable.moc
> [ 26%] Generating styleelementstatetablepage.moc
> [ 27%] Generating complexcontrolmodel.moc
> [ 27%] Generating dynamicproxystyle.moc
> [ 27%] Generating paintbuffermodel.moc
> [ 28%] Generating paintbufferviewer.moc
> [ 28%] Generating paintbufferreplaywidget.moc
> [ 28%] Generating ui_mainwindow.h
> [ 29%] Generating ui_propertywidget.h
> [ 29%] Generating ui_methodinvocationdialog.h
> [ 29%] Generating ui_paintbufferviewer.h
> [ 30%] Generating ui_propertydoublepaireditor.h
> [ 30%] Generating ui_propertyextendededitor.h
> [ 30%] Generating ui_propertyintpaireditor.h
> [ 31%] Generating ui_palettedialog.h
> [ 31%] Generating ui_graphicssceneview.h
> [ 32%] Generating ui_codecbrowser.h
> [ 32%] Generating ui_connectioninspector.h
> [ 32%] Generating ui_fontbrowser.h
> [ 33%] Generating ui_localeinspector.h
> [ 33%] Generating ui_messagehandler.h
> [ 33%] Generating ui_metatypebrowser.h
> [ 34%] Generating ui_modelinspectorwidget.h
> [ 34%] Generating ui_objectinspector.h
> [ 34%] Generating ui_resourcebrowser.h
> [ 35%] Generating ui_sceneinspector.h
> [ 35%] Generating ui_selectionmodelinspector.h
> [ 35%] Generating ui_styleinspector.h
> [ 36%] Generating ui_textdocumentinspector.h
> [ 36%] Generating ui_widgetinspector.h
> [ 36%] Generating ui_styleelementstatetablepage.h
> Scanning dependencies of target gammaray_probe
> [ 36%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/__/3rdparty/kde/krecursivefilterproxymode
> l.cpp.o [ 36%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/__/3rdparty/kde/kfilterproxysearchline.cp
> p.o [ 37%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/__/3rdparty/qt/resourcemodel.cpp.o
> [ 37%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/__/3rdparty/other/modelutils.cpp.o
> [ 37%] Building CXX object core/CMakeFiles/gammaray_probe.dir/util.cpp.o
> [ 38%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/aboutpluginsdialog.cpp.o
> [ 38%] Building CXX object
> core/CMakeFiles/gammaray_probe.dir/mainwindow.cpp.o
> /home/juba/Qt/GammaRay-1.3.2/core/mainwindow.cpp:38:68: fatal error:
> private/qguiplatformplugin_p.h: No such file or directory
> compilation terminated.
> make[2]: *** [core/CMakeFiles/gammaray_probe.dir/mainwindow.cpp.o] Error 1
> make[1]: *** [core/CMakeFiles/gammaray_probe.dir/all] Error 2
> make: *** [all] Error 2
>
> That's all for now, I think I will be forced to use the GammaRay without
> the Qt Internals support for now...
>
> Stefano.
>
> On 10/29/2013 11:21 AM, Kevin Funk wrote:
> > On Tuesday 29 October 2013, 11:14, Stefano Cordibella wrote:
> >> Thank you Kevin for your quick answer!
> >>
> >> In my environment I am unable to auto-detect QT_PRIVATE_INCLUDE_DIR.
> >>
> >> I export qmake bin dir in this way:
> >> export PATH=/usr/local/Trolltech/Qt-4.8.4/bin:$PATH
> >
> > Hey,
> >
> > You need to have 'qmake' from the build directory in your PATH. Then the
> > private-header check in CMake should succeed.
> >
> > See the help text during the CMake run:
> > "Make sure the qmake found first in your execute comes from this build
> > version".
> >
> >> But CMake told me :
> >> -- The C compiler identification is GNU
> >> -- The CXX compiler identification is GNU
> >> -- Check for working C compiler: /usr/bin/gcc
> >> -- Check for working C compiler: /usr/bin/gcc -- works
> >> -- Detecting C compiler ABI info
> >> -- Detecting C compiler ABI info - done
> >> -- Check for working CXX compiler: /usr/bin/c++
> >> -- Check for working CXX compiler: /usr/bin/c++ -- works
> >> -- Detecting CXX compiler ABI info
> >> -- Detecting CXX compiler ABI info - done
> >> -- Building GammaRay 1.3.2 in Release mode
> >> -- Looking for Q_WS_X11
> >> -- Looking for Q_WS_X11 - found
> >> -- Looking for Q_WS_WIN
> >> -- Looking for Q_WS_WIN - not found.
> >> -- Looking for Q_WS_QWS
> >> -- Looking for Q_WS_QWS - not found.
> >> -- Looking for Q_WS_MAC
> >> -- Looking for Q_WS_MAC - not found.
> >> -- Found Qt4: /usr/local/Trolltech/Qt-4.8.4/bin/qmake (found suitable
> >> version "4.8.4", required is "4.7.0")
> >> -- Looking for clock_gettime in rt
> >> -- Looking for clock_gettime in rt - found
> >> -- Looking for include files HAVE_STDINT_H
> >> -- Looking for include files HAVE_STDINT_H - found
> >> -- Performing Test HAVE_GCC_UNUSED_BUT_SET
> >> -- Performing Test HAVE_GCC_UNUSED_BUT_SET - Success
> >> -- Performing Test HAVE_GCC_LOGICAL_OP
> >> -- Performing Test HAVE_GCC_LOGICAL_OP - Success
> >> -- Looking for include files HAVE_GRAPHVIZ_VERSION_H
> >> -- Looking for include files HAVE_GRAPHVIZ_VERSION_H - found
> >> -- Found Graphviz version 2.26.3
> >> -- Found Graphviz: /usr/lib/libcdt.so /usr/lib/libgvc.so
> >> /usr/lib/libcgraph.so /usr/lib/libgraph.so /usr/lib/libpathplan.so
> >>
> >> -------------------------------------------------------------------------
> >> --- - -- The following external packages were located on your system.
> >> -- This installation will have the extra features provided by these
> >> packages.
> >> -------------------------------------------------------------------------
> >> --- - * Script engine debugger in Qt - A debugger for QtScript
> >>
> >> * WebKit in Qt - A Qt-based web browser engine
> >> * Qt SVG - Qt SVG renderer and generator
> >> * Qt Designer Library - Qt graphical widget editor
> >> * Qt Print Support - Qt PDF generation
> >> * librt - High resolution clock for the timer profiler plugin.
> >> * Graphviz - Graph visualization software
> >> * VTK - Visualization Toolkit
> >>
> >> -------------------------------------------------------------------------
> >> --- - -- The following OPTIONAL packages could NOT be located on your
> >> system. -- Consider installing them to enable more features from this
> >> software.
> >> ------------------------------------------------------------------------
> >> --- -- * Qt internals (4.7.0 or higher) <http://developer.qt.nokia.com/>
> >> Private Qt headers, necessary for painter debugging/profiling. You must
> >> have a build version of Qt available. Make sure the qmake found first in
> >> your execute comes from this build version.
> >>
> >> * KDE4 <http://www.kde.org/>
> >>
> >> KDE libraries
> >> Required for the KJob tracker plug-in
> >>
> >> -------------------------------------------------------------------------
> >> --- -
> >>
> >> -- Configuring done
> >> -- Generating done
> >> -- Build files have been written to: /home/juba/Qt/GammaRay-1.3.2/build
> >>
> >> So I try to set the QT_PRIVATE_INCLUDE_DIR manually via make edit_cache:
> >> /home/juba/Qt/qt-everywhere-opensource-src-4.8.4/include/QtCore
> >>
> >> After this the HARFBUZZ_INCLUDE_DIR become set to:
> >> /home/juba/Qt/qt-everywhere-opensource-src-4.8.4/src/3rdparty/harfbuzz/sr
> >> c
> >>
> >> After this setting I generate the Makefiles, but the build doesn't
> >> complete...
> >> The reported error is:
> >> [ 38%] Building CXX object
> >> core/CMakeFiles/gammaray_probe.dir/mainwindow.cpp.o
> >> /home/juba/Qt/GammaRay-1.3.2/core/mainwindow.cpp:38:68: fatal error:
> >> private/qguiplatformplugin_p.h: No such file or directory
> >> compilation terminated.
> >> make[2]: *** [core/CMakeFiles/gammaray_probe.dir/mainwindow.cpp.o] Error
> >> 1
> >> make[1]: *** [core/CMakeFiles/gammaray_probe.dir/all] Error 2
> >> make: *** [all] Error 2
> >
> > Using the other qmake binary probably should solve this already.
> >
> >> So I check the GammaRay root directory and I found the file in
> >> 3rdparty/qt/private/qguiplatformplugin_p.h
> >> The file is also present in
> >> qt-everywhere-opensource-src-4.8.4/src/gui/kernel/qguiplatformplugin_p.h
> >> and
> >> qt-everywhere-opensource-src-4.8.4/include/QtGui/private/qguiplatformplug
> >> in_ p.h, but I haven't diff the content.
> >>
> >> Any idea to fix this build issue?
> >>
> >> (I prefer to use mailing list in order to keep a reference to the
> >> solution of the problem, so other people may track this solution).
> >
> > Perfectly fine, of course.
> >
> > Greets
> >
> >> Stefano.
> >>
> >> On 10/29/2013 09:33 AM, Kevin Funk wrote:
> >>> On Tuesday 29 October 2013, 08:57, Stefano Cordibella wrote:
> >>>> Hi again,
> >>>>
> >>>> I have a question about compiling GammaRay with Qt internals
> >>>>
> >>>> feature enable.
> >>>> What is the directory that I should provide for this feature?
> >>>> I edit the cmake cache and I found an entry named
> >>>> QT_PRIVATE_INCLUDE_DIR
> >>>> but if I set a value for it I am unable to build GammaRay.
> >>>> The documentation refer to the "build" directory of Qt, and I don't
> >>>> understand if it refers to the source directory in which I compile the
> >>>> library (my ~/Qt/qt-everywhere-opensource-src-4.8.4) or the
> >>>> installation
> >>>> directory (the default /usr/local/Throlltech/Qt-4.8.4/).
> >>>>
> >>>> Forgive me for this stupid question, but I am unable to find
> >>>> documentation about this topic...
> >>>>
> >>>> Thanks in advance,
> >>>> Stefano.
> >>>
> >>> Hey Stefano,
> >>>
> >>> unfortunately this is not a stupid question at all. It is a bit tricky
> >>> to
> >>> get right with a Qt4 build at the moment. It's lacking documentation.
> >>>
> >>> So, in order to enable that feature, QT_PRIVATE_INCLUDE_DIR should point
> >>> to
> >>> "$MY_QT4_IN_SOURCE_BUILD_DIRECTORY/include/QtCore". Note that you don't
> >>> have to specify that variable via CMake flags or anything, it's
> >>> auto-detected in case everything is alright.
> >>>
> >>> It's important that you have an *in-source build* of Qt4 (the directory
> >>> must contain both a src/ and include/ directory after having compiled
> >>> Qt)
> >>> -- it's currently not possible to make this work with an out-of-source
> >>> build.
> >>>
> >>> Hope this clears up things a bit. In case you need to debug further,
> >>> have
> >>> a
> >>> look at the root CMakeLists.txt file in GammaRay.git.
> >>>
> >>> Feel free to ping us on #gammaray on Freenode (IRC).
> >>>
> >>> Greets
--
Kevin Funk | kevin.funk at kdab.com | Software Engineer
KDAB (Deutschland) GmbH&Co KG, a KDAB Group company
Tel. Germany +49-30-521325470, Sweden (HQ) +46-563-540090
KDAB - Qt Experts - Platform-independent software solutions
More information about the Gammaray-interest
mailing list