Fixes issues #14812 and #14813 where find_package(OpenMP QUIET) and
find_package(Qt4 QUIET) would still print out messages when calling
check*() functions.
Also a partial fix for #14445 where building CMake
(without cmake-gui) when Qt5 is installed and Qt4 is not installed
and warnings come out of FindQt4.cmake.
Add an introduction about the use of different package types, and the
ability to use Qt 4 and 5 versions together in a single buildsystem.
Add a section about automatic linking of the qtmain.lib library and
how to disable it.
Commit 321e348e (QtAutogen: Use Qt 4 IMPORTED targets to find
executable locations., 2014-01-24) attempted to fix this problem,
but only solved it for a particular ordering of find_package for
Qt 4 and Qt 5.
Add a test to ensure that it works with both orderings.
Remove independent doc listing for Qt4ConfigurationSettings, Qt4Macros
and UseQt4. These are implementation details.
Recommend the use of IMPORTED targets.
Remove references to the UseQt4 file, which is obsolete in light of
the IMPORTED targets.
Add documentation for automatic tool invocation and options.
Remove reference to variables which should not be needed in modern
implementations.
73e9340 get_target_property: Error on non-existent target.
ab9f58f FindQt4: Ensure target exists before calling get_target_property.
37ebeb9 FindQt4: Fix use of get_target_property to use actual target name.
6aabb6a Genex: Use case-sensitive comparison for COMPILER_ID.
5bb53f6 cmTarget: Deprecate COMPILE_DEFINITIONS_ properties with a policy.
This fixes a regression introduced by commit b8af46cb (FindQt4: Don't
fail if certain Qt modules are unavailable., 2013-05-23)
The _FOUND variable is set by the _QT4_ADJUST_LIB_VARS macro, so
invoke that unconditionally, and guard only the set_property calls,
as described in the original bug report (#14165).
The parent commit accidentally referenced QT_QMAKE_QMAKE_EXECUTABLE
which does not exist. Use QT_QMAKE_EXECUTABLE instead.
Reported-by: m.hergarden@euphoria-it.nl
Wihtout this, if qmake binary is from Qt5 the FindQt4 fails even though
the Qt4 version of qmake would be installed as qmake-qt4.
On Archlinux this is the case.
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
This means for example, that consumers can use:
target_link_libraries(foo ${QT_QTGUI_LIBRARIES})
instead of also needing to specify all 'public' dependencies:
target_link_libraries(foo ${QT_QTGUI_LIBRARIES} ${QT_QTCORE_LIBRARIES} )
when using the IMPORTED targets. Also populate the
IMPORTED_LINK_DEPENDENT_LIBRARIES property so CMake can help the linker
find shared library dependencies.
Handle OpenBSD specific paths in Qt3/Qt4, allowing concurrent building
and installation. Some common programs are renamed with suffixes of
either 3 or 4. Also, allow qt3/qt4 installed under /usr/local to be
searched and recognized appropriately.
This solves a lots of warnings, e.g. in the FindModulesExecuteAll test. If the
installed version on the system is rather old this may even lead to bugs, e.g.
https://bugs.gentoo.org/show_bug.cgi?id=436540
...if the library file does not exist inside the .framework then do
not allow a library variable to be set to the path to the framework.
Force set it to NOTFOUND instead.