static void Main(string[] args) { var chakraInfo = new ChakraInfo { ChakraPath = @"C:\Projects\ChakraCore" }; var chakraSharp = new ChakraSharp(chakraInfo); ConsoleDriver.Run(chakraSharp); var settings = new XmlWriterSettings() { Indent = true }; using (var writer = XmlWriter.Create("ChakraExternDefinitions.xml", settings)) { chakraSharp.XmlExport.WriteTo(writer); } Console.WriteLine("Generated 'ChakraExternDefinitions.xml'"); Console.WriteLine("Press enter to continue..."); Console.ReadLine(); }
public static void Main(string[] args) { ConsoleDriver.Run(new Lib()); Move($"{modulename}.cs"); Move($"{modulename}-symbols.cpp"); }
static void Main(string[] args) { Console.WriteLine("Hello World!"); ConsoleDriver.Run(new AzureKinectDKSharp()); Console.WriteLine("Done"); Console.ReadKey(); }
static void Main(string[] args) { if (args.Length < 2) { return; } LibGDSharp libGdSharp; switch (args.Length) { case 0: libGdSharp = new LibGDSharp("../../../../", "../../../../build/lib/libimageflow.a"); break; case 2: libGdSharp = new LibGDSharp(args[0], args[1]); break; case 3: libGdSharp = new LibGDSharp(args[0], args[1], args[2]); break; default: Console.WriteLine("Usage: LibGD.CLI.exe [include_dir_of_libd] [GCC/MinGW_make_exe (optional) - skip for VC++] [library(.dll)_file]"); Console.WriteLine("Unexpected number of arguments"); return; } if (!Directory.Exists(args[0])) { Console.WriteLine("{0} does not exist or is not a directory.", args[0]); return; } if (!File.Exists(args[1])) { Console.WriteLine(args.Length > 2 ? "{0} does not exist or is not a directory." : "{0} does not exist.", args[1]); return; } if (args.Length > 2 && !File.Exists(args[2])) { Console.WriteLine("{0} does not exist.", args[2]); return; } using (new ConsoleCopy("gd-cppsharp-log.txt")) { ConsoleDriver.Run(libGdSharp); } }
private void RunButton_Click(object sender, EventArgs e) { if (module != null) { GeneratorKind mode = GeneratorKind.CSharp; if (radioButton4.Checked) { mode = GeneratorKind.CSharp; } if (radioButton5.Checked) { mode = GeneratorKind.CLI; } if (radioButton6.Checked) { mode = GeneratorKind.C; } if (radioButton7.Checked) { mode = GeneratorKind.CPlusPlus; } if (radioButton8.Checked) { mode = GeneratorKind.ObjectiveC; } if (radioButton9.Checked) { mode = GeneratorKind.Java; } // std.cs生成 File.Copy(Application.StartupPath + @"\Std.cs", bindPath + @"\Std.cs", true); // SymbolResolver.cs生成 File.Copy(Application.StartupPath + @"\SymbolResolver.cs", bindPath + @"\SymbolResolver.cs", true); var builder = new BuildLib(module, mode); ConsoleDriver.Run(builder); } Process.Start(bindPath); module = null; Environment.Exit(0); }