I'm developing a dotnet core 3.1 console app using C# on windows which should generate a dll to be used on a Ubuntu machine.
From a third-party I've got 3 DLLs (ext.dll, ext64.dll, extNet.dll) which are needed for communicating with another device in the same network. To program the app I only need extNet.dll, the other two must be however present as extNet.dll is internally requiring them.
Using Visual Studio 2019 Community, when I try to add the 3 ext*.dll files to the "Dependencies > Assemblies" of my project, ext.dll and ext64.dll will fail with the error
"The reference is invalid or unsupported"
Only the extNet.dll can be added without problems.
I can program my app, and when trying to run, it will give the error:
"System.DllNotFoundException: Unable to load DLL 'ext64.dll' or one of its dependencies: The specified module was not found. (0x8007007E)"
When I simply copy both files (ext.dll, ext64.dll) to my Project/bin/Debug/netcoreapp3.1/
folder and try to run again, the app will work with no problems on my windows machine.
I then copied all the contents of Project/bin/Debug/netcoreapp3.1/
(including ext.dll and ext64.dll) to my Ubuntu machine, and try to run... but on Linux it will continue failing with
"System.DllNotFoundException: Unable to load DLL 'ext64.dll' or one of its dependencies: The specified module was not found. (0x8007007E)"
On Ubuntu I have dotnet version 3.1.102, with following runtimes installed:
On Windows, I have dotnet version 3.1.102, with following runtimes installed:
I've tried to manually add the References on my *.csproj
file, but that does not works either:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp3.1</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<Reference Include="extNet">
<HintPath>..\dlls\extNet.dll</HintPath>
</Reference>
<Reference Include="ext">
<HintPath>..\dlls\ext.dll</HintPath>
</Reference>
<Reference Include="ext64">
<HintPath>..\dlls\ext64.dll</HintPath>
</Reference>
</ItemGroup>
</Project>
Questions..
User contributions licensed under CC BY-SA 3.0