On 2015-10-26 13:13, Thiago Macieira via Interest wrote: > On Monday 26 October 2015 11:58:14 Matthew Woehlke wrote: >> Shouldn't Qt5Config.cmake provide those interface libraries for static >> Qt libraries? It seems to me it should, and since Qt is shipping its >> Qt5Config.cmake these days, that would imply that the problem can/should >> be fixed in Qt itself... > > Tell us what variable to save them in.
I would assume the same properties as you are using. Looking at my /usr/lib64/cmake/Qt5Core/Qt5CoreConfig.cmake, it looks like they would need to wind up in _<libname>_LIB_DEPENDENCIES, however that gets set. I can't tell you exactly because I'm not familiar with how Qt5*Config.cmake are created. Ultimately though they need to end up in the exported libraries' INTERFACE_LINK_LIBRARIES property (and the IMPORTED_LINK_INTERFACE_LIBRARIES_<config> compatability property). > The .pc file has it in the right variable: > > Libs: -L${libdir} -lQt5Core > Libs.private: -lpthread -lz -licui18n -licuuc -licudata -lpcre16 -lm -ldl - > lgthread-2.0 -pthread -lglib-2.0 -lrt -lsystemd Do you know when setting up your exported targets that the libraries are static? (Based on my /usr/lib64/cmake/Qt5Core/Qt5CoreConfig.cmake, I think "yes"?) If yes, when the exported targets are static libraries, just fold the public and private libraries together and specify *all* of them as interface link libraries. That's TRTTD, and I believe what CMake does when CMake is generating the target export file. -- Matthew _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest