Skip to content
Accurate and high performance C++ interop code generator for C#.
C++ C C# Other
Branch: master
Clone or download

Latest commit

Latest commit d14e0b4 Jan 19, 2020

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github Add configuration for Release Drafter. Sep 5, 2018
CastXML Update CastXML to a build based off Clang 7.0 Oct 13, 2018
SdkTests Merge branch 'feature/exception-callback' into feature/exception-call… Jan 13, 2020
SharpGen.Interactive Enable users to instruct SharpGenTools to only generate code for a su… May 17, 2019
SharpGen.Runtime.UnitTests Change to using coverlet instead of OpenCover. (#132) Jul 12, 2019
SharpGen.Runtime
SharpGen.UnitTests Change to using coverlet instead of OpenCover. (#132) Jul 12, 2019
SharpGen Merge branch 'feature/exception-callback' into feature/exception-call… Jan 13, 2020
SharpGenTools.Sdk Run generation before BeforeCompile. Fixes #149 Oct 20, 2019
SharpPatch.Cli Remove legacy SharpPatch patching. Apr 21, 2019
SharpPatch Remove legacy SharpPatch patching. Apr 21, 2019
build Make usage of VisualStudio 2019 generator explicit. Oct 20, 2019
docs Fill in platform detection documentation. Jul 11, 2019
refs/SharpGen.Runtime.Refs Update MSBuild.SDK.Extras and don't pack the refs project. May 9, 2019
.editorconfig Convert dependencies to Nuget packages where possible and add back in… May 12, 2017
.gitignore Change to using coverlet instead of OpenCover. (#132) Jul 12, 2019
Directory.Build.props Define build version by non-appveyor-specific environment variables. … Jul 18, 2019
Directory.Build.targets Refactor MSDN Doc Provider into it's own task assembly and refactor t… Feb 16, 2018
LICENSE.txt Add package metadata. Sep 5, 2017
README.md
SdkPackage.targets Change to using coverlet instead of OpenCover. (#132) Jul 12, 2019
SharpGenTools.sln Use MSBuild.Sdk.Extras new RID support to prototype an xplat correct … Jul 10, 2018
azure-pipelines.yml Enable deployment to NuGet.org. Jul 19, 2019
build.ps1 Make SharpGen.Interactive Avalonia-based to it can run on .NET Core a… Mar 14, 2018
global.json update msbuild.sdk.extras Oct 20, 2019
test.ps1 Refactor codecov upload to support azp. Jul 19, 2019

README.md

SharpGenTools

Build Status MyGet Pre Release NuGet Docs codecov CodeFactor

Accurate and high performance C++ interop code generator for C#.

Features

  • Accurate, fast code-gen for C++ and COM interfaces from their C++ headers.
  • No dependencies on .NET Runtime COM support
  • Supports passing code-gen information through MSBuild project and package references
  • Pluggable Runtime Library Name and runtime support type names (default library is SharpGen.Runtime)
    • Projects that implement their own SharpGenTools runtime support classes can add mapping rules to ensure that their generated code uses their runtime support library.

Components in this Repo

  • SharpGen
    • The code-gen engine that runs CastXML to parse the C++ and then generates the C# interop code.
  • SharpPatch
    • Patches the calli instructions for efficient C++ interop as well as other constructs not possible in C#
  • SharpGenTools.Sdk
    • MSBuild tooling to integrate SharpGen and SharpPatch directly into projects
  • SharpGen.Runtime
    • Runtime support classes for code generated by SharpGen.
  • SharpGen.Interactive
    • Legacy command line front-end for SharpGen with Avalonia progress-dialog
    • Xplat version of original SharpGen application
  • SharpPatch.Cli
    • Legacy command line front-end for SharpPatch
    • The original SharpCli application

Requirements

To Use

  • Any projects using the SDK to generate code must use new SDK-style projects with MSBuild 15.3 or higher (.NET Core 2.0 SDK or VS 2017.3)
  • Make any mapping files a SharpGenMapping item in your .csproj.

To Build

  • MSBuild 15.3 or newer.
  • .NET Core 2.0
  • CMake 3.0 or newer.
You can’t perform that action at this time.