示例#1
0
        public static PBXShellScriptBuildPhaseData Create(string name, string shellPath, string shellScript)
        {
            var res = new PBXShellScriptBuildPhaseData();

            res.guid = PBXGUID.Generate();
            res.SetPropertyString("isa", "PBXShellScriptBuildPhase");
            res.SetPropertyString("buildActionMask", "2147483647");
            res.files = new List <string>();
            res.SetPropertyString("runOnlyForDeploymentPostprocessing", "0");
            res.name        = name;
            res.shellPath   = shellPath;
            res.shellScript = shellScript;
            return(res);
        }
示例#2
0
        // name may be null
        public static PBXCopyFilesBuildPhaseData Create(string name, string dstPath, string subfolderSpec)
        {
            var res = new PBXCopyFilesBuildPhaseData();

            res.guid = PBXGUID.Generate();
            res.SetPropertyString("isa", "PBXCopyFilesBuildPhase");
            res.SetPropertyString("buildActionMask", "2147483647");
            res.dstPath          = dstPath;
            res.dstSubfolderSpec = subfolderSpec;
            res.files            = new List <string>();
            res.SetPropertyString("runOnlyForDeploymentPostprocessing", "0");
            res.name = name;
            return(res);
        }
示例#3
0
        public static PBXFileReferenceData CreateFromFile(string path, string projectFileName,
                                                          PBXSourceTree tree)
        {
            string guid = PBXGUID.Generate();

            PBXFileReferenceData fileRef = new PBXFileReferenceData();

            fileRef.SetPropertyString("isa", "PBXFileReference");
            fileRef.guid = guid;
            fileRef.path = path;
            fileRef.name = projectFileName;
            fileRef.tree = tree;
            return(fileRef);
        }
示例#4
0
        public static PBXBuildFileData CreateFromFile(string fileRefGUID, bool weak,
                                                      string compileFlags)
        {
            PBXBuildFileData buildFile = new PBXBuildFileData();

            buildFile.guid = PBXGUID.Generate();
            buildFile.SetPropertyString("isa", "PBXBuildFile");
            buildFile.fileRef             = fileRefGUID;
            buildFile.compileFlags        = compileFlags;
            buildFile.weak                = weak;
            buildFile.codeSignOnCopy      = false;
            buildFile.removeHeadersOnCopy = false;
            buildFile.assetTags           = new List <string>();
            return(buildFile);
        }
示例#5
0
        public static PBXNativeTargetData Create(string name, string productRef,
                                                 string productType, string buildConfigList)
        {
            var res = new PBXNativeTargetData();

            res.guid = PBXGUID.Generate();
            res.SetPropertyString("isa", "PBXNativeTarget");
            res.buildConfigList = buildConfigList;
            res.phases          = new GUIDList();
            res.SetPropertyList("buildRules", new List <string>());
            res.dependencies     = new GUIDList();
            res.name             = name;
            res.productReference = productRef;
            res.SetPropertyString("productName", name);
            res.SetPropertyString("productReference", productRef);
            res.SetPropertyString("productType", productType);
            return(res);
        }
示例#6
0
        // name must not contain '/'
        public static PBXGroupData Create(string name, string path, PBXSourceTree tree)
        {
            if (name.Contains("/"))
            {
                throw new Exception("Group name must not contain '/'");
            }

            PBXGroupData gr = new PBXGroupData();

            gr.guid = PBXGUID.Generate();
            gr.SetPropertyString("isa", "PBXGroup");
            gr.name     = name;
            gr.path     = path;
            gr.tree     = PBXSourceTree.Group;
            gr.children = new GUIDList();

            return(gr);
        }