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

build / install fails on FreeBSD #68

Open
tpltnt opened this issue Aug 28, 2017 · 3 comments
Open

build / install fails on FreeBSD #68

tpltnt opened this issue Aug 28, 2017 · 3 comments

Comments

@tpltnt
Copy link

tpltnt commented Aug 28, 2017

Hi there,

I tried installing iocaml via opam (i.e. opam install iocaml), but it failed

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[iocaml] Archive in cache
[iocaml-kernel] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of iocaml-kernel failed at "gmake all".
Processing  1/2: [iocaml-kernel: gmake uninstall]
#=== ERROR while installing iocaml-kernel.0.4.8 ===============================#
# opam-version 1.2.2
# os           freebsd
# command      gmake all
# path         /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8
# compiler     system (4.02.3)
# exit-code    2
# env-file     /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-54283-e7966f.env
# stdout-file  /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-54283-e7966f.out
# stderr-file  /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-54283-e7966f.err
### stdout ###
# atdgen -t Ipython_json.atd
# atdgen -j Ipython_json.atd
# ocamlfind c iocaml_zmq_stubs.c
### stderr ###
# iocaml_zmq_stubs.c:1:10: fatal error: 'zmq.h' file not found
# #include <zmq.h>
#          ^
# 1 error generated.
# gmake: *** [Makefile:10: stub] Fehler 2

Libzmq is installed and zmq.h can be found in the directory /usr/local/include/. This directory does not seem to get searched when running ocamlfind c iocaml_zmq_stubs.c. I haven't found any (quick) fix, otherwise I would have provided a patch/pull request. Thank you for providing an OCaml kernel for Jupyter and I hope this issues gets fixed.

Cheers,
tpltnt

@dbuenzli
Copy link

Can you maybe try with the environment variables mentioned there. Something like:

C_INCLUDE_PATH="/usr/local/include:$C_INCLUDE_PATH" opam install iocaml

@tpltnt
Copy link
Author

tpltnt commented Sep 26, 2017

I tried it and it did not work. See below

foo@testbox ~]% C_INCLUDE_PATH="/usr/local/include:$C_INCLUDE_PATH" opam install iocaml
The following actions will be performed:
  ∗  install iocaml-kernel 0.4.8              [required by iocaml]
  ∗  install iocaml        0.4.9
===== ∗  2 =====
Do you want to continue ? [Y/n] y

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[iocaml] Archive in cache
[iocaml-kernel] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of iocaml-kernel failed at "gmake all".
Processing  1/2: [iocaml-kernel: gmake uninstall]
#=== ERROR while installing iocaml-kernel.0.4.8 ===============================#
# opam-version 1.2.2
# os           freebsd
# command      gmake all
# path         /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8
# compiler     system (4.02.3)
# exit-code    2
# env-file     /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-2445-e7966f.env
# stdout-file  /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-2445-e7966f.out
# stderr-file  /usr/home/foo/.opam/system/build/iocaml-kernel.0.4.8/iocaml-kernel-2445-e7966f.err
### stdout ###
# [...]
# # rest of the library
# ocamlfind c -c -g \
#     -package yojson,atdgen,compiler-libs \
#     Ipython_json_t.mli Ipython_json_j.mli base64.mli \
#     Ipython_json_t.ml  Ipython_json_j.ml  base64.ml  
# ocamlfind ocamlmklib -o iocaml_lib \
#     -l zmq \
#     -package ctypes.foreign,lwt.unix,yojson \
#     iocaml_zmq_stubs.o \
#     log.cmo Ipython_json_t.cmo Ipython_json_j.cmo iocaml_zmq.cmo base64.cmo 
### stderr ###
# [...]
# Use Bytes.set instead.
# File "base64.ml", line 69, characters 4-35:
# Warning 3: deprecated: String.set
# Use Bytes.set instead.
# File "base64.ml", line 72, characters 4-44:
# Warning 3: deprecated: String.set
# Use Bytes.set instead.
# /usr/bin/ld: cannot find -lzmq
# cc: error: linker command failed with exit code 1 (use -v to see invocation)
# gmake: *** [Makefile:19: lib] Fehler 2



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions were aborted
  ∗  install iocaml 0.4.9
The following actions failed
  ∗  install iocaml-kernel 0.4.8
No changes have been performed

@andrewray
Copy link
Owner

andrewray commented Sep 26, 2017 via email

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

3 participants