AddBuildPropertyForConfig() public méthode

public AddBuildPropertyForConfig ( IEnumerable configGuids, string name, string value ) : void
configGuids IEnumerable
name string
value string
Résultat void
    public static void OnPostProcessBuild(BuildTarget target, string pathToBuiltProject)
    {
        Debug.LogWarning("IphoneX Fiter");
        if (target != BuildTarget.iOS)
        {
            Debug.LogWarning("Target is not iPhone. XCodePostProcess will not run");
            return;
        }
        // Create a new project object from build target
        UnityEditor.iOS.Xcode.PBXProject project = new UnityEditor.iOS.Xcode.PBXProject();
        string configFilePath = UnityEditor.iOS.Xcode.PBXProject.GetPBXProjectPath(pathToBuiltProject);

        project.ReadFromFile(configFilePath);
        string targetGuid = project.TargetGuidByName("Unity-iPhone");
        string debug      = project.BuildConfigByName(targetGuid, "Debug");
        string release    = project.BuildConfigByName(targetGuid, "Release");

        project.AddBuildPropertyForConfig(debug, "CODE_SIGN_RESOURCE_RULES_PATH", "$(SDKROOT)/ResourceRules.plist");
        project.AddBuildPropertyForConfig(release, "CODE_SIGN_RESOURCE_RULES_PATH", "$(SDKROOT)/ResourceRules.plist");

        project.AddFrameworkToProject(targetGuid, "SystemConfiguration.framework", true);
        project.AddFrameworkToProject(targetGuid, "Security.framework", true);
        project.AddFrameworkToProject(targetGuid, "libz.tbd", true);
        project.AddFrameworkToProject(targetGuid, "libc++.tbd", true);

        project.SetBuildProperty(targetGuid, "ENABLE_BITCODE", "NO");

        project.WriteToFile(configFilePath);

        EditSuitIpXCode(pathToBuiltProject);
    }