-
Bug
-
Resolution: Done
-
P2: Important
-
6.2.0
-
None
-
-
165e01d5d51d16377542c1b3ffbc22f03fb75e97 (qt/qtbase/dev) 2bb41394e0b910bb7c1b1b40ff9944f179ba7be2 (qt/qtbase/6.2)
When building Qt for INTEGRITY in the CI, the CMake variable UNIX not set.
This leads to undefined symbols when building applications against that Qt.
See integration errors of https://codereview.qt-project.org/c/qt/qtdeclarative/+/372168 for details.
If we look at the attached trace file, the toolchain file sets UNIX:
/home/qt/integrity_toolchain/toolchain.cmake(14): set(UNIX True )
But later we have
/opt/cmake-3.21.1/share/cmake-3.21/Modules/CMakeSystemSpecificInformation.cmake(15): set(UNIX )
and just a few lines below we have
/opt/cmake-3.21.1/share/cmake-3.21/Modules/CMakeSystemSpecificInformation.cmake(30): message(System is unknown to cmake, create:
Platform/Integrity to use this system, please post your config file on discourse.cmake.org so it can be added to cmake )
And we should take this warning seriously.
That means that setting UNIX in a toolchain file doesn't have the desired effect.
This variable must be set in a Modules/Platform/Integrity.cmake include file.
Until such a file is available upstream, we could work around this issue by
- setting UNIX as cache variable on the command line for non-qtbase repos too
- setting UNIX in QtPlatformSupport.cmake