ocaml.org
ocaml.org copied to clipboard
Setting up switch for ocaml.org fails
When building rocq-prover.org I ran into an issue with setting up the opam switch. The same problem happens when setting up the switch for ocaml.org (CC @mattam82 @tabareau).
I'm using
$ opam --version
2.3.0
and when I do make switch I get
#=== ERROR while compiling dyn.3.15.3 =========================================#
# context 2.3.0 | linux/x86_64 | ocaml-system.5.2.0 | git+https://github.com/ocaml/opam-repository#c45f5bab71d3589f41f9603daca5acad14df0ab0
# path ~/research/ocaml.org/_opam/.opam-switch/build/dyn.3.15.3
# command ~/.opam/opam-init/hooks/sandbox.sh build dune build -p dyn -j 7 @install
# exit-code 1
# env-file ~/.opam/log/dyn-14066-b7dea4.env
# output-file ~/.opam/log/dyn-14066-b7dea4.out
### output ###
# [...]
# 1 | (lang dune 3.16)
# ^^^^
# Error: Version 3.16 of the dune language is not supported.
# Supported versions of this extension in version 3.16 of the dune language:
# - 1.0 to 1.12
# - 2.0 to 2.9
# - 3.0 to 3.15
# -> required by library "dyn" in _build/default/otherlibs/dyn
# -> required by _build/default/META.dyn
# -> required by _build/install/default/lib/dyn/META
# -> required by _build/default/dyn.install
# -> required by alias install
#=== ERROR while compiling base.v0.17.0 =======================================#
# context 2.3.0 | linux/x86_64 | ocaml-system.5.2.0 | git+https://github.com/ocaml/opam-repository#c45f5bab71d3589f41f9603daca5acad14df0ab0
# path ~/research/ocaml.org/_opam/.opam-switch/build/base.v0.17.0
# command ~/.opam/opam-init/hooks/sandbox.sh build dune build -p base -j 7
# exit-code 1
# env-file ~/.opam/log/base-14066-19a2ac.env
# output-file ~/.opam/log/base-14066-19a2ac.out
### output ###
# [...]
# -> required by _build/default/src/mpopcnt.sexp
# -> required by (:include _build/default/src/mpopcnt.sexp) at src/dune:23
# -> required by _build/default/src/am_testing.o
# -> required by _build/default/src/dllbase_stubs.so
# -> required by _build/install/default/lib/stublibs/dllbase_stubs.so
# -> required by _build/default/base.install
# -> required by alias install
# (cd _build/default && /usr/bin/ocamlopt.opt -w -40 -g -I src/.base.objs/byte -I src/.base.objs/native -I /home/yannick/research/ocaml.org/_opam/lib/ocaml_intrinsics_kernel -I /home/yannick/research/ocaml.org/_opam/lib/sexplib0 -I hash_types/src/.base_internalhash_types.objs/byte -I hash_types/src/.base_internalhash_types.objs/native -I shadow-stdlib/src/.shadow_stdlib.objs/byte -I shadow-stdl[...]
# File "src/array.ml", line 399, characters 28-75:
# 399 | result := Bool.select ((keep_left_if [@inlined]) (compare x !result)) x !result
# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# Warning 55 [inlining-impossible]: Cannot inline: Unknown function
<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
┌─ The following actions failed
│ λ build base v0.17.0
│ λ build dyn 3.15.3
Afterwards installed packages:
opam list
# Packages matching: installed
# Name # Installed # Synopsis
astring 0.8.5 Alternative String module for OCaml
base-bigarray base
base-bytes base Bytes library distributed with the OCaml compiler
base-domains base
base-nnp base Naked pointers prohibited in the OCaml heap
base-threads base
base-unix base
camlp-streams 5.0.1 The Stream and Genlex libraries for use with Camlp4 and Camlp5
chrome-trace 3.15.3 Chrome trace event generation library
cmdliner 1.3.0 Declarative definition of command line interfaces for OCaml
csexp 1.5.2 Parsing and printing of S-expressions in Canonical form
dune 3.15.3 Fast, portable, and opinionated build system
dune-build-info 3.15.3 Embed build information inside executable
dune-configurator 3.15.3 Helper library for gathering system configuration
either 1.0.0 Compatibility Either module
fix 20230505 Algorithmic building blocks for memoization, recursion, and more
fpath 0.7.3 File system paths for OCaml
menhir 20231231 An LR(1) parser generator
menhirCST 20231231 Runtime support library for parsers generated by Menhir
menhirLib 20231231 Runtime support library for parsers generated by Menhir
menhirSdk 20231231 Compile-time library for auxiliary tools related to Menhir
merlin-lib 5.0-502 Merlin's libraries
ocaml 5.2.0 The OCaml compiler (virtual package)
ocaml-config 3 OCaml Switch Configuration
ocaml-system 5.2.0 The OCaml compiler (system version, from outside of opam)
ocaml-version 3.6.7 Manipulate, parse and generate OCaml compiler version strings
ocaml_intrinsics_kernel v0.17.0 Intrinsics
ocamlbuild 0.14.3 OCamlbuild is a build system with builtin rules to easily build most OCaml projects
ocamlfind 1.9.6 A library manager for OCaml
ocamlformat-rpc-lib 0.26.2 Auto-formatter for OCaml code (RPC mode)
ocp-indent 1.8.1 A simple tool to indent OCaml programs
ordering 3.15.3 Element ordering
pp 1.2.0 Pretty-printing library
ppx_yojson_conv_lib v0.17.0 Runtime lib for ppx_yojson_conv
re 1.11.0 RE is a regular expression library for OCaml
result 1.5 Compatibility Result module
seq base Compatibility package for OCaml's standard iterator type starting from 4.07.
sexplib0 v0.17.0 Library containing the definition of S-expressions and some base converters
spawn v0.15.1 Spawning sub-processes
topkg 1.0.7 The transitory OCaml software packager
uucp 15.1.0 Unicode character properties for OCaml
uuseg 15.1.0 Unicode text segmentation for OCaml
uutf 1.0.3 Non-blocking streaming Unicode codec for OCaml
xdg 3.15.3 XDG Base Directory Specification
yojson 2.2.0 Yojson is an optimized parsing and printing library for the JSON format
The system packages from HACKING.md are all installed as far as I can tell.
I can install the deps and build the website on another opam switch just fine, the problem seems to come from the pinned repository https://github.com/ocaml/opam-repository#c45f5bab71d3589f41f9603daca5acad14df0ab0