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

docker dev container: explicit platform, install pkg-config #3547

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

amosr
Copy link
Contributor

@amosr amosr commented Oct 10, 2024

Hi,
The docker dev container wasn't working for me on an M1 Mac. I fixed it by specifying AMD64 emulation. I believe this change should not affect other x86 users.

  • Set platform to amd64 so it works on M1 Macs. Otherwise the Z3 binary had the wrong architecture.
  • Install pkg-config with apt. Otherwise the opam was failing for me.

@amosr
Copy link
Contributor Author

amosr commented Oct 11, 2024

I found that I also needed to add this environment variable to get dotnet working:

ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=true

However, even with these fixes, I still can't get make ci to succeed locally... hmm

$ make ci
...
/workspaces/FStar/bin/fstar.exe --ext context_pruning   --warn_error +240  --use_hints   --extract Bug3473 --codegen OCaml Bug3473.fst
Extracted module Bug3473
Verified module: Bug3473
All verification conditions discharged successfully
diff -u --strip-trailing-cr Bug3473.ml Bug3473.ml.expected
make[4]: Leaving directory '/workspaces/FStar/tests/bug-reports'
make -C coercions all
make[4]: Entering directory '/workspaces/FStar/tests/coercions'
Makefile:12: warning: overriding recipe for target 'clean'
../../examples/Makefile.common:114: warning: ignoring old recipe for target 'clean'
make[4]: *** No rule to make target '/Users/amos/proj/ext/fstar/FStar/ulib/FStar.BV.fsti', needed by '/Users/amos/proj/ext/fstar/FStar/bin/../ulib/.cache/FStar.BV.fsti.checked'.  Stop.
make[4]: Leaving directory '/workspaces/FStar/tests/coercions'
make[3]: *** [Makefile:32: coercions.all] Error 2
make[3]: Leaving directory '/workspaces/FStar/tests'
make[2]: *** [Makefile:64: utests] Error 2
make[2]: Leaving directory '/workspaces/FStar/src'
make[1]: *** [Makefile:198: ci-uregressions] Error 2
make[1]: Leaving directory '/workspaces/FStar'
make: *** [Makefile:158: ci] Error 2

Set platform to amd64 so it works on M1 Macs. Otherwise the Z3 binary had the wrong architecture.

Install pkg-config with apt. Otherwise the opam was failing for me.
@mtzguido
Copy link
Member

Thanks Amos, I'll take a look. I haven't been using this and it's not under CI. This minimal devcontainer could probably be unified with the one we use for CI (base.Dockerfile), though I'm also in the process of replacing all this.

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