Skip to content

Commit

Permalink
INSTALL_RPATH_USE_LINK_PATH
Browse files Browse the repository at this point in the history
  • Loading branch information
ahnaf-tahmid-chowdhury committed May 5, 2024
1 parent dc80c6a commit b1debd7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 0 additions & 2 deletions cmake/PyneMacros.cmake
Expand Up @@ -12,14 +12,12 @@ endmacro()

# Configure RPATH
macro(pyne_configure_rpath)
set(CMAKE_BUILD_WITH_INSTALL_RPATH ON)
if(APPLE)
set(RPATH "@loader_path")
elseif(UNIX)
set(RPATH "$ORIGIN")
else()
# Windows
set(CMAKE_BUILD_WITH_INSTALL_RPATH OFF)
set(RPATH OFF)
endif()
endmacro()
Expand Down
2 changes: 2 additions & 0 deletions src/CMakeLists.txt
Expand Up @@ -225,6 +225,8 @@ install(TARGETS ${CMAKE_PROJECT_NAME} LIBRARY
# Configure the RPATH
if(RPATH)
set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES
INSTALL_RPATH_USE_LINK_PATH TRUE
BUILD_WITH_INSTALL_RPATH TRUE
INSTALL_RPATH ${RPATH}
)
endif()

0 comments on commit b1debd7

Please sign in to comment.