summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2020-12-03 11:53:24 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2020-12-03 18:48:25 +0000
commit50fff573777bd32a3ade8e5548c7ec551976593f (patch)
treebe5578970228e1e58dd6216c07177bd1cbf65884 /cmake
parent8e7bcedb659a4d9a052a0ddea375abd253e8925f (diff)
CMake: Fix QMAKE_LIB_<NAME> variable names in module .pri files
QMake libraries that contain dashes are referenced by QMAKE_USE as is, but the corresponding QMAKE_LIB_<NAME> variable must be normalized to contain underscores. Example from the qmake build: ./mkspecs/modules/qt_lib_waylandclient.pri 11:QT.waylandclient.uses = wayland-client xkbcommon wayland-cursor ./mkspecs/modules/qt_lib_waylandclient_private.pri 12:QMAKE_DEPENDS_WAYLAND_CURSOR_CC = WAYLAND_CLIENT 13:QMAKE_DEPENDS_WAYLAND_CURSOR_LD = WAYLAND_CLIENT 15:QMAKE_LIBS_WAYLAND_CURSOR = -lwayland-cursor Change-Id: If31bd45764d52f97d80d6388503008dc1ffb16ab Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit e32e4898dde1dc2a5ae19a1c3dc4609064258a43) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/QtPriHelpers.cmake1
1 files changed, 1 insertions, 0 deletions
diff --git a/cmake/QtPriHelpers.cmake b/cmake/QtPriHelpers.cmake
index 4fe8c609d4..e77e98fe76 100644
--- a/cmake/QtPriHelpers.cmake
+++ b/cmake/QtPriHelpers.cmake
@@ -18,6 +18,7 @@ function(qt_generate_qmake_libraries_pri_content module_name output_root_dir out
foreach(lib ${QT_QMAKE_LIBS_FOR_${module_name}})
set(lib_targets ${QT_TARGETS_OF_QMAKE_LIB_${lib}})
string(TOUPPER ${lib} uclib)
+ string(REPLACE "-" "_" uclib "${uclib}")
set(lib_defines "")
set(lib_incdir "")
set(lib_libdir "")