CPack: Add compatibility for incorrect CPACK_INSTALL_CMAKE_PROJECTS value
Since commit v3.6.0-rc1~339^2 (CPack: Fix CPACK_INSTALL_CMAKE_PROJECTS SubDirectory (4th) option, 2016-02-18) we now honor the "Directory" option of this variable. Prior to that commit the value was not used so projects may have used a placeholder value like `.` instead of `/`. Treat `.` the same as `/` to restore compatibility with such projects. Fixes #16205.
This commit is contained in:
parent
e31084e657
commit
57534990d8
|
@ -625,7 +625,8 @@ int cmCPackGenerator::InstallProjectViaInstallCMakeProjects(
|
||||||
cmGlobalGenerator gg(&cm);
|
cmGlobalGenerator gg(&cm);
|
||||||
cmsys::auto_ptr<cmMakefile> mf(
|
cmsys::auto_ptr<cmMakefile> mf(
|
||||||
new cmMakefile(&gg, cm.GetCurrentSnapshot()));
|
new cmMakefile(&gg, cm.GetCurrentSnapshot()));
|
||||||
if (!installSubDirectory.empty() && installSubDirectory != "/") {
|
if (!installSubDirectory.empty() && installSubDirectory != "/" &&
|
||||||
|
installSubDirectory != ".") {
|
||||||
tempInstallDirectory += installSubDirectory;
|
tempInstallDirectory += installSubDirectory;
|
||||||
}
|
}
|
||||||
if (componentInstall) {
|
if (componentInstall) {
|
||||||
|
|
Loading…
Reference in New Issue