detect the Qt version KF5 frameworks were build against in CMake?
René J.V. Bertin
rjvbertin at gmail.com
Wed Aug 28 18:19:21 BST 2019
Hi,
Some KF5 framework libraries pull in Qt5 headers and/or libraries via their CMake modules, right?
Take the somewhat unusual situation where you have your KF5 frameworks built against, say, Qt 5.9 from the system and you want to test an application against a different, newer Qt build installed with Qt's installer. Qt guarantees this should work as long as you don't use private APIs.
Those aforementioned KF5 frameworks will pull in "their" Qt5 headers (e.g. for Qt5Network in the project I'm tinkering with), meaning that QT_VERSION #ifdefs can behave in an unexpected way.
Is there a way to detect this kind of situation at the cmake level, i.e. is there some constant that holds the Qt value the frameworks were built against?
Thanks,
R.
More information about the Kde-frameworks-devel
mailing list