diff options
author | Andrei Alexeyev <akari@taisei-project.org> | 2020-11-12 22:59:42 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-12 12:59:42 -0800 |
commit | d239a265b95ee75d610e795861390eb57accea58 (patch) | |
tree | d6e763e4182dbc726e34382ea5f08052f4e5c622 | |
parent | c48433eb9c24bf51ae24fbe646fc4719ea88e746 (diff) | |
download | binaryen-d239a265b95ee75d610e795861390eb57accea58.tar.gz binaryen-d239a265b95ee75d610e795861390eb57accea58.tar.bz2 binaryen-d239a265b95ee75d610e795861390eb57accea58.zip |
build/linux: more correct rpath handling (#3331)
Don't hardcode `lib`, it's incorrect for many systems (e.g. `lib64` is
common on some x86_64 distros like openSUSE). Use CMAKE_INSTALL_LIBDIR
instead.
-rw-r--r-- | CMakeLists.txt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 784fbcd64..d879e86d7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -82,7 +82,7 @@ function(binaryen_setup_rpath name) set(_install_name_dir INSTALL_NAME_DIR "@rpath") set(_install_rpath "@loader_path/../lib") elseif(UNIX) - set(_install_rpath "\$ORIGIN/../lib") + set(_install_rpath "\$ORIGIN/../${CMAKE_INSTALL_LIBDIR}") if(${CMAKE_SYSTEM_NAME} MATCHES "(FreeBSD|DragonFly)") set_property(TARGET ${name} APPEND_STRING PROPERTY LINK_FLAGS " -Wl,-z,origin ") |