summaryrefslogtreecommitdiff
path: root/src/debug/createdump/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'src/debug/createdump/CMakeLists.txt')
-rw-r--r--src/debug/createdump/CMakeLists.txt11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/debug/createdump/CMakeLists.txt b/src/debug/createdump/CMakeLists.txt
index 5b5ec0a5c6..4272cfcb87 100644
--- a/src/debug/createdump/CMakeLists.txt
+++ b/src/debug/createdump/CMakeLists.txt
@@ -2,6 +2,17 @@ project(createdump)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
+# Set the RPATH of createdump so that it can find dependencies without needing to set LD_LIBRARY_PATH
+# For more information: http://www.cmake.org/Wiki/CMake_RPATH_handling.
+if (CORECLR_SET_RPATH)
+ set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE)
+ if(CLR_CMAKE_PLATFORM_DARWIN)
+ set(CMAKE_INSTALL_RPATH "@loader_path")
+ else()
+ set(CMAKE_INSTALL_RPATH "\$ORIGIN")
+ endif(CLR_CMAKE_PLATFORM_DARWIN)
+endif (CORECLR_SET_RPATH)
+
remove_definitions(-DUNICODE)
remove_definitions(-D_UNICODE)