Page 1 of 2 12 LastLast
Results 1 to 20 of 39

Thread: Qwt-6.0.0-rc1

  1. #1
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Qwt-6.0.0-rc1

    Hi all,

    I have uploaded the first release candidate of Qwt 6.0.0 to
    https://sourceforge.net/project/admi...group_id=13693. See the
    qwt-beta section.

    The main intention of this release candidate is to check whether it compiles
    and builds in the various environments. Like always my tests were with gcc +
    Linux/X11 only.

    Beside building the examples I would be interested in tests of qwt.prf - the
    configuration features file of Qwt. When it is properly installed (make
    install) and can be seen ( http://doc.qt.nokia.com/4.7/qmake-ad...ation-features ) by qmake it you should be enough to write "CONFIG += qwt" in your application qmake project file.

    Because there are already several applications using Qwt from SVN trunk most
    new classes are already tested to a certain level - beside the changes to the
    raster item classes ( f.e spectrogram ), that have been implemented recently.
    I would be interested in some feedback in this area ( particularly about
    QwtMatrixRasterData ).

    Qwt 6.0 is intended to support Qt versions >= Qt 4.4.

    Uwe

  2. The following user says thank you to Uwe for this useful post:

    sonulohani (24th May 2012)

  3. #2
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Here are my experiences (Mac OS X 10.6, Qt 4.7):

    1. for me, the link you posted does not work (permission denied)

    2. if I compile the package as is (without modification of any of the files) I get linker errors:


    linking plugins/designer/libqwt_designer_plugin.dylib
    ld: warning: directory '/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib' following -L not found
    ld: warning: directory '/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib' following -F not found
    ld: framework not found qwt
    collect2: ld returned 1 exit status
    make[1]: *** [plugins/designer/libqwt_designer_plugin.dylib] Error 1
    make: *** [sub-designer-make_default-ordered] Error 2


    Deactivating the compilation of the examples and the Designer plugins solves the issue.

    3. only debug libraries are built. Is this the intended behaviour?

  4. #3
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Thanks for testing.

    Quote Originally Posted by mariposa View Post
    1. for me, the link you posted does not work (permission denied)
    Right, this one should be better: http://sourceforge.net/projects/qwt/
    Quote Originally Posted by mariposa View Post
    2. if I compile the package as is (without modification of any of the files) I get linker errors:
    Please tell me the reason for the bad linker command - I don't have a Mac.
    Quote Originally Posted by mariposa View Post
    3. only debug libraries are built. Is this the intended behaviour?
    Ah no - this is a bug in my package build script. Only release libraries should be built on the Mac.

    Uwe

  5. #4
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    Please tell me the reason for the bad linker command - I don't have a Mac.
    I'm afraid, I never had to debug such linker problems, therefore I am not sure how to find the reason. Would you tell me what to do?

  6. #5
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    This is no linker problem - it's a problem of the linker command in the Makefile, that is generated by qmake. So you need to fine out which line in the qwt project files are responsible for the bad linker options.

    I guess you have to check "qtAddLibrary", that is implemented in <qtdir>/mkspecs/features/qt_functions.prf.

    Uwe

  7. #6
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    This is no linker problem - it's a problem of the linker command in the Makefile, that is generated by qmake. So you need to fine out which line in the qwt project files are responsible for the bad linker options.
    After some investigation I think I have found the problem. On Mac OS X, the linker is looking for the qwt libraries in /Libary/Frameworks/qwt.framework/, and with the current build configuration, no such framework is created. I managed to successfully compile the designer plugin and examples by doing the following:

    First, I deactivated the compilation of examples and plugin and added the following line to the src.pro file:
    Qt Code:
    1. CONFIG += lib_bundle
    To copy to clipboard, switch view to plain text mode 

    This activates the creation of the needed framework. Now I compiled and installed as usual. Now the framework folder is in /usr/local/qwt-6.0.0-rc1/lib/qwt.framework/.

    I moved the folder to /Library/Frameworks and recompiled qwt, but now with examples and designer plugin activated. Now everything compiled without errors.

    But, unfortunately, I have not yet found a solution on how to make the linker search for the framework in the build directory, since at compile-time the framework cannot be where the linker expects it.

    PS: Of course directly specifying the location of the library (LIBS +=) would also solve the problem.

  8. #7
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by mariposa View Post
    PS: Of course directly specifying the location of the library (LIBS +=) would also solve the problem.
    You find "LIBS += " lines in examples.pri ( for building the examples ) and designer.pro ( for the designer ). When building an application against an installed Qwt package - by adding "CONFIG += qwt" - qwt.prf is included, where you also find a "LIBS *= ..." line.

    Why do these lines result in an empty -L and -F linker option in your Makefile ?

    Uwe

  9. #8
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    Why do these lines result in an empty -L and -F linker option in your Makefile ?
    I am not sure, at first glance, it should work. I tried the following: After commenting out "qtAddLibrary(qwt)" in examples.pri and designer.pro and chnaging the LIBS line to "LIBS += -L$${QWT_ROOT}/lib -lqwt" (in both files) everything compiles fine.

  10. #9
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Manually adding linker commands for all types of platforms and debug/release combinations is what I did in Qwt 5. Fortunately in Qt4 this is not necessary anymore because of qtAddLibrary.

    Please look into the implementation of qtAddLibrary ( in qt_functions.prf ) and check why it doesn't work in your environment.

    Uwe

  11. #10
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    Please look into the implementation of qtAddLibrary ( in qt_functions.prf ) and check why it doesn't work in your environment.
    I'm trying to understand the code of the qt_functions.prf file, but since I'm very new to programming, this is not that easily done. But I hope that I can work it out.

  12. #11
    Join Date
    Oct 2010
    Posts
    12
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qwt-6.0.0-rc1

    My experience was very good. ( Windows 7, msvc2005, Qt 4.7.0)

    Built and installed with no problems. In case I did not build and install in normal manner, this is what I did:

    1. Set my QWT_INSTALL_PREFIX in qwtconfig.pri to the location I installed Qt 4.7.0. I did not change anything else.

    2. Ran the following sequence from Visual Studio 2005 Command Prompt:
    qmake -recursive qwt.pro
    nmake
    nmake install


    3. Manually copied qwt.dll from the lib directory of my install location to the bin directory.


    Ran QtDesigner, and qwtPlot widgets appearred correctly in the designer. Ran some examples made during the build, and they ran fine.

    So, all in all, it was the simplest build and install I've ever had.

    Cheers

  13. #12
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    Please look into the implementation of qtAddLibrary ( in qt_functions.prf ) and check why it doesn't work in your environment.
    I did not completely understand every detail that happens in the qtAddLibrary function, but I think I found out what causes the problem:

    Qt Code:
    1. INCLUDEPATH -= $$QMAKE_INCDIR_QT/$$1
    2. INCLUDEPATH = $$QMAKE_INCDIR_QT/$$1 $$INCLUDEPATH
    3.  
    4. LIB_NAME = $$1
    5. unset(LINKAGE)
    6.  
    7.  
    8. mac {
    9. CONFIG(qt_framework, qt_framework|qt_no_framework) { #forced
    10. QMAKE_FRAMEWORKPATH *= $${QMAKE_LIBDIR_QT}
    11. FRAMEWORK_INCLUDE = $$QMAKE_LIBDIR_QT/$${LIB_NAME}.framework/Headers
    12. !qt_no_framework_direct_includes:exists($$FRAMEWORK_INCLUDE) {
    13. INCLUDEPATH -= $$FRAMEWORK_INCLUDE
    14. INCLUDEPATH = $$FRAMEWORK_INCLUDE $$INCLUDEPATH
    15. }
    16. LINKAGE = -framework $${LIB_NAME}$${QT_LIBINFIX}
    17. } else:!qt_no_framework { #detection
    18. for(frmwrk_dir, $$list($$QMAKE_LIBDIR_QT $$QMAKE_LIBDIR $$(DYLD_FRAMEWORK_PATH) /Library/F$
    19. exists($${frmwrk_dir}/$${LIB_NAME}.framework) {
    20. QMAKE_FRAMEWORKPATH *= $${frmwrk_dir}
    21. FRAMEWORK_INCLUDE = $$frmwrk_dir/$${LIB_NAME}.framework/Headers
    22. !qt_no_framework_direct_includes:exists($$FRAMEWORK_INCLUDE) {
    23. INCLUDEPATH -= $$FRAMEWORK_INCLUDE
    24. INCLUDEPATH = $$FRAMEWORK_INCLUDE $$INCLUDEPATH
    25. }
    26. LINKAGE = -framework $${LIB_NAME}
    27. break()
    28. }
    29. }
    30. }
    31. }
    To copy to clipboard, switch view to plain text mode 

    The variable $$1 gets the value "qwt" and this is written into the variable LIB_NAME.

    In every outcome for "mac" the LINKAGE option "-framework qwt" is thereofore added as compiler option. This causes the linker to look for the folder "qwt.framework" in the $$QMAKE_LIBDIR_QT and this is simply not present. Therefore the linking stops with the corresponding error.

    But unfortunately I see no way in specifying a "custom" place (namely ../lib) to look for the framework. It seems to be the intention of this function to look in the system framework directory for the specified framework. All options that are set using the "LIBS" variable are not considered for the addition of the "-framework" flag.

    But (as I already said) my experince is negligible and therefore my "analysis" of the error might be totally wrong.

  14. #13
    Join Date
    Mar 2010
    Posts
    77
    Thanks
    17
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Hello!
    Just like gedrite I'm on Win7 but I'm using the SDK-install of Qt.

    I've managed to build qwt 6 using both nmake and mingw. Either way I'm able to compile and run the examples from Qt Creator but in neither case am I able to get the widgets to show up in the Creator (Form Editor) area for drag-and-drop-placing.
    Qwt is not listed at all in the Help->About plugins-menu.

    I've put the qwt_designer_plugin-files in the Qt\2010.05\bin\designer-folder but nothing shows up in Creator/Designer.

    What might be wrong?

    Cheers!
    /Tottish

  15. #14
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by mariposa View Post
    But unfortunately I see no way in specifying a "custom" place (namely ../lib) to look for the framework. It seems to be the intention of this function to look in the system framework directory for the specified framework. All options that are set using the "LIBS" variable are not considered for the addition of the "-framework" flag.
    Doesn't qtAddLibrary iterate over the path stored in the environment variable DYLD_FRAMEWORK_PATH ? Also manually setting "QMAKE_FRAMEWORKPATH *= ..." might help.

    But back to your initial posting: when you don't set "CONFIG += lib_bundle" and also remove "CONFIG += silent" from qwtbuild.pri - how does the failing linker command look like ?

    Uwe

  16. #15
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    But back to your initial posting: when you don't set "CONFIG += lib_bundle" and also remove "CONFIG += silent" from qwtbuild.pri - how does the failing linker command look like ?
    The failing command is the following:

    Qt Code:
    1. g++ -headerpad_max_install_names -single_module -dynamiclib -o libqwt_designer_plugin.dylib debug/qwt_designer_plugin.o debug/qwt_designer_plotdialog.o debug/moc_qwt_designer_plugin.o debug/moc_qwt_designer_plotdialog.o debug/qrc_qwt_designer_plugin.o -F/Library/Frameworks -L/Library/Frameworks -L../lib -framework qwt -L/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib -F/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib -framework QtDesigner -framework QtScript -framework QtXml -framework QtGui -framework QtCore
    2. ld: framework not found qwt
    3. collect2: ld returned 1 exit status
    4. make[2]: *** [plugins/designer/libqwt_designer_plugin.dylib] Error 1
    5. make[1]: *** [debug-all] Error 2
    6. make: *** [sub-designer-make_default-ordered] Error 2
    To copy to clipboard, switch view to plain text mode 

  17. #16
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    As far as I understand ( without knowing much about frameworks on the Mac ) the commands generated by qtAddLibrary depend on the qmake variable qt_framework. ( Guess whether it is enabled depends on how Qt had been built. )

    So the first thing should be to add the following to src.pro:

    Qt Code:
    1. CONFIG(qt_framework, qt_framework|qt_no_framework) {
    2.  
    3. CONFIG += lib_bundle
    4. }
    To copy to clipboard, switch view to plain text mode 

    But what has to be in this bundle ? Could you check what changes, when you use the following sequence:

    Qt Code:
    1. CONFIG(qt_framework, qt_framework|qt_no_framework) {
    2.  
    3. CONFIG += lib_bundle
    4.  
    5. FRAMEWORK_HEADERS.version = Versions
    6. FRAMEWORK_HEADERS.files = $${HEADERS}
    7. FRAMEWORK_HEADERS.path = Headers
    8. QMAKE_BUNDLE_DATA += FRAMEWORK_HEADERS
    9. }
    To copy to clipboard, switch view to plain text mode 

    What has happened after you have build the qwt library ( in src ) and what is installed where, when you do "make install" then ?

    Uwe

    PS: Is nobody out there knowing about Mac frameworks and qmake ?

  18. #17
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    What has happened after you have build the qwt library ( in src ) and what is installed where, when you do "make install" then ?


    My investigation has led to the following results:

    (just to mention: to make it compile I disabled the designer_plugin and the examples, furthermore I added the release libraries to the config since they are not built by default; I didn't change anything else)

    If you add "lib_bundle" to the config (as in your posted code), then in the lib-directory a folder "qwt.framework" is created which is copied to "/usr/local/qwt-6.0.0-rc1/lib" by the install script. The folder contains the files depicted in this screenshot:

    with_lib_bundle.png

    By the way: the folder is absolutely identical if the variable declarations after "CONFIG += lib_bundle" (in your post) are omitted. The values of these variables already seem to be appropriately set.

    If you do not specifiy the lib_bundle option, no "qwt.framework" folder is created and the "/usr/local/qwt-6.0.0-rc1/lib" folder looks the following:

    without_lib_bundle.png

    The rest of the "/usr/local/qwt-6.0.0-rc1/" folder is identical no matter if "lib_bundle" is set or not. It contains the subfolders "docs" "features" "include" (with all header files) and the already mentioned "lib" folder.

    So the framework-folder basically contains the release and debug library and "Headers" file which is a symlink to "Versions/6/Headers" (a folder that does not exist).

    PS: The qwt.framework-folder seems to be "okay" that way, because if I move it manually to "/Library/Frameworks", the linking no longer fails.

  19. #18
    Join Date
    Oct 2010
    Posts
    12
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Tottish View Post
    Hello!
    ....
    Qwt is not listed at all in the Help->About plugins-menu.

    I've put the qwt_designer_plugin-files in the Qt\2010.05\bin\designer-folder but nothing shows up in Creator/Designer.
    ....

    /Tottish
    My plugin does not listed in Help->About Plugins either. However, in Tools->FormEditor->About Qt Designer Plugins, the qwt plugin does show up as being installed. You should look there to see if it lists the dll at all.

    My qwt_designer_plugin.dll appears in my QtCreator-2.0.1/bin/designer directory, which should be equivalent to your location, so I'm not sure why yours does not show up, as mine shows up fine.

    I'm reading elsewhere where people, in a general sense, are having problems when the plugin dll's are built in mingw whereas the QtCreator is built with visual studio, and vice-versa, so perhaps make sure both are built with the same tool chain.

    Good luck.

  20. #19
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,309
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by mariposa View Post
    If you add "lib_bundle" to the config (as in your posted code), then in the lib-directory a folder "qwt.framework" is created which is copied to "/usr/local/qwt-6.0.0-rc1/lib" by the install script.
    What about "/usr/local/qwt-6.0.0-rc1/include" - I hope installing the headers there too is omitted in case of "lib_bundle" ?

    Quote Originally Posted by mariposa View Post
    The qwt.framework folder seems to be "okay" that way, because if I move it manually to "/Library/Frameworks", the linking no longer fails.
    O.k. - when you don't move the qwt.framework folder how can you build against it ?

    Qwt 6 supports qmake features, what means that a couple of qwt specific settings are loaded from a file qwt.prf, when you add "CONFIG += qwt" to your application qmake project file. But before building your application Makefiles you have to configure qmake, so that it can find qwt.prf in /usr/local/qwt-6.0.0-rc1. ( See http://doc.qt.nokia.com/4.7/qmake-ad...ation-features ).

    What happens, when you use the following qwt.prf ?

    Qt Code:
    1. include ( ./qwtconfig.pri )
    2.  
    3. QMAKE_FRAMEWORKPATH *= $${QWT_INSTALL_PREFIX}
    4. qtAddLibrary(qwt)
    To copy to clipboard, switch view to plain text mode 

    Beside QMAKE_FRAMEWORKPATH qtAddLibrary(qwt) also checks the DYLD_FRAMEWORK_PATH environment variable. By setting it qmake should be able to find a framework folder at any other place too:

    Qt Code:
    1. export DYLD_FRAMEWORK_PATH=...
    2. qmake
    To copy to clipboard, switch view to plain text mode 

    Uwe

  21. #20
    Join Date
    Sep 2010
    Posts
    35
    Thanks
    5
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qwt-6.0.0-rc1

    Quote Originally Posted by Uwe View Post
    What about "/usr/local/qwt-6.0.0-rc1/include" - I hope installing the headers there too is omitted in case of "lib_bundle" ?
    No, the headers are always in "/usr/local/qwt-6.0.0-rc1/include", even if lib_bundle is set.

    Quote Originally Posted by Uwe View Post
    O.k. - when you don't move the qwt.framework folder how can you build against it ?
    I think one would have to specify the location of the framework with the -F option.

    Quote Originally Posted by Uwe View Post
    What happens, when you use the following qwt.prf ?
    I added the line "QMAKE_FRAMEWORKPATH *= $${QWT_INSTALL_PREFIX}" to the qwt.prf but the very same error (framework not found) persists. But this should not be unusual since at compile time, the framework is not yet installed in $${QWT_INSTALL_PREFIX}.

    I also tried exporting the DYLD_FRAMEWORK_PATH variable with the path to the lib-folder, but it did not work either.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.