bsansouci / bsb-native

Build system for OCaml/Reason
Other
245 stars 10 forks source link

ocamlfind-dependencies appears to be broken #48

Open cem2ran opened 6 years ago

cem2ran commented 6 years ago

Can be reproduced by cloning the following example and using bsb-native master: https://github.com/bsansouci/bsb-native-example/tree/opam-example

Build output:

$ bsb -backend native
ninja: Entering directory `/Users/cem2ran/git/bsb-native-alcotest/lib/bs/native'
[1/3] Building src/index.cmx
FAILED: src/index.cmx src/index.cmi
ocamlfind ocamlopt   -I /Users/cem2ran/git/bsb-native-alcotest/node_modules/bs-platform/lib/ocaml/native  -I src -I web -I test  -package alcotest -thread -passopt -no-alias-deps -passopt -color -passopt always -o src/index.cmx -w -30-40+6+7+27+32..39+44+45+101-31 -g -c -intf-suffix .mliast_simple -impl src/index.mlast_simple
ocamlfind: Package `alcotest' not found
ninja: build stopped: subcommand failed.
error Command failed with exit code 2.
bsansouci commented 6 years ago

I think this means you need to install alcotest with opam, by doing opam install alcotest. Make sure you have the correct switch:

opam switch 4.02.3+buckle-master && eval `opam config env`
cem2ran commented 6 years ago

I did all that. Is it working at your end? If so I might have messed something up in my environment.

bsansouci commented 6 years ago

https://github.com/reasonml/reason-cli/issues/44#issuecomment-397063662