awslabs / aws-crt-dotnet

.NET bindings for the AWS Common Runtime
Apache License 2.0
10 stars 5 forks source link

Support windows arm64 #103

Open Michael-Hering opened 2 weeks ago

Michael-Hering commented 2 weeks ago

Describe the bug

Attempting to use the bindings on windows arm64 and the following exception is thrown:

System.TypeInitializationException: The type initializer for 'API' threw an exception.
 ---> System.TypeInitializationException: The type initializer for 'Aws.Crt.NativeAPI' threw an exception.
 ---> System.TypeInitializationException: The type initializer for 'Aws.Crt.CRT' threw an exception.
 ---> System.InvalidOperationException: Unable to load , exception occurred
 ---> System.IO.IOException: Could not find aws-crt-dotnet-ARM64.dll in resource manifest; Resources=Aws.CRT.libaws-crt-dotnet-ARM64.dylib,Aws.CRT.libaws-crt-dotnet-x64.dylib,Aws.CRT.libaws-crt-dotnet-ARM64.so,Aws.CRT.libaws-crt-dotnet-x64.so,Aws.CRT.aws-crt-dotnet-x64.dll,Aws.CRT.aws-crt-dotnet-x86.dll
   at Aws.Crt.CRT.PlatformBinding.ExtractLibrary(String libraryName)
   at Aws.Crt.CRT.PlatformBinding..ctor()
   --- End of inner exception stack trace ---
   at Aws.Crt.CRT.PlatformBinding..ctor()
   at Aws.Crt.CRT..cctor()
   --- End of inner exception stack trace ---
   at Aws.Crt.CRT.get_Binding()
   at Aws.Crt.NativeAPI..cctor()

Can we please support windows arm64?

Expected Behavior

The dll should be loaded correctly.

Current Behavior

When attempting to load the dll, an exception is thrown because there is not support for arm64 windows.

Reproduction Steps

call new HashingWrapperCRC32C().ComputeHash(stream) from a dotnet project running on windows arm64

Possible Solution

No response

Additional Information/Context

No response

aws-crt-dotnet version used

0.4.3

dotnet version used

8.0

Operating System and version

Windows 11 arm64

Michael-Hering commented 2 weeks ago

this seems related to a similar issue previously faced on macos: https://github.com/awslabs/aws-crt-dotnet/issues/75

jmklix commented 2 weeks ago

This is a feature request for us to add the binaries to the dotnet bindings. This is something that we want to do, but I don't have a timeline for when this might get added. Similar feature request: https://github.com/awslabs/aws-c-common/issues/1042