summaryrefslogtreecommitdiffstats
path: root/src/widgets/graphicsview
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2018-10-16 12:58:22 -0400
committerKyle Edwards <kyle.edwards@kitware.com>2018-12-07 21:06:53 +0000
commiteda28621f6c1a68774719f382be53ec109123b18 (patch)
tree065356083b9822dc3e345f40b1d5d481cc996a39 /src/widgets/graphicsview
parent70a5fc15fdff380eab3f136eba9992f1d2263957 (diff)
Add support for linking against static builds in CMake
This change reinstates functionality that was removed in commit 102e1822ffcdc9954d3c698f863734a8083e349c. However, it differs from the original implementation in several ways: * It uses the QMAKE_PRL_LIBS variable, replacing whitespace with semicolons, rather than using a dedicated QMAKE_PRL_LIBS_FOR_CMAKE variable. * More importantly, it parses the -L and -l flags and uses CMake's find_library() command to look for the libraries in the specified search paths, and then converts them to absolute paths. This is the same approach that CMake's own FindPkgConfig module uses to find libraries specified in this form. Any other flags not of the form -L or -l (for instance, -s flags passed to Emscripten) are added to the new INTERFACE_LINK_OPTIONS target property if the CMake version is 3.13 or newer. The original implementation of this functionality was removed because of the lack of absolute library paths. At the time, it was believed that qmake would have to be modified to do its own equivalent of find_library() to get the absolute paths to the libraries. However, the approach taken by FindPkgConfig has proven robust enough to be used here, allowing CMake to find the absolute paths to the libraries without having to modify qmake. [ChangeLog][CMake] Added support for automatic linking of transitive dependencies in static builds Fixes: QTBUG-38913 Change-Id: I7d9cdb0d339c6ef697b04099d129481c770fc0fc Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/widgets/graphicsview')
0 files changed, 0 insertions, 0 deletions