aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2021-12-08 13:42:28 +0100
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2021-12-08 13:42:28 +0100
commit66af7423e1a3df332f9c62992f92639cead987b0 (patch)
tree7b272a1a1442c68990539a165f9f86c519a08bd2
parent5b84c106dd8af8f0be14fd8a8efd3b3dd9ef2c25 (diff)
parentaf5a57545d9aa5493790798b77364f3c923eb337 (diff)
downloadqmenumodel-66af7423e1a3df332f9c62992f92639cead987b0.tar.gz
qmenumodel-66af7423e1a3df332f9c62992f92639cead987b0.tar.bz2
qmenumodel-66af7423e1a3df332f9c62992f92639cead987b0.zip
Merge branch 'tari01-pr/fix-qt5-use-modules-warning'
Attributes GH PR #14: https://github.com/AyatanaIndicators/qmenumodel/pull/14
-rw-r--r--examples/CMakeLists.txt3
-rw-r--r--tests/client/CMakeLists.txt10
-rw-r--r--tests/script/CMakeLists.txt2
3 files changed, 10 insertions, 5 deletions
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
index 028c6ef..67e1348 100644
--- a/examples/CMakeLists.txt
+++ b/examples/CMakeLists.txt
@@ -14,7 +14,6 @@ pkg_check_modules(QMENUMODEL REQUIRED qmenumodel)
add_executable(info-menumodel info-menumodel.cpp)
-qt5_use_modules(info-menumodel Core)
include_directories(${QMENUMODEL_INCLUDE_DIRS})
-target_link_libraries(info-menumodel ${QMENUMODEL_LDFLAGS})
+target_link_libraries(info-menumodel ${QMENUMODEL_LDFLAGS} Qt5::Core)
diff --git a/tests/client/CMakeLists.txt b/tests/client/CMakeLists.txt
index 9021585..3d1dc9a 100644
--- a/tests/client/CMakeLists.txt
+++ b/tests/client/CMakeLists.txt
@@ -1,11 +1,16 @@
macro(declare_test testname)
add_executable(${testname} ${testname}.cpp)
- qt5_use_modules(${testname} Core DBus Widgets Test Qml Quick)
target_link_libraries(${testname}
qmenumodel
dbusmenuscript
${GLIB_LDFLAGS}
${GIO_LDFLAGS}
+ Qt5::Core
+ Qt5::DBus
+ Qt5::Widgets
+ Qt5::Test
+ Qt5::Qml
+ Qt5::Quick
)
if(TEST_XML_OUTPUT)
@@ -28,11 +33,12 @@ endmacro(declare_test testname)
macro(declare_simple_test testname)
add_executable(${testname} ${testname}.cpp)
- qt5_use_modules(${testname} Core Test)
target_link_libraries(${testname}
qmenumodel
${GLIB_LDFLAGS}
${GIO_LDFLAGS}
+ Qt5::Core
+ Qt5::Test
)
add_test(${testname}
diff --git a/tests/script/CMakeLists.txt b/tests/script/CMakeLists.txt
index afa073b..fc0db8a 100644
--- a/tests/script/CMakeLists.txt
+++ b/tests/script/CMakeLists.txt
@@ -4,5 +4,5 @@ add_library(dbusmenuscript STATIC dbusmenuscript.cpp)
set_target_properties(dbusmenuscript PROPERTIES COMPILE_FLAGS -fPIC)
-qt5_use_modules(dbusmenuscript Core DBus Test)
+target_link_libraries(dbusmenuscript Qt5::Core Qt5::DBus Qt5::Test)