From 04c715d3144c1f1fb5aba86708cb292d1d54ac64 Mon Sep 17 00:00:00 2001 From: Bananymous Date: Mon, 2 Sep 2024 21:31:08 +0300 Subject: [PATCH] BuildSystem: Build all libraries in root build directory I could not figure out how to use cmake's rpath to build libraries with DT_NEEDED only containing the library name, not a relative path. --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index c08a832a2e..581595c2c3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,6 +25,9 @@ set(CMAKE_INSTALL_SYSCONF ${BANAN_ETC}) set(CMAKE_INSTALL_MESSAGE NEVER) set(CMAKE_SKIP_INSTALL_ALL_DEPENDENCY True) +set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}") +set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}") + # include headers of ${library} to ${target} function(banan_include_headers target library) target_include_directories(${target} PRIVATE $/include)