From dc6d8066607435a0d4b6338bc53e0b1ac746bd35 Mon Sep 17 00:00:00 2001 From: Ruslan Baratov Date: Sat, 1 Oct 2016 02:30:57 +0300 Subject: Add a BUILD_RPATH target property specifying build-tree RPATH entries Users may need to add custom `RPATH` entries to be able to run binaries from their build tree without setting `LD_LIBRARY_PATH`. Provide a way to do this that does not affect the install-tree `RPATH`. --- Help/manual/cmake-properties.7.rst | 1 + Help/manual/cmake-variables.7.rst | 1 + Help/prop_tgt/BUILD_RPATH.rst | 10 ++++++++++ Help/release/dev/add-BUILD_RPATH.rst | 6 ++++++ Help/variable/CMAKE_BUILD_RPATH.rst | 10 ++++++++++ 5 files changed, 28 insertions(+) create mode 100644 Help/prop_tgt/BUILD_RPATH.rst create mode 100644 Help/release/dev/add-BUILD_RPATH.rst create mode 100644 Help/variable/CMAKE_BUILD_RPATH.rst (limited to 'Help') diff --git a/Help/manual/cmake-properties.7.rst b/Help/manual/cmake-properties.7.rst index 271f497261..fa21a1fe2c 100644 --- a/Help/manual/cmake-properties.7.rst +++ b/Help/manual/cmake-properties.7.rst @@ -121,6 +121,7 @@ Properties on Targets /prop_tgt/AUTORCC /prop_tgt/AUTORCC_OPTIONS /prop_tgt/BINARY_DIR + /prop_tgt/BUILD_RPATH /prop_tgt/BUILD_WITH_INSTALL_RPATH /prop_tgt/BUNDLE_EXTENSION /prop_tgt/BUNDLE diff --git a/Help/manual/cmake-variables.7.rst b/Help/manual/cmake-variables.7.rst index b74f8670e6..f76c467cb6 100644 --- a/Help/manual/cmake-variables.7.rst +++ b/Help/manual/cmake-variables.7.rst @@ -257,6 +257,7 @@ Variables that Control the Build /variable/CMAKE_AUTORCC_OPTIONS /variable/CMAKE_AUTOUIC /variable/CMAKE_AUTOUIC_OPTIONS + /variable/CMAKE_BUILD_RPATH /variable/CMAKE_BUILD_WITH_INSTALL_RPATH /variable/CMAKE_COMPILE_PDB_OUTPUT_DIRECTORY /variable/CMAKE_COMPILE_PDB_OUTPUT_DIRECTORY_CONFIG diff --git a/Help/prop_tgt/BUILD_RPATH.rst b/Help/prop_tgt/BUILD_RPATH.rst new file mode 100644 index 0000000000..27393f5d77 --- /dev/null +++ b/Help/prop_tgt/BUILD_RPATH.rst @@ -0,0 +1,10 @@ +BUILD_RPATH +----------- + +A :ref:`;-list ` specifying runtime path (``RPATH``) +entries to add to binaries linked in the build tree (for platforms that +support it). The entries will *not* be used for binaries in the install +tree. See also the :prop_tgt:`INSTALL_RPATH` target property. + +This property is initialized by the value of the variable +:variable:`CMAKE_BUILD_RPATH` if it is set when a target is created. diff --git a/Help/release/dev/add-BUILD_RPATH.rst b/Help/release/dev/add-BUILD_RPATH.rst new file mode 100644 index 0000000000..0d69e45e85 --- /dev/null +++ b/Help/release/dev/add-BUILD_RPATH.rst @@ -0,0 +1,6 @@ +add-BUILD_RPATH +--------------- + +* A :variable:`CMAKE_BUILD_RPATH` variable and corresponding + :prop_tgt:`BUILD_RPATH` target property were added to support custom + ``RPATH`` locations to be added to binaries in the build tree. diff --git a/Help/variable/CMAKE_BUILD_RPATH.rst b/Help/variable/CMAKE_BUILD_RPATH.rst new file mode 100644 index 0000000000..f20eb418f4 --- /dev/null +++ b/Help/variable/CMAKE_BUILD_RPATH.rst @@ -0,0 +1,10 @@ +CMAKE_BUILD_RPATH +----------------- + +A :ref:`;-list ` specifying runtime path (``RPATH``) +entries to add to binaries linked in the build tree (for platforms that +support it). The entries will *not* be used for binaries in the install +tree. See also the :variable:`CMAKE_INSTALL_RPATH` variable. + +This is used to initialize the :prop_tgt:`BUILD_RPATH` target property +for all targets. -- cgit v1.2.1