diff options
author | Brad King <brad.king@kitware.com> | 2013-08-26 15:50:08 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2013-08-26 15:54:07 (GMT) |
commit | df62f64db72b6f00657e9e739e1e117639dea9da (patch) | |
tree | 88a64dd1f0579ab27b18b0911c817c1e556b3259 /Docs | |
parent | 8da09f6ee1a59cbef6327d2a88ab8ba5f8b29b1a (diff) | |
download | CMake-df62f64db72b6f00657e9e739e1e117639dea9da.zip CMake-df62f64db72b6f00657e9e739e1e117639dea9da.tar.gz CMake-df62f64db72b6f00657e9e739e1e117639dea9da.tar.bz2 |
Clean up install rules of CMake itself (#14371)
Ensure CMAKE_DATA_DIR, CMAKE_DOC_DIR, and CMAKE_MAN_DIR are always
relative paths in CMake code, and set defaults accordingly. Use the
install() command instead of install_files() and install_targets().
This is more modern and also avoids stripping of the first character
from user-specified destinations.
While at it, fix the default destinations reported in the bootstrap
help.
Diffstat (limited to 'Docs')
-rw-r--r-- | Docs/CMakeLists.txt | 5 | ||||
-rw-r--r-- | Docs/bash-completion/CMakeLists.txt | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/Docs/CMakeLists.txt b/Docs/CMakeLists.txt index a5e91c9..34090d2 100644 --- a/Docs/CMakeLists.txt +++ b/Docs/CMakeLists.txt @@ -1,4 +1,3 @@ -string(REGEX REPLACE "^/(.*)" "\\1" REL_CMAKE_DATA_DIR "${CMAKE_DATA_DIR}") -install(FILES cmake-help.vim cmake-indent.vim cmake-syntax.vim DESTINATION ${REL_CMAKE_DATA_DIR}/editors/vim) -install(FILES cmake-mode.el DESTINATION ${REL_CMAKE_DATA_DIR}/editors/emacs) +install(FILES cmake-help.vim cmake-indent.vim cmake-syntax.vim DESTINATION ${CMAKE_DATA_DIR}/editors/vim) +install(FILES cmake-mode.el DESTINATION ${CMAKE_DATA_DIR}/editors/emacs) add_subdirectory (bash-completion) diff --git a/Docs/bash-completion/CMakeLists.txt b/Docs/bash-completion/CMakeLists.txt index 592b71e..c0a8899 100644 --- a/Docs/bash-completion/CMakeLists.txt +++ b/Docs/bash-completion/CMakeLists.txt @@ -5,4 +5,4 @@ # add symlinks to the files in appropriate places # /etc/bash_completion.d/ # DATADIR/completions (may be /usr/share/<package>/completions -install(FILES cmake cpack ctest DESTINATION ${REL_CMAKE_DATA_DIR}/completions) +install(FILES cmake cpack ctest DESTINATION ${CMAKE_DATA_DIR}/completions) |