Make CPACK_SET_DESTDIR work with archive generator + component-based packaging

Fix bug #13004. The patch is from Stanislaw Szymczyk.
This commit is contained in:
Eric NOULARD 2012-10-14 18:50:57 +02:00
parent 3eecc12df0
commit ddec053321
1 changed files with 1 additions and 1 deletions

View File

@ -905,7 +905,7 @@ int cmCPackGenerator::InstallProjectViaInstallCMakeProjects(
localFileName =
cmSystemTools::RelativePath(InstallPrefix, fit->c_str());
localFileName =
localFileName.substr(localFileName.find('/')+1,
localFileName.substr(localFileName.find_first_not_of('/'),
std::string::npos);
Components[installComponent].Files.push_back(localFileName);
cmCPackLogger(cmCPackLog::LOG_DEBUG, "Adding file <"