Skip to content

Commit

Permalink
Add BUILD_RPATH back
Browse files Browse the repository at this point in the history
  • Loading branch information
adamdempsey90 committed Jan 18, 2025
1 parent a412b54 commit 07b8d2a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,9 @@ if (CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME)

# Bake in rpath to rebound on mac
if(${CMAKE_SYSTEM_NAME} STREQUAL "Darwin")
set_target_properties(artemis PROPERTIES
BUILD_RPATH "${CMAKE_BINARY_DIR}/rebound"
)
add_custom_command(TARGET artemis POST_BUILD
COMMAND install_name_tool -add_rpath @executable_path/../rebound $<TARGET_FILE:artemis>
COMMAND install_name_tool -change librebound.so @rpath/librebound.so $<TARGET_FILE:artemis>
Expand Down

0 comments on commit 07b8d2a

Please sign in to comment.