From 68964b8db6952aee33c1ece7d3215da531c92991 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= Date: Fri, 5 Nov 2021 22:19:36 +0100 Subject: [PATCH] cmake: fix incorrect relative path concatenation (#733) When a `-DCMAKE_INSTALL_PREFIX` is given, this could result in paths like: /path/to/prefix//path/to/prefix/lib/cmake/glog/glog-modules.cmake which was incorrect. If a relative `DESTINATION` is given, it's assumed to be relative to the install prefix. --- AUTHORS | 1 + CMakeLists.txt | 2 +- CONTRIBUTORS | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/AUTHORS b/AUTHORS index 5d8cc0db9..5f74a7a35 100644 --- a/AUTHORS +++ b/AUTHORS @@ -19,6 +19,7 @@ Guillaume Dumont Marco Wang Michael Tanner MiniLight +Niklas Hambuechen romange Roman Perepelitsa Sergiu Deitsch diff --git a/CMakeLists.txt b/CMakeLists.txt index ca93d0b80..990daa46e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1027,7 +1027,7 @@ configure_file (\"${CMAKE_CURRENT_SOURCE_DIR}/glog-modules.cmake.in\" file (INSTALL \"${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/glog-modules.cmake\" DESTINATION - \"\${CMAKE_INSTALL_PREFIX}/${_glog_CMake_INSTALLDIR}\") + \"${_glog_CMake_INSTALLDIR}\") " COMPONENT Development ) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 571fd9618..b125035e9 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -39,6 +39,7 @@ Marco Wang Michael Darr Michael Tanner MiniLight +Niklas Hambuechen Peter Collingbourne Rodrigo Queiro romange