polars-ocaml
polars-ocaml copied to clipboard
Odd issue with MDX when running in Docker
When trying to build the project in a dev container, we seem to get the following linking-related error:
# dune build @fmt @runtest @doc
File "lib/dune", line 41, characters 0-123:
41 | (mdx
42 | (files :standard - *.mli)
43 | (libraries core core_kernel.nonempty_list polars)
44 | (preludes mdx_prelude/mdx_prelude.txt))
Fatal error: cannot load shared library dllpolars_ocaml
Reason: dllpolars_ocaml.so: cannot open shared object file: No such file or directory
This happens on both Docker for mac and on GitHub codespaces. I suspect we're hitting some issue related to how OCaml links things into bytecode binaries, but I'm not entirely sure. Commenting out the mdx stanza fixes the issue.
Passing some options, we get:
# dune runtest --verbose -j1
Running[19]: (cd _build/default/lib && ./mdx_gen.bc utils.mli) > _build/default/lib/.mdx/utils.mli.corrected
File "lib/dune", line 41, characters 0-123:
41 | (mdx
42 | (files :standard - *.mli)
43 | (libraries core core_kernel.nonempty_list polars)
44 | (preludes mdx_prelude/mdx_prelude.txt))
Command [19] got signal ABRT:
$ (cd _build/default/lib && ./mdx_gen.bc utils.mli) > _build/default/lib/.mdx/utils.mli.corrected
Fatal error: cannot load shared library dllpolars_ocaml
Reason: dllpolars_ocaml.so: cannot open shared object file: No such file or directory
Running mdx_gen.bc
on its own also seems to exhibit the issue:
_build/default/lib/mdx_gen.bc
Fatal error: cannot load shared library dllpolars_ocaml
Reason: dllpolars_ocaml.so: cannot open shared object file: No such file or directory
Aborted (core dumped)