https://github.com/baristalabs/chakrasharp
Mono/.NET bindings for ChakraCore
https://github.com/baristalabs/chakrasharp
chakra cppsharp pinvoke
Last synced: 1 day ago
JSON representation
Mono/.NET bindings for ChakraCore
- Host: GitHub
- URL: https://github.com/baristalabs/chakrasharp
- Owner: BaristaLabs
- License: mit
- Created: 2017-01-18T22:33:39.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-08-18T00:59:32.000Z (over 6 years ago)
- Last Synced: 2025-04-22T11:17:11.156Z (1 day ago)
- Topics: chakra, cppsharp, pinvoke
- Language: C#
- Size: 28.3 KB
- Stars: 14
- Watchers: 6
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ChakraSharp
A quick & dirty pass at generating a [ChakraCore](https://github.com/Microsoft/ChakraCore) P/Invoke layer in C# using [CppSharp](https://github.com/mono/CppSharp)
Note: [ChakraSharpCastXml](https://github.com/BaristaLabs/ChakraCoreCastXml) is an improvement over the approach offered here.
### Advantages
- Generates P/Invoke layer directly from ChakraCore Jsrt headers; any changes and additions made to ChakraCore can be integrated quickly and easily without manual porting
- Function and parameter descriptions contained in the Jsrt headers are retained and included in the generated cs file.
- Customization of the generated code can be performed by forking this project and adding/changing the passes.
### Instructions
1. Clone this repo
2. Clone Microsoft/ChakraCore - you won't need to build Chakra as the headers are used to generate the P/Invoke. In your implementing program you can use the version on NuGet.
3. Ensure that the path in ChakraShare.CLI/Program.cs points to the path where ChakraCore was cloned.
4. Build and run ChakraSharp.CLI -- ChakraCore.cs will be generated. Take this file and use it in the application that you'd like to use Chakra in.For a sample of how to use the generated ChakraCore.cs file, see [ChakraSharp-Sample](https://github.com/BaristaLabs/ChakraSharp-Sample)
For a high-level object model, see [BaristaCore](https://github.com/BaristaLabs/BaristaCore)