Open jplgarcia opened 3 years ago
Please follow our issue template and attach full information from the Data tab.
But I think you're just trying combine mentioned win-x64 runtime for x86+x64 configuration, that's incorrect. Check this out and reconfigure for x64.
Did you handle the issue like describe here https://github.com/dotnet/runtime/issues/33590 ?
Seems for .NET Core dll injection is not supported anymore.
Hi!
I have the exact same issue publishing a simple DllExport project targeted for .NET Core 3.1.
v1.7.3.58831+9a4bc51
win-x86
I've created simple .NET Core Class Library project, added most recent DllExport package from NuGet, configured the project for x86 (using workaround from #175) and when trying to publish the project, I get the same issue as stated above with the following error in the Output log:
Build started...
1>------ Build started: Project: DllExportTest, Configuration: Release x86 ------
1>DllExportTest -> [...]\DllExportTest\bin\x86\Release\netcoreapp3.1\win-x86\DllExportTest.dll
2>------ Publish started: Project: DllExportTest, Configuration: Release x86 ------
2>Determining projects to restore...
2>Restored [...]\DllExportTest\DllExportTest.csproj (in 291 ms).
2>DllExportTest -> [...]\DllExportTest\bin\x86\Release\netcoreapp3.1\win-x86\DllExportTest.dll
2>The file '[...]\DllExportTest\bin\x86\Release\netcoreapp3.1\win-x86\DllExportTest.pdb' to be packed was not found on disk.
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
Project builds without any issue but publish fails every time, tried also changing parameters with no luck.
I'm attaching the whole sample project if it helps. DllExportTest.zip
Thanks! ✌
Not sure what happened, but .NET Core version does not work properly. Manual conversion via NDDE works, but it generates separate unmanaged dll.
@supermartzin,
... pdb to be packed was not found on disk.
Your problem seems a bit different comparing this issue. Could you please open a new one. Thanks!
@mikasoukhov,
Seems for .NET Core dll injection is not supported anymore.
Make sure you're using my custom IL assembler together with rebasing (see related options) // #123 I can't say anything else without requested information.
I use Nuget package.
Think the reason was described here https://github.com/3F/DllExport/issues/175
Now no official instruction works with VS. Neither bat, no Nuget. Maybe someone will publish a quick solution or update the instruction. New projects for .NET Core is fully unsupportable )
Is this closed by now?
Steps to reproduce:
DllExport -version
: 1.7.3Information from
Data
tab or log data:Every time I try to publish my DLL by right clicking and hitting publish I set target to my local folder configuration release, target framework .netcoreapp3.0 target runtime win-x64
The build and rebuild work fine but whenI publish I receive the following message " Publishing has encountered an error. Publishing has failed
A Diagnostic log has been written to the following location: "c:\User.....\AppData\Local\Temp\filename.tmp" "
Checking the file I receive an error that does not help very much:
2020-0
My code is no more than the following class:
using System; using System.Runtime.InteropServices;
namespace ClassLibrary2 { public class Class1 { [DllExport("Add2", CallingConvention.Cdecl)] public static int testAdd(int a, int b) { return a + b; }
}