-
Notifications
You must be signed in to change notification settings - Fork 412
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
[macOS] dune
3.11.1 errors (build itself works now, but building some of dependents fails)
#8941
Comments
What macos version are you using? |
@Alizter This is on 10.6, so pretty old, but it is the last one to run on PowerPC. I only get this error with |
@barracuda156 We recently switched to using clone file on macos: The issue in this case is that the stubs don't compile in the case that copyfile is unavailable. @rgrinberg are there any work arounds to this? According to the man pages, this API was introduced in 10.5. https://www.unix.com/man-page/mojave/3/copyfile/ So theoretically this should be available. |
It seems that we could do something similar:
|
@Alizter That would be very helpful if you could add an appropriate fallback from your side. We can do testing then. 10.4 is not really a concern, IMO, but having 10.5–10.6 working on PPC would be great. (I think 10.6 may be still used on some older Intel too.) |
@barracuda156 Try this PR. I can't test it myself as I don't have a powerpc VM setup. Hopefully this fixes the issue, if not we will need to think a little harder. |
@Alizter Thank you, I will test this tonight and update here. |
@Alizter After applying the patch to
What could I try now? |
If you try
this should disable Dune's digest and sandbox code from running in background threads. I believe these were recently enabled on macos in #8090. This simply avoids the problem with posix_spawn on this older macos version. I have no idea as to why it doesn't work however. |
@Alizter Oh well, code there has errors:
UPD1. While these should still be fixed, I believe, the error results from something else. UPD2. Discussion is in #8090 |
@Alizter @rgrinberg Could you please comment on the errors with 3.11.1 when trying to build dependents?
Ref to #8090 (comment) |
copyfile_stubs.c:45:39: error: 'COPYFILE_CLONE' undeclared (first use in this function); did you mean 'COPYFILE_MOVE'?
dune
3.11.1 errors (build itself works now, but building dependents fails)
Unfortunately Dune support for building the compiler itself is quite lacking. So I wouldn't recommend trying it unless your know what you are doing. If however you do want to press on https://github.com/ocaml-flambda/flambda-backend is a version of the compiler where they are developing compiler optimisations, and notably they have a much better time building (their fork of) the compiler with Dune. So there might be some things to learn there. Unfortunately its unlikely we will be able to help you with the compiler build as it relies a lot on a custom rule set and custom layout. Which isn't really up to us to make sure it works properly. The recommended option would be to use |
@Alizter Thank you. Here what I tried to build was |
For your specific issue: I suspect that even with the But look, we're not going to be actively looking for solutions about how to use dune 3.11 on macos 10.6. The dev team is already low on resources and we can't support a platform that has been EOL for more than 10 years. Put differently, you're on your own here. If you come up with a 1-line fix that restores support, why not, but we can't help you with that. |
@Alizter @rgrinberg Update on @emillon I got you. Once I am sure that everything works neatly, I will submit a PR. |
dune
3.11.1 errors (build itself works now, but building dependents fails)dune
3.11.1 errors (build itself works now, but building some of dependents fails)
How could we fix this?
The text was updated successfully, but these errors were encountered: