From a0a1411ec96143e1d386bad7618898dc64669d4b Mon Sep 17 00:00:00 2001 From: Andrew Kaster Date: Sat, 12 Aug 2023 18:21:38 -0600 Subject: [PATCH] CMake: Set CMAKE_RUNTIME_OUTPUT_DIRECTORY based on CMAKE_INSTALL_BINDIR Instead of hardcoding bin/, we should use the INSTALL_BINDIR directly to reflect the intent of the way we're doing the settings. This should have the benefit of fixing the build when a distro sets the GNUInstallDirs variables to exciting values, like on NixOS. --- Meta/Lagom/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Meta/Lagom/CMakeLists.txt b/Meta/Lagom/CMakeLists.txt index dc024db158..4a34749592 100644 --- a/Meta/Lagom/CMakeLists.txt +++ b/Meta/Lagom/CMakeLists.txt @@ -80,7 +80,7 @@ include(GNUInstallDirs) # make sure to include before we mess w/RPATH # Mirror the structure of the installed tree to ensure that rpaths # always remain valid. -set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/bin") +set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_BINDIR}") set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}") set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}")