Last active
April 15, 2017 18:24
-
-
Save fleth/44c8bc15eb932e218ec8982daa87905a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using CppSharp; | |
using CppSharp.AST; | |
using CppSharp.Generators; | |
namespace LibMuseCppSharp | |
{ | |
class MuseLibrary : ILibrary | |
{ | |
public void Postprocess(Driver driver, ASTContext ctx) | |
{ | |
} | |
public void Preprocess(Driver driver, ASTContext ctx) | |
{ | |
} | |
public void Setup(Driver driver) | |
{ | |
var options = driver.Options; | |
options.GeneratorKind = GeneratorKind.CSharp; | |
var module = options.AddModule("LibMuse"); | |
module.IncludeDirs.Add("C:/libmuse_6.0.0/windows/include"); | |
module.Headers.Add("muse.h"); | |
module.LibraryDirs.Add("C:/libmuse_6.0.0/windows/lib/release/x64"); | |
module.Libraries.Add("libmuse-uwp.lib"); | |
options.OutputDir = "C:/libmuse_6.0.0"; | |
} | |
public void SetupPasses(Driver driver) | |
{ | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using CppSharp; | |
namespace LibMuseCppSharp | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
ConsoleDriver.Run(new MuseLibrary()); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment