mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-07-20 12:48:32 +00:00
Added support for overriding default output files
This makes it possible to generate different output files when using -mode:all to generate multiple bindings in the same run.
This commit is contained in:
parent
23c084587a
commit
5298aff14d
|
@ -15,7 +15,9 @@ namespace Bind
|
||||||
class Settings
|
class Settings
|
||||||
{
|
{
|
||||||
// Disable BeforeFieldInit.
|
// Disable BeforeFieldInit.
|
||||||
public Settings() { }
|
public Settings()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
public string DefaultInputPath = "../../../Source/Bind/Specifications";
|
public string DefaultInputPath = "../../../Source/Bind/Specifications";
|
||||||
public string DefaultOutputPath = "../../../Source/OpenTK/Graphics/OpenGL";
|
public string DefaultOutputPath = "../../../Source/OpenTK/Graphics/OpenGL";
|
||||||
|
@ -26,9 +28,14 @@ namespace Bind
|
||||||
public string DefaultOverridesFile = "GL2/gloverrides.xml";
|
public string DefaultOverridesFile = "GL2/gloverrides.xml";
|
||||||
public string DefaultLanguageTypeMapFile = "csharp.tm";
|
public string DefaultLanguageTypeMapFile = "csharp.tm";
|
||||||
public string DefaultKeywordEscapeCharacter = "@";
|
public string DefaultKeywordEscapeCharacter = "@";
|
||||||
|
public string DefaultImportsFile = "Core.cs";
|
||||||
|
public string DefaultDelegatesFile = "Delegates.cs";
|
||||||
|
public string DefaultEnumsFile = "Enums.cs";
|
||||||
|
public string DefaultWrappersFile = "GL.cs";
|
||||||
|
|
||||||
string inputPath, outputPath, outputNamespace, docPath, docFile, licenseFile, overridesFile,
|
string inputPath, outputPath, outputNamespace, docPath, docFile, licenseFile, overridesFile,
|
||||||
languageTypeMapFile, keywordEscapeCharacter;
|
languageTypeMapFile, keywordEscapeCharacter, importsFile, delegatesFile, enumsFile,
|
||||||
|
wrappersFile;
|
||||||
public string InputPath { get { return inputPath ?? DefaultInputPath; } set { inputPath = value; } }
|
public string InputPath { get { return inputPath ?? DefaultInputPath; } set { inputPath = value; } }
|
||||||
public string OutputPath { get { return outputPath ?? DefaultOutputPath; } set { outputPath = value; } }
|
public string OutputPath { get { return outputPath ?? DefaultOutputPath; } set { outputPath = value; } }
|
||||||
public string OutputNamespace { get { return outputNamespace ?? DefaultOutputNamespace; } set { outputNamespace = value; } }
|
public string OutputNamespace { get { return outputNamespace ?? DefaultOutputNamespace; } set { outputNamespace = value; } }
|
||||||
|
@ -38,6 +45,10 @@ namespace Bind
|
||||||
public string OverridesFile { get { return overridesFile ?? DefaultOverridesFile; } set { overridesFile = value; } }
|
public string OverridesFile { get { return overridesFile ?? DefaultOverridesFile; } set { overridesFile = value; } }
|
||||||
public string LanguageTypeMapFile { get { return languageTypeMapFile ?? DefaultLanguageTypeMapFile; } set { languageTypeMapFile = value; } }
|
public string LanguageTypeMapFile { get { return languageTypeMapFile ?? DefaultLanguageTypeMapFile; } set { languageTypeMapFile = value; } }
|
||||||
public string KeywordEscapeCharacter { get { return keywordEscapeCharacter ?? DefaultKeywordEscapeCharacter; } set { keywordEscapeCharacter = value; } }
|
public string KeywordEscapeCharacter { get { return keywordEscapeCharacter ?? DefaultKeywordEscapeCharacter; } set { keywordEscapeCharacter = value; } }
|
||||||
|
public string ImportsFile { get { return importsFile ?? DefaultImportsFile; } set { importsFile = value; } }
|
||||||
|
public string DelegatesFile { get { return delegatesFile ?? DefaultDelegatesFile; } set { delegatesFile = value; } }
|
||||||
|
public string EnumsFile { get { return enumsFile ?? DefaultEnumsFile; } set { enumsFile = value; } }
|
||||||
|
public string WrappersFile { get { return wrappersFile ?? DefaultWrappersFile; } set { wrappersFile = value; } }
|
||||||
|
|
||||||
public string GLClass = "GL"; // Needed by Glu for the AuxEnumsClass. Can be set through -gl:"xxx".
|
public string GLClass = "GL"; // Needed by Glu for the AuxEnumsClass. Can be set through -gl:"xxx".
|
||||||
public string OutputClass = "GL"; // The real output class. Can be set through -class:"xxx".
|
public string OutputClass = "GL"; // The real output class. Can be set through -class:"xxx".
|
||||||
|
@ -46,11 +57,6 @@ namespace Bind
|
||||||
public string EnumPrefix = "";
|
public string EnumPrefix = "";
|
||||||
public string NamespaceSeparator = ".";
|
public string NamespaceSeparator = ".";
|
||||||
|
|
||||||
public string ImportsFile = "Core.cs";
|
|
||||||
public string DelegatesFile = "Delegates.cs";
|
|
||||||
public string EnumsFile = "Enums.cs";
|
|
||||||
public string WrappersFile = "GL.cs";
|
|
||||||
|
|
||||||
// TODO: This code is too fragile.
|
// TODO: This code is too fragile.
|
||||||
// Old enums code:
|
// Old enums code:
|
||||||
public string normalEnumsClassOverride = null;
|
public string normalEnumsClassOverride = null;
|
||||||
|
|
Loading…
Reference in a new issue