Quantcast
Channel: Questions in topic: "xcode"
Viewing all articles
Browse latest Browse all 1047

xcodesettingspostprocesser

$
0
0
Hi, i've made a script to modify some xcode project setting after unity build. public class XcodeSettingsPostProcesser { [PostProcessBuildAttribute(0)] public static void OnPostprocessBuild(BuildTarget buildTarget, string pathToBuiltProject) { // Stop processing if targe is NOT iOS if (buildTarget != BuildTarget.iOS) return; // Initialize PbxProject var projectPath = pathToBuiltProject + "/Unity-iPhone.xcodeproj/project.pbxproj"; PBXProject pbxProject = new PBXProject(); pbxProject.ReadFromFile(projectPath); string targetGuid = pbxProject.TargetGuidByName("Unity-iPhone"); pbxProject.UpdateBuildProperty(targetGuid, "Enable Objective-C Exceptions", new string[] { "Yes" },new string[] { "No" }); // Apply settings File.WriteAllText(projectPath, pbxProject.WriteToString()); } } specifically i wanna set "Enable Objective-C Exceptions" to Yes. But instead update the settings, i've got a new setting parameter (equals to the original one) with Yes setted. Obviously xcode continue to take the original one : ( any suggestion?

Viewing all articles
Browse latest Browse all 1047

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>