[Interest] QMake, (static) libraries and LTCG (LTO) on Mac

René J.V. Bertin rjvbertin at gmail.com
Sat Nov 11 14:01:53 CET 2017


Hi,

I have made some tweaks to the qttools/src/assistant directories so that I can build the Assistant as a standalone application against any Qt install. To do that, I removed the qtNomakeTools(), load(qt_module) and load(qt_app) statements from the relevant .pro files, set up QtHelp to build as a static library and removed the `help` from `QT` in the Assistant's .pro file, replacing that with `LIB += -L../help -lQHelp`.

That works, and on Linux I can build the resulting application with LTO by adding `-config ltcg` to the qmake invocation. On Mac however that leads to a whole list of missing symbol errors in the final link step, all from the QtHelp library.

Am I doing something wrong or am I simply hitting a limitation?

Thanks,
René



More information about the Interest mailing list