From e51835110a0878dca709ce947955fa8a5066ea61 Mon Sep 17 00:00:00 2001 From: "Joachim Wuttke (h)" <j.wuttke@fz-juelich.de> Date: Fri, 2 Jun 2023 20:12:11 +0200 Subject: [PATCH] correct install destination, use GNUInstallDirs --- CMakeLists.txt | 2 ++ QCR/CMakeLists.txt | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4a2bdc0..c27294c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -55,6 +55,8 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) ## Installation settings. +include(GNUInstallDirs) + configure_file("qcr.pc.in" "qcr.pc" @ONLY) install( FILES "${CMAKE_CURRENT_BINARY_DIR}/qcr.pc" diff --git a/QCR/CMakeLists.txt b/QCR/CMakeLists.txt index 8a669e0..d697957 100644 --- a/QCR/CMakeLists.txt +++ b/QCR/CMakeLists.txt @@ -52,10 +52,10 @@ set_target_properties( install( TARGETS ${lib} EXPORT QCRTargets - LIBRARY DESTINATION lib - RUNTIME DESTINATION lib - ARCHIVE DESTINATION lib - ) + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + COMPONENT Libraries) set(include_dest include/QCR) file(MAKE_DIRECTORY ${include_dest}) -- GitLab