Closed fxfactorial closed 4 years ago
It looks like you didn't have the Graphics library installed during the compilation of your opam or your ocaml switch.
I guess, from your home path, that you're on a mac. I think you should install https://www.xquartz.org/ (and reinstall opam) if it is not already the case.
I'll modify the readme to note the Graphics dependencies
[ERROR] The compilation of graphics failed at "/Users/edgar/.opam/opam-init/hooks/sandbox.sh build ocamlc -custom graphics.cma -o test".
#=== ERROR while compiling graphics.1.0 =======================================#
# context 2.0.2 | macos/x86_64 | base-bigarray.base base-threads.base base-unix.base ocaml-base-compiler.4.06.1 | https://opam.ocaml.org#dc840fe4
# path ~/.opam/4.06.1/.opam-switch/build/graphics.1.0
# command ~/.opam/opam-init/hooks/sandbox.sh build ocamlc -custom graphics.cma -o test
# exit-code 2
# env-file ~/.opam/log/graphics-29574-dd682e.env
# output-file ~/.opam/log/graphics-29574-dd682e.out
### output ###
# File "_none_", line 1:
# Error: Cannot find file graphics.cma
<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><> π«
ββ The following actions failed
β Ξ» build graphics 1.0
ββ
βΆβ No changes have been performed
<><> graphics.1.0 troubleshooting <><><><><><><><><><><><><><><><><><><><><> π«
=> This package checks whether the Graphics library was compiled.
This is after removing and installing opam 2.0.2, after I had installed xquartz. Is there a reason for this dependency at all? Seems like just for simulator/tests?
I think it's just the simulator yes. I'm guessing commenting out lines 7 through 9 in the toplevel Makefile like so :
--- a/Makefile
+++ b/Makefile
@@ -4,9 +4,9 @@ all: config
$(call compile, lib/extra)
$(call compile, src/bc2c)
$(call compile, src/h15ppx)
- $(call compile, src/simulators/lcd)
- $(call compile, src/simulators/dip)
- $(call compile, src/simulators/circuit)
+# $(call compile, src/simulators/lcd)
+# $(call compile, src/simulators/dip)
+# $(call compile, src/simulators/circuit)
$(call compile, src/byterun)
$(call compile, src/omicrob)
$(call compile, src/stdlib)
Should do the trick (not having your problem, I haven't been able to test it though). That also mean you won't be able to simulate your programs, but you should be able to compile and flash them.
Great work, love this.
Got a build bug: