Пример #1
0
 public override void AddFilesToManifest(BuildManifest Manifest, STBuildBinary Binary)
 {
     // ok, this is pretty awful, we want the import libraries that go with the editor, only on the PC
     if (STBuildTool.BuildingRocket() &&
         Path.GetFileNameWithoutExtension(Binary.Config.OutputFilePath).StartsWith("UE4Editor-", StringComparison.InvariantCultureIgnoreCase) &&
         Path.GetExtension(Binary.Config.OutputFilePath).EndsWith("dll", StringComparison.InvariantCultureIgnoreCase) &&
         Binary.Config.Type == STBuildBinaryType.DynamicLinkLibrary)
     {
         // ok, this is pretty awful, we want the import libraries that go with the editor, only on the PC
         Manifest.AddBuildProduct(Path.Combine(Binary.Config.IntermediateDirectory, Path.GetFileNameWithoutExtension(Binary.Config.OutputFilePath) + ".lib"), "");
     }
 }
Пример #2
0
        /** Generates a public manifest file for writing out */
        public void GenerateManifest(ISTToolChain ToolChain, List<STBuildBinary> Binaries, CPPTargetPlatform Platform, List<string> SpecialRocketLibFilesThatAreBuildProducts)
        {
            string ManifestPath;
            if (STBuildTool.RunningRocket())
            {
                ManifestPath = Path.Combine(STBuildTool.GetUProjectPath(), BuildConfiguration.BaseIntermediateFolder, "Manifest.xml");
            }
            else
            {
                ManifestPath = "../Intermediate/Build/Manifest.xml";
            }

            BuildManifest Manifest = new BuildManifest();
            if (STBuildConfiguration.bMergeManifests)
            {
                // Load in existing manifest (if any)
                Manifest = Utils.ReadClass<BuildManifest>(ManifestPath);
            }

            STTargetPlatform TargetPlatform = CPPTargetPlatformToSTTargetPlatform(Platform);
            var BuildPlatform = STBuildPlatform.GetBuildPlatform(TargetPlatform);

            // Iterate over all the binaries, and add the relevant info to the manifest
            foreach (STBuildBinary Binary in Binaries)
            {
                // Get the platform specific extension for debug info files

                // Don't add static library files to the manifest as we do not check them into perforce.
                // However, add them to the manifest when cleaning the project as we do want to delete
                // them in that case.
                if (STBuildConfiguration.bCleanProject == false)
                {
                    if (Binary.Config.Type == STBuildBinaryType.StaticLibrary)
                    {
                        continue;
                    }
                }
                string DebugInfoExtension = BuildPlatform.GetDebugInfoExtension(Binary.Config.Type);

                // Create and add the binary and associated debug info
                foreach (string OutputFilePath in Binary.Config.OutputFilePaths)
                {
                    Manifest.AddBuildProduct(OutputFilePath, DebugInfoExtension);
                }

                // Add all the stripped debug symbols
                if (STBuildTool.BuildingRocket() && (Platform == CPPTargetPlatform.Win32 || Platform == CPPTargetPlatform.Win64))
                {
                    foreach (string OutputFilePath in Binary.Config.OutputFilePaths)
                    {
                        string StrippedPath = Path.Combine(Path.GetDirectoryName(OutputFilePath), Path.GetFileNameWithoutExtension(OutputFilePath) + "-Stripped" + DebugInfoExtension);
                        Manifest.AddBuildProduct(StrippedPath);
                    }
                }

                if (Binary.Config.Type == STBuildBinaryType.Executable &&
                      GlobalLinkEnvironment.Config.CanProduceAdditionalConsoleApp &&
                      STBuildConfiguration.bBuildEditor)
                {
                    foreach (string OutputFilePath in Binary.Config.OutputFilePaths)
                    {
                        Manifest.AddBuildProduct(STBuildBinary.GetAdditionalConsoleAppPath(OutputFilePath), DebugInfoExtension);
                    }
                }

                ToolChain.AddFilesToManifest(Manifest, Binary);
            }
            {
                string DebugInfoExtension = BuildPlatform.GetDebugInfoExtension(STBuildBinaryType.StaticLibrary);
                foreach (var RedistLib in SpecialRocketLibFilesThatAreBuildProducts)
                {
                    Manifest.AddBuildProduct(RedistLib, DebugInfoExtension);
                }
            }

            if (STBuildConfiguration.bCleanProject)
            {
                CleanTarget(Binaries, Platform, Manifest);
            }
            if (STBuildConfiguration.bGenerateManifest)
            {
                Utils.WriteClass<BuildManifest>(Manifest, ManifestPath, "");
            }
        }
Пример #3
0
 public override void AddFilesToManifest(BuildManifest Manifest, STBuildBinary Binary)
 {
     if (BuildConfiguration.bCreateStubIPA)
     {
         string StubFile = Path.Combine (Path.GetDirectoryName (Binary.Config.OutputFilePath), Path.GetFileNameWithoutExtension (Binary.Config.OutputFilePath) + ".stub");
         Manifest.AddBuildProduct(StubFile);
     }
 }
Пример #4
0
        /// <summary>
        /// Write the project files manifest
        /// This is used by CIS to verify all files referenced are checked into perforce.
        /// </summary>
        protected virtual bool WriteProjectFileManifest()
        {
            BuildManifest Manifest = new BuildManifest();
            foreach (var CurProject in GeneratedProjectFiles)
            {
                foreach (var SourceFile in CurProject.SourceFiles)
                {
                    Manifest.AddBuildProduct(SourceFile.FilePath);
                }
            }

            string ManifestName = Path.Combine(ProjectFileGenerator.IntermediateProjectFilesPath, "UE4SourceFiles.xml");
            Utils.WriteClass<BuildManifest>(Manifest, ManifestName, "");
            return true;
        }