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

opam deps are not precise enough #103

Open
zapashcanon opened this issue Oct 11, 2024 · 3 comments
Open

opam deps are not precise enough #103

zapashcanon opened this issue Oct 11, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@zapashcanon
Copy link

On my switch:

$ opam install opam install --deps-only ./wasm_of_ocaml-compiler.opam
$ dune build -p wasm_of_ocaml-compiler @install
[...]
File "compiler/lib/wasm/wa_source_map.ml", line 132, characters 41-65:
132 |   `Assoc ((m, v) :: List.remove_assoc m (Yojson.Raw.Util.to_assoc assoc))
                                               ^^^^^^^^^^^^^^^^^^^^^^^^
Error: Unbound module Yojson.Raw.Util

File "compiler/lib/wasm/wa_source_map.ml", line 132, characters 41-65:
132 |   `Assoc ((m, v) :: List.remove_assoc m (Yojson.Raw.Util.to_assoc assoc))
                                               ^^^^^^^^^^^^^^^^^^^^^^^^
Error: Unbound module Yojson.Raw.Util

107 |   let l = Structure.blocks_in_reverse_post_order g in
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error: Unbound value Structure.blocks_in_reverse_post_order

File "compiler/lib/wasm/wa_globalize.ml", line 107, characters 10-48:
107 |   let l = Structure.blocks_in_reverse_post_order g in
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error: Unbound value Structure.blocks_in_reverse_post_order
@zapashcanon zapashcanon added the bug Something isn't working label Oct 11, 2024
@vouillon
Copy link
Collaborator

Thanks for your report.

Indeed, I need to update the Yojson dependency.

The other error is because wasm_of_ocaml is not quite in sync with the latest release of Js_of_ocaml. So, you need to install a modified version of js_of_ocaml-compiler first. You can use the following commands to make sure that your get the right versions of the different packages:

opam pin add -n --with-version 5.8.2-wasm .
opam install wasm_of_ocaml-compiler

@zapashcanon
Copy link
Author

Does it mean that wsoo depends on jsoo ? (I did that pin command but got the error anyway, then it disappeared when I upgraded yojson)

@vouillon
Copy link
Collaborator

vouillon commented Oct 15, 2024

It is built using the js_of_ocaml-compiler library. This library is part of the opam package js_of_ocaml-compiler together with the js_of_ocaml binary.
There is a lot of code in common.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants