Hello,
I’m facing a strange error when using opam pin. opam install-ing a package works fine, but opam pin add-ing an archive results in (here with package vlt but the error is the same with any package):
opam pin add https://github.com/codinuum/vlt/archive/v0.2.5.tar.gz
...
#=== ERROR while compiling vlt.0.2.5 ==========================================#
# context 2.5.1 | linux/x86_64 | ocaml-base-compiler.5.4.0 | pinned(https://github.com/codinuum/vlt/archive/v0.2.5.tar.gz)
# path /personal/guesdon/.opam/5.4.0/.opam-switch/build/vlt.0.2.5
# command /personal/guesdon/.opam/opam-init/hooks/sandbox.sh build dune build -p vlt -j 15 @install
# exit-code 1
# env-file /personal/guesdon/.opam/log/vlt-139671-ec5925.env
# output-file /personal/guesdon/.opam/log/vlt-139671-ec5925.out
### output ###
# Error: I don't know about package vlt (passed through --only-packages)
And indeed, the directory /personal/guesdon/.opam/5.4.0/.opam-switch/build/vlt.0.2.5 only contains the dune _build directory, not any file from the archive. In a verbose log, it appears that opam runs rsync:
+ /usr/bin/rsync "-rLptgoDvc" "--exclude" ".git" "--exclude" "_darcs" "--exclude" ".hg" "--exclude" ".#*" "--exclude" "_opam*" "--exclude" "_build" "--delete" "--delete-excluded" "/tmp/opam-pin-cache-139671-415d73/a0a557e2dadf49e6/" "/tmp/opam-139671-7398b7"
Could the problem be that the destination directory of the rsync command is /tmp/opam-139671-7398b7 instead of /personal/guesdon/.opam/5.4.0/.opam-switch/build/vlt.0.2.5 ? And if so, do you have any idea why ?
I can provide a full log if needed.