Skip to content

Commit

Permalink
Merge pull request #2454 from lf-lang/cmake-dont-clear-rpath
Browse files Browse the repository at this point in the history
CMake: Dont clear executable runtime path when installing
  • Loading branch information
erlingrj authored Jan 6, 2025
2 parents 74e13e0 + 0864ed5 commit 35ebba7
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,10 @@ CodeBuilder generateCMakeCode(
cMakeCode.pr("set(CMAKE_COLOR_DIAGNOSTICS ON)\n");
cMakeCode.newLine();

cMakeCode.pr("# Do not clear runtime path of the executable when installing it\n");
cMakeCode.pr("SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)\n");
cMakeCode.newLine();

if (CppMode) {
// Suppress warnings about const char*.
cMakeCode.pr("set(CMAKE_CXX_FLAGS \"${CMAKE_CXX_FLAGS} -Wno-write-strings\")");
Expand Down

0 comments on commit 35ebba7

Please sign in to comment.