From 9f9872d164dfdbb1b1590d7e5eb05d00a9fd4db4 Mon Sep 17 00:00:00 2001 From: Arniiiii Date: Tue, 20 Aug 2024 05:16:45 +0000 Subject: [PATCH] make ARCH_INDEPENDENT libraries to have CMake configs installed to share --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2c35c56..80d46e2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -113,8 +113,10 @@ function(packageProject) endif() endif() + set(INSTALL_DIR_FOR_CMAKE_CONFIGS ${CMAKE_INSTALL_LIBDIR}) if(PROJECT_ARCH_INDEPENDENT) set(wbpvf_extra_args ARCH_INDEPENDENT) + set(INSTALL_DIR_FOR_CMAKE_CONFIGS ${CMAKE_INSTALL_DATADIR}) # share endif() write_basic_package_version_file( @@ -141,7 +143,7 @@ function(packageProject) ) set("${PROJECT_NAME}_INSTALL_CMAKEDIR" - "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}${PROJECT_VERSION_SUFFIX}" + "${INSTALL_DIR_FOR_CMAKE_CONFIGS}/cmake/${PROJECT_NAME}${PROJECT_VERSION_SUFFIX}" CACHE PATH "CMake package config location relative to the install prefix" )