Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make test is broken on OSX #1

Open
samoht opened this issue Mar 24, 2014 · 3 comments
Open

make test is broken on OSX #1

samoht opened this issue Mar 24, 2014 · 3 comments

Comments

@samoht
Copy link
Contributor

samoht commented Mar 24, 2014

$ make test
ocaml setup.ml -build
/Users/thomas/.opam/system/bin/ocamlfind ocamlopt -shared -linkall lib/profuse.cmxa -o lib/profuse.cmxs
/Users/thomas/.opam/system/bin/ocamlfind ocamlopt -shared -linkall linux/linux.cmxa -o linux/linux.cmxs
ocaml setup.ml -test
ocamlfind ocamlopt -o run_test -package oUnit -package alcotest -package ctypes -package fd-send-recv -package unix-unistd -package unix-errno -package unix-dirent -package unix-sys-stat -package unix-fcntl -package lwt.unix -package lwt.preemptive -g -thread \
        -I ../_build/lib -I ../_build/linux \
        ../_build/lib/opcode.cmx \
        ../_build/lib/fuse.cmx \
        ../_build/lib/view.cmx \
        ../_build/lib/struct_common.cmx \
        ../_build/lib/struct_linux_7_8.cmx \
        ../_build/lib/struct_osx_7_8.cmx \
        ../_build/lib/struct.cmx \
        ../_build/lib/in_common.cmx \
        ../_build/lib/in_linux_7_8.cmx \
        ../_build/lib/in_osx_7_8.cmx \
        ../_build/lib/in.cmx \
        ../_build/lib/out_common.cmx \
        ../_build/lib/out_linux_7_8.cmx \
        ../_build/lib/out_osx_7_8.cmx \
        ../_build/lib/out.cmx \
        ../_build/linux/profuse.cmx \
        ../_build/linux/lofs.cmx \
        -linkpkg test.ml
Undefined symbols for architecture x86_64:
  "_ffi_closure_alloc", referenced from:
      _ctypes_make_function_pointer in libctypes-foreign-base_stubs.a(ffi_call_stubs.o)
  "_ffi_prep_closure_loc", referenced from:
      _ctypes_make_function_pointer in libctypes-foreign-base_stubs.a(ffi_call_stubs.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
File "caml_startup", line 1:
Error: Error during linking

I suspect this is expected because this isrunning linux tests on OSX, but that would be good to fail more graciously.

@samoht
Copy link
Contributor Author

samoht commented Mar 24, 2014

Seems to be related to yallop/ocaml-ctypes#74

@dsheets
Copy link
Member

dsheets commented Mar 24, 2014

I believe this issue is a general ctypes problem as you indicate. Once you clear it, you will surely find further issues with ctypes-on-osx. In particular, I believe a new mounting procedure will need to be defined. Probably linux/profuse.ml should be functorized and placed into lib/.

@yallop will eventually bring back the Mac Mini (:-P) and we can rack it for remote test builds. Alternately, I will probably hook up my MacBook Air with 10.6 and broken screen in the next few days for testing if I can work around the display damage.

@dsheets
Copy link
Member

dsheets commented Mar 29, 2014

While the tests still fail on OS X, the ctypes problem has been temporarily addressed in HEAD using the pkg-config solution described in yallop/ocaml-ctypes#74.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants