Skip to content

Commit

Permalink
Merge pull request #38 from project-tsurugi/build-fix-rh-rpath
Browse files Browse the repository at this point in the history
build: fix RPATH settings to work even if libdir is not "lib"
  • Loading branch information
kuron99 authored Feb 17, 2025
2 parents 2f7274c + 78bc215 commit c434c92
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions examples/cli/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2018-2023 Project Tsurugi.
# Copyright 2018-2025 Project Tsurugi.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -25,7 +25,7 @@ add_executable(cli

set_target_properties(cli
PROPERTIES
INSTALL_RPATH "\$ORIGIN/../lib"
INSTALL_RPATH "\$ORIGIN/../${CMAKE_INSTALL_LIBDIR}"
RUNTIME_OUTPUT_NAME "sharksfin-cli"
)

Expand Down
4 changes: 2 additions & 2 deletions memory/src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2018-2023 Project Tsurugi.
# Copyright 2018-2025 Project Tsurugi.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -21,7 +21,7 @@ add_library(memory

set_target_properties(memory
PROPERTIES
INSTALL_RPATH "\$ORIGIN/../lib"
INSTALL_RPATH "\$ORIGIN"
LIBRARY_OUTPUT_NAME "sharksfin-memory"
)

Expand Down
2 changes: 1 addition & 1 deletion shirakami/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ add_library(shirakami

set_target_properties(shirakami
PROPERTIES
INSTALL_RPATH "\$ORIGIN/../lib"
INSTALL_RPATH "\$ORIGIN"
LIBRARY_OUTPUT_NAME "sharksfin-shirakami"
)

Expand Down

0 comments on commit c434c92

Please sign in to comment.