示例#1
0
        protected virtual CompilerOptions CreateOptionsForSupportingAssembly(SetupCompileInfo setupCompileInfo, NPath outputDirectory, NPath[] sourceFiles, NPath[] references, string[] defines)
        {
            var allDefines    = defines.Concat(setupCompileInfo.Defines ?? new string [0]).ToArray();
            var allReferences = references.Concat(setupCompileInfo.References?.Select(p => MakeSupportingAssemblyReferencePathAbsolute(outputDirectory, p)) ?? new NPath [0]).ToArray();

            return(new CompilerOptions
            {
                OutputPath = outputDirectory.Combine(setupCompileInfo.OutputName),
                SourceFiles = sourceFiles,
                References = allReferences,
                Defines = allDefines
            });
        }
示例#2
0
        protected virtual CompilerOptions CreateOptionsForSupportingAssembly(SetupCompileInfo setupCompileInfo, NPath outputDirectory, NPath[] sourceFiles, NPath[] references, string[] defines, NPath[] resources)
        {
            var allDefines    = defines.Concat(setupCompileInfo.Defines ?? new string[0]).ToArray();
            var allReferences = references.Concat(setupCompileInfo.References?.Select(p => MakeSupportingAssemblyReferencePathAbsolute(outputDirectory, p)) ?? new NPath[0]).ToArray();

            string[] additionalArguments = string.IsNullOrEmpty(setupCompileInfo.AdditionalArguments) ? null : new[] { setupCompileInfo.AdditionalArguments };
            return(new CompilerOptions {
                OutputPath = outputDirectory.Combine(setupCompileInfo.OutputName),
                SourceFiles = sourceFiles,
                References = allReferences,
                Defines = allDefines,
                Resources = resources,
                AdditionalArguments = additionalArguments,
                CompilerToUse = setupCompileInfo.CompilerToUse?.ToLower()
            });
        }
示例#3
0
 private NPath[] CollectSetupAfterSourcesFiles(SetupCompileInfo info)
 {
     return(CollectSourceFilesFrom(_sandbox.AfterReferenceSourceDirectoryFor(info.OutputName)));
 }
示例#4
0
 private NPath[] CollectSetupAfterResourcesFiles(SetupCompileInfo info)
 {
     return(_sandbox.AfterReferenceResourceDirectoryFor(info.OutputName).Files().ToArray());
 }