diff options
author | Brad King <brad.king@kitware.com> | 2016-09-08 13:36:51 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2016-09-08 13:36:51 (GMT) |
commit | 04657ee2f83cb446c5595090f256273a23be94a2 (patch) | |
tree | 2ac65fed70ad562137ecd9d478580528d9d1a159 /Source | |
parent | 4c674eba7ab7d431f535639553be8dcce14276c4 (diff) | |
parent | 290e4ce8a89819d6617fa404513d8a1629cafea7 (diff) | |
download | CMake-04657ee2f83cb446c5595090f256273a23be94a2.zip CMake-04657ee2f83cb446c5595090f256273a23be94a2.tar.gz CMake-04657ee2f83cb446c5595090f256273a23be94a2.tar.bz2 |
Merge topic 'install-export-root-prefix'
290e4ce8 install: Fix computed import prefix in export files when it is "/"
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmExportInstallFileGenerator.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx index ceba69a..bcadaa0 100644 --- a/Source/cmExportInstallFileGenerator.cxx +++ b/Source/cmExportInstallFileGenerator.cxx @@ -122,7 +122,10 @@ bool cmExportInstallFileGenerator::GenerateMainFile(std::ostream& os) "PATH)\n"; dest = cmSystemTools::GetFilenamePath(dest); } - os << "\n"; + os << "if(_IMPORT_PREFIX STREQUAL \"/\")\n" + << " set(_IMPORT_PREFIX \"\")\n" + << "endif()\n" + << "\n"; } std::vector<std::string> missingTargets; |