[cmake-developers] [patch] install cfbundles as directory
Tim Blechmann
tim at klingt.org
Wed Jul 9 14:02:00 EDT 2014
>> shall i update the patch?
>
> Yes, so that we know the updated version works for what you need.
> Please also include a change to use Ben's suggestion of
>
> targetName.find('/')
>
> instead of find_first_of.
attached!
thanks a lot,
tim
-------------- next part --------------
>From 18147876fd834a24dcdeca70078c972f84e92866 Mon Sep 17 00:00:00 2001
From: Tim Blechmann <tim at klingt.org>
Date: Wed, 9 Jul 2014 20:01:11 +0200
Subject: [PATCH] InstallTarget: install CFBundles with complete directory
---
Source/cmInstallTargetGenerator.cxx | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/Source/cmInstallTargetGenerator.cxx b/Source/cmInstallTargetGenerator.cxx
index 7a39f45..38d369e 100644
--- a/Source/cmInstallTargetGenerator.cxx
+++ b/Source/cmInstallTargetGenerator.cxx
@@ -213,6 +213,20 @@ void cmInstallTargetGenerator::GenerateScriptForConfig(std::ostream& os,
filesFrom.push_back(from1);
filesTo.push_back(to1);
}
+ else if(this->Target->IsCFBundleOnApple())
+ {
+ // Install the whole app bundle directory.
+ type = cmInstallType_DIRECTORY;
+ literal_args += " USE_SOURCE_PERMISSIONS";
+
+ std::string targetNameBase = targetName.substr(0, targetName.find('/'));
+
+ std::string from1 = fromDirConfig + targetNameBase;
+ std::string to1 = toDir + targetName;
+
+ filesFrom.push_back(from1);
+ filesTo.push_back(to1);
+ }
else
{
bool haveNamelink = false;
--
2.0.1
More information about the cmake-developers
mailing list