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

Fails to compile in Apple M1 #33

Open
davesnx opened this issue May 28, 2021 · 1 comment
Open

Fails to compile in Apple M1 #33

davesnx opened this issue May 28, 2021 · 1 comment

Comments

@davesnx
Copy link

davesnx commented May 28, 2021

Hey,

Trying to install opam-lock like following: opam install opam-lock which depends on opam-solver which depends on ocaml-mccs. Fails at compiling mccs.1.1+13.

  • opam 2.0.8
  • ocaml 4.10.0
[ERROR] The compilation of mccs failed at "/Users/davesnx/.opam/opam-init/hooks/sandbox.sh build dune build -p mccs -j 7".

#=== ERROR while compiling mccs.1.1+13 ========================================#
# context     2.0.8 | macos/x86_64 | ocaml-base-compiler.4.10.0 | https://opam.ocaml.org#44953419
# path        ~/Code/github/counter-as-a-service/_opam/.opam-switch/build/mccs.1.1+13
# command     ~/.opam/opam-init/hooks/sandbox.sh build dune build -p mccs -j 7
# exit-code   1
# env-file    ~/.opam/log/mccs-8358-335865.env
# output-file ~/.opam/log/mccs-8358-335865.out
### output ###
# [...]
# In file included from ./abstract_criteria.h:13:
# In file included from ./cudf.h:24:
# In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/vector:276:
# In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/__bit_reference:15:
# In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/algorithm:643:
# In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/memory:671:
# In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/new:93:
# /Users/davesnx/Code/github/counter-as-a-service/_opam/lib/ocaml/version:1:1: error: expected unqualified-id
# 4.10.0
# ^
# fatal error: too many errors emitted, stopping now [-ferror-limit=]
# 20 errors generated.

Is there anything I'm missing in my setup? or something I can add in this issue?

Thanks

@dra27
Copy link
Member

dra27 commented Jun 7, 2021

This is caused by using a C++20 compiler and was fixed in ocaml/ocaml#9895. Are you able to use OCaml 4.12 instead? A safe workaround should be simply to delete /Users/davesnx/Code/github/counter-as-a-service/_opam/lib/ocaml/version.

LasseBlaauwbroek added a commit to coq-tactician/platform that referenced this issue Feb 8, 2022
This also means using Coq dev packages, because otherwise the version constrains
are to tight
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

No branches or pull requests

2 participants