Skip to content
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

a patch to Makefile.menhir for ocaml-non-native architctures. #502

Conversation

yozot
Copy link

@yozot yozot commented Aug 23, 2023

OpenBSD ports recently updated CompCert to 3.13, but does not work for ocaml-non-native architectures.
The problem comes from Makefile.menhir expecting either menhirLib.cmxa or .cmx is available.
It assumes ocaml native compilation environment.

This patch adds one more condition using OCAML_NATIVE_COMP which is prepared by configure, to adjust MENHIR_LIBS according to ocaml-native or ocaml-non-native environment.
I confirmed this patch works in OpenBSD ports, and believe it's useful for any other environments.

@xavierleroy
Copy link
Contributor

Thanks for the patch and apologies for the late reply. I think that with recent enough versions of Menhir the issue goes away, because the library is always menhirLib.cmxa or menhirLib.cma, but no longer menhirLib.cmx nor menhirLib.cma. Then, the general .cmxa -> .cma rule for bytecode-only builds in Makefile.extr handles the situation. Or so it seems on my test.

I'm closing this PR, but please do comment if I missed something.

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants