-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
libR-sys bindings for Apple M1 #35
Comments
(please be gentle, haven't done anything like this in almost 20 years, new to GitHub) Apple Silicon MBPro (M1), running Big Sur 11.1 I installed bindgen: I used git to get libR-sys: Then I ran Next I got error: Based on: This resulted in: target dir seems new, not sure how to test what I got... |
You can test with:
Also, could you do the following? Rebuild with:
and then post the tail end of the output you get, starting from Finally, I think you had all these setup problems because you added the path to the homebrew llvm at the end of the existing path rather than at the beginning. Also, installing bindgen is not necessary. |
Running the test command:
Here's the output for:
|
Sorry, my mistake:
|
@Ilia-Kosenkov Do you think you could set up cross-compilation of bindings for Apple M1? The target tripel is |
@clauswilke, |
@clauswilke, We are now able to compile, consume and test bindings on Windows using a single instance (so reduced number of virtual machines are required). However, I am unable to build for It would be nice if someone can use an |
@Ilia-Kosenkov The problem is that the Apparently it's possible to turn on Big Sur, though: actions/runner-images#1814 |
@clauswilke, As of writing this message, my previous CI run is waiting for more than 30 minutes. |
OK, there is some progress, I will hopefully finish the script later today. |
Here's the output:
|
If you'd like me to test something else, another version or a binary perhaps, let me know. |
@psobolewskiPhD Thanks for your efforts so far. They show that the bindings can be generated and compiled on M1. The next step will be to pre-compile bindings and add them to the repo. We normally do this mostly automated on GitHub Actions, and @Ilia-Kosenkov is looking into this right now. If he succeeds, it would be good if you could test the precomputed bindings as well. If he doesn't, we may ask you to send us the bindings your compilation generated. |
@clauswilke, @psobolewskiPhD It says it is unable to locate Lines 368 to 374 in 07dac17
Is it possible |
It may require properly set |
Welp, there is an issue in |
They're just creating symlinks from the installed version of R to /usr/local/bin, this should work for us the same. |
@clauswilke, |
After an hour of waiting, here is a new error |
See: |
@clauswilke, |
Probably. Apologies for the terse answers, on my phone. |
@clauswilke, its OK, I just have no experience with Macs and I think that path @psobolewskiPhD used is super-specific and we should not rely on hard-coded values. |
I would try setting On my machine (which doesn't run Big Sur):
|
Sorry,
|
Good news -- it works, we have bindngs.
As soon as we decide on this, I'll make a PR with new precomputed bindings which then can be tested by M1 owners. |
FYI, these are environments that are currently set up |
Let me know when/what you'd like tested, just probably need to spell it out like to a 2-year-old... |
OK, here I infer llvm paths using @clauswilke, we still have to decide on what Mac configs to use. @psobolewskiPhD, will let you know as soon as we are ready. |
R release is good. I don't have a strong opinion on Rust stable or nightly, whichever you prefer. |
@psobolewskiPhD, we have merged #45, so now there are bindings for Could you please fetch/clone latest cargo test -vv -- --nocapture --test-threads=1 |
I think it worked?
|
Fantastic! This was all around easier than I expected. I'm closing this issue. Let's open a new one if any problems crop up. |
Sooner rather than later, we will need bindings for Apple M1 chips. One strategy we could pursue is to cross-compile, as we're already doing for our Windows bindings. The only downside is that we can't test whether the bindings actually work.
Here's a relevant issue about Github Action runners on M1: actions/runner-images#2187
The text was updated successfully, but these errors were encountered: