[cmake-commits] king committed cmInstallTargetGenerator.cxx 1.40 1.41
cmake-commits at cmake.org
cmake-commits at cmake.org
Mon Jul 2 11:31:12 EDT 2007
Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv3722
Modified Files:
cmInstallTargetGenerator.cxx
Log Message:
BUG: Fix install_name_tool update of the executable in an installed bundle on OSX. This addresses bug#4534.
Index: cmInstallTargetGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmInstallTargetGenerator.cxx,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- cmInstallTargetGenerator.cxx 2 Jul 2007 15:02:52 -0000 1.40
+++ cmInstallTargetGenerator.cxx 2 Jul 2007 15:31:10 -0000 1.41
@@ -178,6 +178,13 @@
const char* config,
Indent const& indent)
{
+ // Compute the full path to the main installed file for this target.
+ std::string toFullPath = "$ENV{DESTDIR}";
+ toFullPath += this->Destination;
+ toFullPath += "/";
+ toFullPath += this->GetInstallFilename(this->Target, config,
+ this->ImportLibrary, false);
+
// Compute the list of files to install for this target.
std::vector<std::string> files;
std::string literal_args;
@@ -214,6 +221,9 @@
from1 += ".app";
files.push_back(from1);
type = cmTarget::INSTALL_DIRECTORY;
+ toFullPath += ".app/Contents/MacOS/";
+ toFullPath += this->GetInstallFilename(this->Target, config,
+ this->ImportLibrary, false);
literal_args += " USE_SOURCE_PERMISSIONS";
// TODO: Still need to apply install_name_tool and stripping
// to binaries inside bundle.
@@ -284,12 +294,6 @@
no_rename, literal_args.c_str(),
indent);
- std::string toFullPath = "$ENV{DESTDIR}";
- toFullPath += this->Destination;
- toFullPath += "/";
- toFullPath += this->GetInstallFilename(this->Target, config,
- this->ImportLibrary, false);
-
os << indent << "IF(EXISTS \"" << toFullPath << "\")\n";
this->AddInstallNamePatchRule(os, indent.Next(), config, toFullPath);
this->AddRanlibRule(os, indent.Next(), type, toFullPath);
More information about the Cmake-commits
mailing list