NXPorts 1.1.0
Requires NuGet 4.3 or higher.
dotnet add package NXPorts --version 1.1.0
NuGet\Install-Package NXPorts -Version 1.1.0
<PackageReference Include="NXPorts" Version="1.1.0" />
paket add NXPorts --version 1.1.0
#r "nuget: NXPorts, 1.1.0"
// Install NXPorts as a Cake Addin
#addin nuget:?package=NXPorts&version=1.1.0
// Install NXPorts as a Cake Tool
#tool nuget:?package=NXPorts&version=1.1.0
NXPorts
A MSBuild-integrated library/tool to expose entrypoints in .NET assemblies to the platform invocation system or short PInvoke
.
It allows you to build .NET libraries that can be called from any development platform that supports PInvoke
, including C++, C, Rust, Delphi, Python and so on...
Getting Started
To get started you only have to add the NXPorts
package to your project. That's it. NXPorts
will automatically generate exports as
part of your build now. Some samples are available here.
Prerequisites
This software itself will run on any system that supports developing .NET software - it does not have any dependencies on
ildasm.exe
, ilasm.exe
or any other windows-only libraries.
Keep in mind that Reverse PInvoke
- calling PInvoke entrypoints in .NET assemblies - is only officially supported
in the .NET Framework. It may work in other runtimes as well, but your mileage may vary.
See Compatibility Docs for more info.
Sample
The following code will result in an exported function named SampleExportFunc
:
public static class Exports {
[DllExport(alias:"SampleExportFunc")]
public static double Add(double a, double b)
{
return a + b;
}
}
The following code will result in an exported function named Sum
:
public static class Exports {
[DllExport]
public static double Sum(double a, double b)
{
return a + b;
}
}
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net is compatible. |
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on NXPorts:
Repository | Stars |
---|---|
Reloaded-Project/Reloaded.Injector
C# DLL Injection Library capable of injecting x86 DLLs to x86 process from x64 processes.
|
Version | Downloads | Last updated |
---|---|---|
1.1.0 | 2,080 | 10/31/2021 |
1.0.0 | 22,405 | 7/2/2020 |
0.2.0 | 1,988 | 12/15/2019 |
0.2.0-rc.1 | 214 | 12/4/2019 |
0.2.0-p | 197 | 11/24/2019 |
0.1.0 | 479 | 8/30/2019 |
0.1.0-pre-fa9fc3fd3c0c72d14... | 361 | 8/22/2019 |
0.1.0-pre-a834d6e9d5c65b133... | 331 | 8/20/2019 |