[solved] JBuilder doesn't work for macOS 10.11 anymore?

I just post an issue in , but github there’s still not solution.

Then I tried the basic example of JBuilder as

(jbuild_version 1)

(executables
  ((names (hello_world))))

The hello_world.ml as:

print_endline "Hi"

Error message as:

$ jbuilder build hello_world.exe
    ocamldep hello_world.depends.ocamldep-output
      ocamlc hello_world.{cmi,cmo,cmt}
    ocamlopt hello_world.{cmx,o}
    ocamlopt hello_world.exe
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/std_exit.o) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/stdlib.a(camlinternalFormatBasics.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/stdlib.a(pervasives.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(amd64.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(roots.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(minor_gc.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(main.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(major_gc.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(memory.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(misc.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(fail.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(backtrace.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(str.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(floats.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(compact.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(weak.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(finalise.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(freelist.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(ints.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(obj.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(signals_asm.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(compare.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(intern.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(startup.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(io.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(extern.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(callback.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(signals.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(globroots.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(backtrace_prim.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(gc_ctrl.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(sys.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(alloc.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(custom.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(debugger.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(unix.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(printexc.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(startup_aux.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(md5.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/libasmrun.a(parsing.o)) was built for newer OSX version (10.12) than being linked (10.11)

Doesn’t seem like a jbuider issue. Do you get the same warning when you try building with ocamlbuild?

For example $ ocamlbuild hello_world.native

1 Like

Yeah, you are right!

 $ ocamlbuild hello_world.native
+ /Users/liweijian/.opam/4.04.1/bin/ocamlopt.opt hello_world.cmx -o hello_world.native
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/std_exit.o) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/stdlib.a(camlinternalFormatBasics.o)) was built for newer OSX version (10.12) than being linked (10.11)
ld: warning: object file (/Users/liweijian/.opam/4.04.1/lib/ocaml/stdlib.a(pervasives.o)) was built for newer OSX version (10.12) than being linked (10.11)