Open kurt-mueller-osumc opened 1 year ago
net7.0 projects can use net5.0 libraries. There are issues on windows, but mac should be fine.
What's the specific issue that you're encountering?
Bumping target framework to net7.0 blocks things still on net5.0, but keeping on 5.0 shouldn't affect 7.0. Unless there's something specific that you're running into?
Is there a specific issue - is this the one in #261? RProvider already supports .net 5+ and apple silicon macs
I have an example repo here: https://github.com/EverybodyKurts/rprovider-net8
Run this on an M1+ Mac in a docker container:
$ dotnet fsi script.fsx
chmod: cannot access "'/home/vscode/.nuget/packages/rprovider/2.1.0/lib/net5.0/server/linux-x64/RProvider.Server'": No such file or directory
rosetta error: failed to open elf at /lib64/ld-linux-x86-64.so.2
I don’t know docker, so take with a grain of salt: I think your dockerfile makes it think that it’s running on Debian Linux, hence looking for server/linux-x64/RProvider.Server. See here: https://github.com/devcontainers/images/tree/main/src/base-debian
If you change your dockerfile to think it’s on Mac, does that fix it?
Indeed, I am running a debian linux container on my m1 mac. dotnet build
for most projects works just fine. The container also returns its underlying architecture as aarch64
:
$ uname -a
Linux a1917383b162 6.6.12-linuxkit #1 SMP Thu Feb 8 06:36:34 UTC 2024 aarch64 GNU/Linux
Here is where the exe paths are specified:
Supported runtimes:
https://github.com/fslaborg/RProvider/blob/008c08476d04eda984be5564e367f93954062f38/build.fsx#L72
Target frameworks:
aarch64
is not on the list unfortunately.
Ok, so it sounds like it may not be an m1 macOS issue. It seems to be an arm64-Linux issue.
Can you use a macOS container on your m1 Mac? RProvider works on m1 Mac under macOS.
Probably also adding aarch64 to the list of server runtimes in build.fsx would fix that. Maybe try adding that line and building the library. If that makes it work then could submit it as a pr?
hmm, exe path also probably needs updating. Good point.
@kurt-mueller-osumc Your simplest solution is macOS host instead of Debian Linux.
@AndrewIOM this is why it's netstandard2.0: https://github.com/fslaborg/RProvider/pull/222
That was almost 3 years ago though so things could be different.
(sorry, just realized I put this in the wrong place. Should be on Kurt's PR).
Is your feature request related to a problem? Please describe.
I'd like to be able to use rprovider in net7.0 on my M1 Mac.
Describe the solution you'd like Update project to be net7.0 compatabile.