[CMake] Re: CMake 2.4.4 available for download

wedekind wedekind at caesar.de
Wed Nov 22 11:33:31 EST 2006


Hello all,

I guess there has been a change in the interpretation of "optimized" and
"debug" libraries used in the TARGET_LINK_LIBRARIES command.

In 2.4.3 the following line successfully produced a link to the Qt
libraries:

TARGET_LINK_LIBRARIES(JCore optimized ${QT_QT_LIBRARY} debug
${QT_QT_LIBRARY_DEBUG})

It still does on my windows system. But on Unix it links to _both_ libraries
resulting in the following entry to build.make:

---
...
# External object files for target JCore
JCore_EXTERNAL_OBJECTS =
...
framework/JCore/libJCore.so: .../libqt-mt.so
framework/JCore/libJCore.so: .../libqt-mtd.so
framework/JCore/libJCore.so: framework/JCore/CMakeFiles/JCore.dir/build.make
...
---

With cmake 2.4.3 build.make does not even have any line that includes
libqt-mt.so like with 2.4.4 above.

If making the target JCore make issues a warning like this:

... no rule to make target '.../libqt-mtd.so' required by '.../libJCore.so'

What could have caused this wrong behaviour? Can it be fixed quickly? If
not, is there a work-around?

It does link correctly if I do not differentiate between optimized- and
debug-libs like this:

TARGET_LINK_LIBRARIES(JCore ${QT_QT_LIBRARY})

Cheers

Marco




More information about the CMake mailing list