private static void FindAllSources(string[] sourcesArguments, Sharpmake.Arguments sharpmakeArguments, string startArguments, string[] defines) { MainSources = sourcesArguments; RootPath = Path.GetDirectoryName(sourcesArguments[0]); Assembler assembler = new Assembler(sharpmakeArguments.Builder.Defines); assembler.AttributeParsers.Add(new DebugProjectNameAttributeParser()); IAssemblyInfo assemblyInfo = assembler.LoadUncompiledAssemblyInfo(Builder.Instance.CreateContext(BuilderCompileErrorBehavior.ReturnNullAssembly), MainSources); GenerateDebugProject(assemblyInfo, true, startArguments, new Dictionary <string, Type>(), defines); }
public static void SharpmakeMain(Sharpmake.Arguments arguments) { arguments.Generate <ConfigureOrderingSolution>(); }
/// <summary> /// Generates debug projects and solutions /// </summary> /// <param name="sources"></param> /// <param name="arguments"></param> public static void GenerateDebugSolution(string[] sources, Sharpmake.Arguments arguments) { FindAllSources(sources); arguments.Generate <DebugSolution>(); }
private static void FindAllSources(string[] sourcesArguments, string solutionPath, Sharpmake.Arguments sharpmakeArguments, string startArguments) { MainSources = sourcesArguments; if (!string.IsNullOrEmpty(solutionPath)) { RootPath = solutionPath; if (!Path.IsPathRooted(RootPath)) { RootPath = Path.Combine(Directory.GetCurrentDirectory(), RootPath); } Directory.CreateDirectory(RootPath); } else { RootPath = Path.GetDirectoryName(sourcesArguments[0]); } Assembler assembler = new Assembler(sharpmakeArguments.Builder.Defines); assembler.AttributeParsers.Add(new DebugProjectNameAttributeParser()); IAssemblyInfo assemblyInfo = assembler.LoadUncompiledAssemblyInfo(Builder.Instance.CreateContext(BuilderCompileErrorBehavior.ReturnNullAssembly), MainSources); GenerateDebugProject(assemblyInfo, true, startArguments, new Dictionary <string, Type>(), sharpmakeArguments.Builder.Defines.ToArray()); }