[Cmake-commits] [cmake-commits] hoffman committed cmCPackBundleGenerator.cxx 1.2.2.3 1.2.2.4 cmCPackGenerator.cxx 1.6.2.4 1.6.2.5 cmCPackGenerator.h 1.2.2.3 1.2.2.4 cmCPackNSISGenerator.cxx 1.31.2.2 1.31.2.3 cmCPackNSISGenerator.h 1.11.2.2 1.11.2.3 cmCPackPackageMakerGenerator.cxx 1.23.2.3 1.23.2.4
cmake-commits at cmake.org
cmake-commits at cmake.org
Fri Oct 24 11:18:57 EDT 2008
Update of /cvsroot/CMake/CMake/Source/CPack
In directory public:/mounts/ram/cvs-serv25234/Source/CPack
Modified Files:
Tag: CMake-2-6
cmCPackBundleGenerator.cxx cmCPackGenerator.cxx
cmCPackGenerator.h cmCPackNSISGenerator.cxx
cmCPackNSISGenerator.h cmCPackPackageMakerGenerator.cxx
Log Message:
ENH: merge in changes for 2.6.3 RC 1
Index: cmCPackBundleGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackBundleGenerator.cxx,v
retrieving revision 1.2.2.3
retrieving revision 1.2.2.4
diff -C 2 -d -r1.2.2.3 -r1.2.2.4
*** cmCPackBundleGenerator.cxx 22 Jul 2008 18:04:24 -0000 1.2.2.3
--- cmCPackBundleGenerator.cxx 24 Oct 2008 15:18:55 -0000 1.2.2.4
***************
*** 81,85 ****
// Get required arguments ...
! const std::string cpack_bundle_name = this->GetOption("CPACK_BUNDLE_NAME") ? this->GetOption("CPACK_BUNDLE_NAME") : "";
if(cpack_bundle_name.empty())
{
--- 81,86 ----
// Get required arguments ...
! const std::string cpack_bundle_name = this->GetOption("CPACK_BUNDLE_NAME")
! ? this->GetOption("CPACK_BUNDLE_NAME") : "";
if(cpack_bundle_name.empty())
{
***************
*** 91,95 ****
}
! const std::string cpack_bundle_plist = this->GetOption("CPACK_BUNDLE_PLIST") ? this->GetOption("CPACK_BUNDLE_PLIST") : "";
if(cpack_bundle_plist.empty())
{
--- 92,97 ----
}
! const std::string cpack_bundle_plist = this->GetOption("CPACK_BUNDLE_PLIST")
! ? this->GetOption("CPACK_BUNDLE_PLIST") : "";
if(cpack_bundle_plist.empty())
{
***************
*** 101,105 ****
}
! const std::string cpack_bundle_icon = this->GetOption("CPACK_BUNDLE_ICON") ? this->GetOption("CPACK_BUNDLE_ICON") : "";
if(cpack_bundle_icon.empty())
{
--- 103,108 ----
}
! const std::string cpack_bundle_icon = this->GetOption("CPACK_BUNDLE_ICON")
! ? this->GetOption("CPACK_BUNDLE_ICON") : "";
if(cpack_bundle_icon.empty())
{
***************
*** 111,115 ****
}
! const std::string cpack_bundle_startup_command = this->GetOption("CPACK_BUNDLE_STARTUP_COMMAND") ? this->GetOption("CPACK_BUNDLE_STARTUP_COMMAND") : "";
if(cpack_bundle_startup_command.empty())
{
--- 114,120 ----
}
! const std::string cpack_bundle_startup_command =
! this->GetOption("CPACK_BUNDLE_STARTUP_COMMAND") ?
! this->GetOption("CPACK_BUNDLE_STARTUP_COMMAND") : "";
if(cpack_bundle_startup_command.empty())
{
***************
*** 122,126 ****
// Get optional arguments ...
! const std::string cpack_package_icon = this->GetOption("CPACK_PACKAGE_ICON") ? this->GetOption("CPACK_PACKAGE_ICON") : "";
// The staging directory contains everything that will end-up inside the
--- 127,132 ----
// Get optional arguments ...
! const std::string cpack_package_icon = this->GetOption("CPACK_PACKAGE_ICON")
! ? this->GetOption("CPACK_PACKAGE_ICON") : "";
// The staging directory contains everything that will end-up inside the
***************
*** 182,186 ****
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
! "Error copying startup command. Check the value of CPACK_BUNDLE_STARTUP_COMMAND."
<< std::endl);
--- 188,193 ----
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
! "Error copying startup command. "
! " Check the value of CPACK_BUNDLE_STARTUP_COMMAND."
<< std::endl);
***************
*** 209,213 ****
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
! "Error copying disk volume icon. Check the value of CPACK_PACKAGE_ICON."
<< std::endl);
--- 216,221 ----
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
! "Error copying disk volume icon. "
! "Check the value of CPACK_PACKAGE_ICON."
<< std::endl);
Index: cmCPackGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackGenerator.cxx,v
retrieving revision 1.6.2.4
retrieving revision 1.6.2.5
diff -C 2 -d -r1.6.2.4 -r1.6.2.5
*** cmCPackGenerator.cxx 24 Sep 2008 14:07:49 -0000 1.6.2.4
--- cmCPackGenerator.cxx 24 Oct 2008 15:18:55 -0000 1.6.2.5
***************
*** 643,650 ****
if ( setDestDir )
{
! // For DESTDIR based packaging, use the *project* CMAKE_INSTALL_PREFIX
! // underneath the tempInstallDirectory. The value of the project's
! // CMAKE_INSTALL_PREFIX is sent in here as the value of the
! // CPACK_INSTALL_PREFIX variable.
std::string dir;
if (this->GetOption("CPACK_INSTALL_PREFIX"))
--- 643,651 ----
if ( setDestDir )
{
! // For DESTDIR based packaging, use the *project*
! // CMAKE_INSTALL_PREFIX underneath the tempInstallDirectory. The
! // value of the project's CMAKE_INSTALL_PREFIX is sent in here as
! // the value of the CPACK_INSTALL_PREFIX variable.
! //
std::string dir;
if (this->GetOption("CPACK_INSTALL_PREFIX"))
***************
*** 654,657 ****
--- 655,681 ----
mf->AddDefinition("CMAKE_INSTALL_PREFIX", dir.c_str());
+ cmCPackLogger(
+ cmCPackLog::LOG_DEBUG,
+ "- Using DESTDIR + CPACK_INSTALL_PREFIX... (mf->AddDefinition)"
+ << std::endl);
+ cmCPackLogger(cmCPackLog::LOG_DEBUG,
+ "- Setting CMAKE_INSTALL_PREFIX to '" << dir << "'"
+ << std::endl);
+
+ // Make sure that DESTDIR + CPACK_INSTALL_PREFIX directory
+ // exists:
+ //
+ if (cmSystemTools::StringStartsWith(dir.c_str(), "/"))
+ {
+ dir = tempInstallDirectory + dir;
+ }
+ else
+ {
+ dir = tempInstallDirectory + "/" + dir;
+ }
+
+ cmCPackLogger(cmCPackLog::LOG_DEBUG,
+ "- Creating directory: '" << dir << "'" << std::endl);
+
if ( !cmsys::SystemTools::MakeDirectory(dir.c_str()))
{
***************
*** 661,677 ****
return 0;
}
-
- cmCPackLogger(cmCPackLog::LOG_DEBUG,
- "- Using DESTDIR + CPACK_INSTALL_PREFIX... (mf->AddDefinition)"
- << std::endl);
- cmCPackLogger(cmCPackLog::LOG_DEBUG,
- "- Setting CMAKE_INSTALL_PREFIX to '" << dir << "'"
- << std::endl);
}
else
{
! mf->AddDefinition("CMAKE_INSTALL_PREFIX", tempInstallDirectory.c_str());
! if ( !cmsys::SystemTools::MakeDirectory(tempInstallDirectory.c_str()))
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
--- 685,696 ----
return 0;
}
}
else
{
! mf->AddDefinition("CMAKE_INSTALL_PREFIX",
! tempInstallDirectory.c_str());
! if ( !cmsys::SystemTools::MakeDirectory(
! tempInstallDirectory.c_str()))
{
cmCPackLogger(cmCPackLog::LOG_ERROR,
***************
*** 682,688 ****
cmCPackLogger(cmCPackLog::LOG_DEBUG,
! "- Using non-DESTDIR install... (mf->AddDefinition)" << std::endl);
cmCPackLogger(cmCPackLog::LOG_DEBUG,
! "- Setting CMAKE_INSTALL_PREFIX to '" << tempInstallDirectory
<< "'" << std::endl);
}
--- 701,709 ----
cmCPackLogger(cmCPackLog::LOG_DEBUG,
! "- Using non-DESTDIR install... (mf->AddDefinition)"
! << std::endl);
cmCPackLogger(cmCPackLog::LOG_DEBUG,
! "- Setting CMAKE_INSTALL_PREFIX to '"
! << tempInstallDirectory
<< "'" << std::endl);
}
***************
*** 771,775 ****
if ( cmSystemTools::FileExists(toplevelDirectory) )
{
! cmCPackLogger(cmCPackLog::LOG_VERBOSE, "Remove toplevel directory: "
<< toplevelDirectory << std::endl);
if ( !cmSystemTools::RemoveADirectory(toplevelDirectory) )
--- 792,797 ----
if ( cmSystemTools::FileExists(toplevelDirectory) )
{
! cmCPackLogger(cmCPackLog::LOG_VERBOSE,
! "Remove toplevel directory: "
<< toplevelDirectory << std::endl);
if ( !cmSystemTools::RemoveADirectory(toplevelDirectory) )
***************
*** 1078,1082 ****
//----------------------------------------------------------------------
cmCPackInstallationType*
! cmCPackGenerator::GetInstallationType(const char *projectName, const char *name)
{
(void) projectName;
--- 1100,1105 ----
//----------------------------------------------------------------------
cmCPackInstallationType*
! cmCPackGenerator::GetInstallationType(const char *projectName,
! const char *name)
{
(void) projectName;
***************
*** 1139,1143 ****
|| cmSystemTools::IsOn(this->GetOption("CPACK_DOWNLOAD_ALL"));
! const char* archiveFile = this->GetOption((macroPrefix + "_ARCHIVE_FILE").c_str());
if (archiveFile && *archiveFile)
{
--- 1162,1167 ----
|| cmSystemTools::IsOn(this->GetOption("CPACK_DOWNLOAD_ALL"));
! const char* archiveFile = this->GetOption((macroPrefix +
! "_ARCHIVE_FILE").c_str());
if (archiveFile && *archiveFile)
{
***************
*** 1191,1195 ****
++dependIt)
{
! cmCPackComponent *child = GetComponent(projectName, dependIt->c_str());
component->Dependencies.push_back(child);
child->ReverseDependencies.push_back(component);
--- 1215,1220 ----
++dependIt)
{
! cmCPackComponent *child = GetComponent(projectName,
! dependIt->c_str());
component->Dependencies.push_back(child);
child->ReverseDependencies.push_back(component);
Index: cmCPackGenerator.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackGenerator.h,v
retrieving revision 1.2.2.3
retrieving revision 1.2.2.4
diff -C 2 -d -r1.2.2.3 -r1.2.2.4
*** cmCPackGenerator.h 24 Sep 2008 14:07:50 -0000 1.2.2.3
--- cmCPackGenerator.h 24 Oct 2008 15:18:55 -0000 1.2.2.4
***************
*** 128,134 ****
virtual bool SupportsComponentInstallation() const;
! virtual cmCPackInstallationType* GetInstallationType(const char *projectName, const char* name);
! virtual cmCPackComponent* GetComponent(const char *projectName, const char* name);
! virtual cmCPackComponentGroup* GetComponentGroup(const char *projectName, const char* name);
bool GeneratorVerbose;
--- 128,137 ----
virtual bool SupportsComponentInstallation() const;
! virtual cmCPackInstallationType* GetInstallationType(const char *projectName,
! const char* name);
! virtual cmCPackComponent* GetComponent(const char *projectName,
! const char* name);
! virtual cmCPackComponentGroup* GetComponentGroup(const char *projectName,
! const char* name);
bool GeneratorVerbose;
Index: cmCPackNSISGenerator.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackNSISGenerator.h,v
retrieving revision 1.11.2.2
retrieving revision 1.11.2.3
diff -C 2 -d -r1.11.2.2 -r1.11.2.3
*** cmCPackNSISGenerator.h 13 Jul 2008 21:55:24 -0000 1.11.2.2
--- cmCPackNSISGenerator.h 24 Oct 2008 15:18:55 -0000 1.11.2.3
***************
*** 66,71 ****
std::set<cmCPackComponent *>& visited);
! /// Produce NSIS code that de-selects all of the components that are dependent
! /// on this component, recursively.
std::string CreateDeselectionDependenciesDescription
(cmCPackComponent *component,
--- 66,71 ----
std::set<cmCPackComponent *>& visited);
! /// Produce NSIS code that de-selects all of the components that are
! /// dependent on this component, recursively.
std::string CreateDeselectionDependenciesDescription
(cmCPackComponent *component,
Index: cmCPackPackageMakerGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackPackageMakerGenerator.cxx,v
retrieving revision 1.23.2.3
retrieving revision 1.23.2.4
diff -C 2 -d -r1.23.2.3 -r1.23.2.4
*** cmCPackPackageMakerGenerator.cxx 30 Jul 2008 18:54:49 -0000 1.23.2.3
--- cmCPackPackageMakerGenerator.cxx 24 Oct 2008 15:18:55 -0000 1.23.2.4
***************
*** 180,184 ****
// Create the directory where downloaded component packages will
// be placed.
! const char* userUploadDirectory = this->GetOption("CPACK_UPLOAD_DIRECTORY");
std::string uploadDirectory;
if (userUploadDirectory && *userUploadDirectory)
--- 180,185 ----
// Create the directory where downloaded component packages will
// be placed.
! const char* userUploadDirectory =
! this->GetOption("CPACK_UPLOAD_DIRECTORY");
std::string uploadDirectory;
if (userUploadDirectory && *userUploadDirectory)
***************
*** 223,229 ****
if (this->PackageCompatibilityVersion < 10.5)
{
! cmCPackLogger(cmCPackLog::LOG_WARNING,
! "CPack warning: please set CPACK_OSX_PACKAGE_VERSION to 10.5 or greater enable downloaded packages. CPack will build a non-downloaded package."
! << std::endl);
}
--- 224,233 ----
if (this->PackageCompatibilityVersion < 10.5)
{
! cmCPackLogger(
! cmCPackLog::LOG_WARNING,
! "CPack warning: please set CPACK_OSX_PACKAGE_VERSION to 10.5 "
! "or greater enable downloaded packages. CPack will build a "
! "non-downloaded package."
! << std::endl);
}
***************
*** 231,235 ****
{
cmCPackLogger(cmCPackLog::LOG_WARNING,
! "CPack warning: unable to build downloaded packages with PackageMaker versions prior to 3.0. CPack will build a non-downloaded package."
<< std::endl);
}
--- 235,241 ----
{
cmCPackLogger(cmCPackLog::LOG_WARNING,
! "CPack warning: unable to build downloaded "
! "packages with PackageMaker versions prior "
! "to 3.0. CPack will build a non-downloaded package."
<< std::endl);
}
***************
*** 606,610 ****
{
cmCPackLogger(cmCPackLog::LOG_OUTPUT,
! "- Building component package: " << packageFile << std::endl);
// The command that will be used to run PackageMaker
--- 612,617 ----
{
cmCPackLogger(cmCPackLog::LOG_OUTPUT,
! "- Building component package: " <<
! packageFile << std::endl);
// The command that will be used to run PackageMaker
***************
*** 639,643 ****
std::string moduleVersionSuffix = ".";
moduleVersionSuffix += component.Name;
! this->SetOption("CPACK_MODULE_VERSION_SUFFIX", moduleVersionSuffix.c_str());
std::string infoFileName = component.Name;
infoFileName += "-Info.plist";
--- 646,651 ----
std::string moduleVersionSuffix = ".";
moduleVersionSuffix += component.Name;
! this->SetOption("CPACK_MODULE_VERSION_SUFFIX",
! moduleVersionSuffix.c_str());
std::string infoFileName = component.Name;
infoFileName += "-Info.plist";
***************
*** 802,806 ****
<< "title=\"" << component.DisplayName << "\" "
<< "start_selected=\""
! << (component.IsDisabledByDefault && !component.IsRequired? "false" : "true")
<< "\" "
<< "start_enabled=\""
--- 810,815 ----
<< "title=\"" << component.DisplayName << "\" "
<< "start_selected=\""
! << (component.IsDisabledByDefault &&
! !component.IsRequired? "false" : "true")
<< "\" "
<< "start_enabled=\""
***************
*** 813,817 ****
<< "\" ";
}
! if (!component.Dependencies.empty() || !component.ReverseDependencies.empty())
{
// The "selected" expression is evaluated each time any choice is
--- 822,827 ----
<< "\" ";
}
! if (!component.Dependencies.empty() ||
! !component.ReverseDependencies.empty())
{
// The "selected" expression is evaluated each time any choice is
***************
*** 886,890 ****
++dependIt)
{
! out << " && choices['" << (*dependIt)->Name << "Choice'].selected";
AddDependencyAttributes(**dependIt, visited, out);
}
--- 896,901 ----
++dependIt)
{
! out << " && choices['" <<
! (*dependIt)->Name << "Choice'].selected";
AddDependencyAttributes(**dependIt, visited, out);
}
Index: cmCPackNSISGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/CPack/cmCPackNSISGenerator.cxx,v
retrieving revision 1.31.2.2
retrieving revision 1.31.2.3
diff -C 2 -d -r1.31.2.2 -r1.31.2.3
*** cmCPackNSISGenerator.cxx 13 Jul 2008 21:55:24 -0000 1.31.2.2
--- cmCPackNSISGenerator.cxx 24 Oct 2008 15:18:55 -0000 1.31.2.3
***************
*** 112,116 ****
if (slash != std::string::npos)
{
! // If this is a component installation, determine which component it is.
componentName = fileN.substr(0, slash);
--- 112,117 ----
if (slash != std::string::npos)
{
! // If this is a component installation, determine which component it
! // is.
componentName = fileN.substr(0, slash);
***************
*** 285,294 ****
}
! this->SetOptionIfNotSet("CPACK_NSIS_INSTALLATION_TYPES", installTypesCode.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_PAGE_COMPONENTS", "!insertmacro MUI_PAGE_COMPONENTS");
this->SetOptionIfNotSet("CPACK_NSIS_FULL_INSTALL", "");
! this->SetOptionIfNotSet("CPACK_NSIS_COMPONENT_SECTIONS", componentCode.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_COMPONENT_SECTION_LIST", sectionList.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_SECTION_SELECTED_VARS", selectedVarsList.c_str());
this->SetOption("CPACK_NSIS_DEFINES", defines.c_str());
}
--- 286,300 ----
}
! this->SetOptionIfNotSet("CPACK_NSIS_INSTALLATION_TYPES",
! installTypesCode.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_PAGE_COMPONENTS",
! "!insertmacro MUI_PAGE_COMPONENTS");
this->SetOptionIfNotSet("CPACK_NSIS_FULL_INSTALL", "");
! this->SetOptionIfNotSet("CPACK_NSIS_COMPONENT_SECTIONS",
! componentCode.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_COMPONENT_SECTION_LIST",
! sectionList.c_str());
! this->SetOptionIfNotSet("CPACK_NSIS_SECTION_SELECTED_VARS",
! selectedVarsList.c_str());
this->SetOption("CPACK_NSIS_DEFINES", defines.c_str());
}
***************
*** 343,353 ****
cmsys::SystemTools::KeyWOW64_32) )
{
! cmCPackLogger
! (cmCPackLog::LOG_ERROR,
! "Cannot find NSIS registry value. This is usually caused by NSIS "
! "not being installed. Please install NSIS from "
! "http://nsis.sourceforge.net"
! << std::endl);
! return 0;
}
path.push_back(nsisPath);
--- 349,363 ----
cmsys::SystemTools::KeyWOW64_32) )
{
! if ( !cmsys::SystemTools::ReadRegistryValue(
! "HKEY_LOCAL_MACHINE\\SOFTWARE\\NSIS", nsisPath) )
! {
! cmCPackLogger
! (cmCPackLog::LOG_ERROR,
! "Cannot find NSIS registry value. This is usually caused by NSIS "
! "not being installed. Please install NSIS from "
! "http://nsis.sourceforge.net"
! << std::endl);
! return 0;
! }
}
path.push_back(nsisPath);
***************
*** 591,595 ****
std::string
cmCPackNSISGenerator::
! CreateComponentDescription(cmCPackComponent *component, cmOStringStream& macrosOut)
{
// Basic description of the component
--- 601,606 ----
std::string
cmCPackNSISGenerator::
! CreateComponentDescription(cmCPackComponent *component,
! cmOStringStream& macrosOut)
{
// Basic description of the component
***************
*** 641,645 ****
// Create the directory for the upload area
! const char* userUploadDirectory = this->GetOption("CPACK_UPLOAD_DIRECTORY");
std::string uploadDirectory;
if (userUploadDirectory && *userUploadDirectory)
--- 652,657 ----
// Create the directory for the upload area
! const char* userUploadDirectory =
! this->GetOption("CPACK_UPLOAD_DIRECTORY");
std::string uploadDirectory;
if (userUploadDirectory && *userUploadDirectory)
***************
*** 771,775 ****
else
{
! componentCode += " File /r \"${INST_DIR}\\" + component->Name + "\\*.*\"\n";
}
componentCode += " noinstall_" + component->Name + ":\n";
--- 783,788 ----
else
{
! componentCode += " File /r \"${INST_DIR}\\" +
! component->Name + "\\*.*\"\n";
}
componentCode += " noinstall_" + component->Name + ":\n";
***************
*** 838,842 ****
out << " IntOp $0 $0 | ${SF_SELECTED}\n";
out << " SectionSetFlags ${" << (*dependIt)->Name << "} $0\n";
! out << " IntOp $" << (*dependIt)->Name << "_selected 0 + ${SF_SELECTED}\n";
// Recurse
out << CreateSelectionDependenciesDescription(*dependIt, visited).c_str();
--- 851,856 ----
out << " IntOp $0 $0 | ${SF_SELECTED}\n";
out << " SectionSetFlags ${" << (*dependIt)->Name << "} $0\n";
! out << " IntOp $" << (*dependIt)->Name
! << "_selected 0 + ${SF_SELECTED}\n";
// Recurse
out << CreateSelectionDependenciesDescription(*dependIt, visited).c_str();
***************
*** 873,877 ****
// Recurse
! out << CreateDeselectionDependenciesDescription(*dependIt, visited).c_str();
}
--- 887,892 ----
// Recurse
! out <<
! CreateDeselectionDependenciesDescription(*dependIt, visited).c_str();
}
More information about the Cmake-commits
mailing list