Two changes were needed:
- correctly link against frameworks
- use qcore_mac.cpp instead of qcore_mac_objc.mm, because we don't
link against AppKit
Change-Id: Ibd9d6d367a7fcdf7dce277c1b06d36c491294eeb
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Improve the code that simplifies conditions to take "OS families"
into account. E.g. if a system must be ANDROID, then it is redundant
to express that it is NOT APPLE_OSX.
Change-Id: Ib7e62726c309bf84b9e5e0d6a6e3465511db0ead
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Parse conditions more exactly as before, enabling proper handling
of else scopes.
Change-Id: Icb5dcc73010be4833b2d1cbc1396191992df1ee4
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Since the dependency on moc is in CorePrivate (o Core) we need
the target to depend on it otherwise cmake will try to use moc before
it is built.
This is because what we do with cmake is say "moc is in this
path, you can use it", but it's actually not built yet so
we need to depend on a target that depends on moc directly otherwise
cmake will trust us and try to use a cmake that doesn't exist and just
hang forever when running make -jN
Change-Id: Icf55c62092fd3fd3754a4f4f28c8c313bf374615
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
And add the eglfs_x11 plugin
We need to actually try to compile the test as the comment it it says
that having x11 and egl is not enough since sometimes they are actually
incompatible
Change-Id: If6bdc08c21b91fa9c41663f2fa653fd59e5ddd2e
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Only has warnings for now
Next to come is the support for developer-build and enabling Werror
Change-Id: I8070dc06eb439c2a03007cce975c8147ff7e1582
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Because the default "empty" CMAKE_BUILD_TYPE is a weird default
Change-Id: I5768f67aa85dce4108e421d2f4eacdfb1cb5beb0
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
This amends d885226544.
Change-Id: Ia7b2fb6e0e762c73d3c0775cdd106c1dec646ab2
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Use the same approach as with qmake, by using readelf -l /bin/ls and
then a regular expression to extract the program interpreter path. It's
a little simpler in cmake because we can avoid the perl dance and quotes
and just use cmake's built-in regular expression matching.
This change also excludes static builds, as with qmake.
Change-Id: I699e166c4b38b3fe98e6390316206109ad6363f9
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Upstream commit 7c64db9568296e1caafcfd7163cea3ab1b1626ae fixed the
suffix path checking and thus the build on FreeBSD.
Change-Id: I0cceeac0639c2899c617ffd6359098d2154acf5b
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Pass -DQT_USE_CCACHE=ON to enable the use of ccache. This avoids having
to set up symlinks, which is useful when cross-compiling against
different targets.
Change-Id: I023fff105baaa538730997948aa122d2678887ce
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Don't try to build uic but instead import it. This is done centrally now
in add_qt_tool.
Change-Id: I241fbb924de68549e9c0320e157351bd7b1bf5c3
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
so use map_qt_library instead of map_qt_base_library
Change-Id: I4dd0097fff3ffd9ec4aad36d11d79ea23a08cb90
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Makes sure qobject.cpp.o also sees -DQT_BUILD_CORE_LIB
Change-Id: I2aaf1cec62eeab07bbec6e4135bbe144d4ae7fba
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Liang Qi <liang.qi@qt.io>
Public interface libraries of the private target need to be first looked
up via `find_dependency(...)` in the CMake config files as well.
This patch is just changing the foreach() loop and defer the package
config file generation.
Change-Id: Iecaf7f778379b526f12ac6a42e76d714d9349b2c
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Lifetime of the variable is bound to the function body. Use a CACHE
variable to escape it (and to speed up future calls to the function).
Change-Id: I2d164a1c94e64cc652e65c1eea0522f3d911ad82
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
... when QtBuild.cmake is being included from another Qt module
Change-Id: Ia55e03422cc84a56dd9eac640621e5b2ee9681bd
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
The ECM version now also does a compile test, which was the only real
"functional" difference.
Change-Id: I1d5cd590359feba7c7a38ff374992349d5943070
Reviewed-by: Volker Krause <volker.krause@kdab.com>
This makes it possible to use the binaries out of the box. This is
particularly relevant for program binaries that link against QtCore
dynamically, when trying to use these binaries during cross-compilation.
Change-Id: I7dee93194be3fff5c6e3bbb9e202e4cf5e19b6d0
Reviewed-by: Volker Krause <volker.krause@kdab.com>
Otherwise the cmake summary at the end says
-- The following packages have not been found:
* WrapOpenGL
It's OpenGL or GLESv2 that will show there as missing if needed
Change-Id: I182f1299b86e1a4e24762d0bad6533c6136cbbcc
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
The syncqt generated headers are optional, i.e. their source may not
exist -- so for now make their installation optional (as it seems to
have been the case with qmake).
Change-Id: Ieaeb3d13a1d8ff1f158b5b1c918750fec48d3bef
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
This change fixes a few things in one go:
* cmake's FindOpenGL cannot be used reliably to detect EGL. So use a
custom module for that.
* Added a custom module for GLESv2 detection, as cmake's FindOpenGL
does not support that.
* Map CONFIG += opengl to a WrapOpenGL target, which links against
either GLESv2 or libGL - just like mkspecs/features/*/opengl.prf
* cmake's FindOpenGL remains in use solely to detect the availability
of desktop gl.
Change-Id: I9315e5ad1fd88e1b7dc7e920053e98fb51fea7fc
Reviewed-by: Volker Krause <volker.krause@kdab.com>