From 4c0bee6c7e60f56f11df6c1be1cfef98b1dfc4da Mon Sep 17 00:00:00 2001 From: Sebastian Reimers Date: Wed, 4 Dec 2024 08:26:50 +0100 Subject: [PATCH] cmake: fix APPLE RPATH workaround (#3232) --- CMakeLists.txt | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 469e89033..6022a4797 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -53,10 +53,8 @@ endif() set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_C_STANDARD 11) -list(FIND CMAKE_C_IMPLICIT_LINK_DIRECTORIES - "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}" IS_SYSTEM_DIR) -if(IS_SYSTEM_DIR STREQUAL "-1") - set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}") +if(APPLE) + set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib") set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) endif()