ygrek / ocurl

OCaml bindings to libcurl
https://ygrek.org/p/ocurl
MIT License
59 stars 32 forks source link

ocurl fails to install on ubuntu 12.04 LTS #9

Closed ivg closed 7 years ago

ivg commented 9 years ago

Actually on Travis, it started to fail out with the following:

### stderr ###
# [...]
# curl-helper.c: In function ‘duplicateConnection’:
# curl-helper.c:2885:9: warning: implicit declaration of function ‘handle_DNS_SERVERS’ [-Wimplicit-function-declaration]
# ../libcurl-helper.a(curl-helper.o): In function `duplicateConnection':
# /home/travis/.opam/system/build/ocurl.0.7.4/curl-helper.c:2885: undefined reference to `handle_DNS_SERVERS'
# collect2: ld returned 1 exit status

More examples. Do have any ideas, whats going on? libcurl4-gnutls-dev is installed, maybe some other dependency?

ygrek commented 9 years ago

It is a bug, support for old libcurl is broken. Temporary workaround - upgrade libcurl or downgrade ocurl. Thanks for the report.

ivg commented 9 years ago

do you have an initial approximation to which version I should downgrade? 0.7.1 is fine?

ygrek commented 9 years ago

0.7.2 should be fine

ygrek commented 9 years ago

@ivg can you please check that git trunk fixes build with old libcurl?

ivg commented 9 years ago

It would be hard, since I have access to Precise only via Travis. But I will try

hcarty commented 7 years ago

It looks like this has come up again with 0.7.8 (see https://github.com/BinaryAnalysisPlatform/bap/pull/556)

ygrek commented 7 years ago

Sorry about that. Build log and libcurl version would be helpful.

ivg commented 7 years ago

Sure, here is the build log from Travis, and here is the relevant excerpt:

#=== ERROR while installing ocurl.0.7.8 =======================================#
# opam-version 1.2.2
# os           linux
# command      make
# path         /home/travis/.opam/system/build/ocurl.0.7.8
# compiler     system (4.02.3)
# exit-code    2
# env-file     /home/travis/.opam/system/build/ocurl.0.7.8/ocurl-11620-55d991.env
# stdout-file  /home/travis/.opam/system/build/ocurl.0.7.8/ocurl-11620-55d991.out
# stderr-file  /home/travis/.opam/system/build/ocurl.0.7.8/ocurl-11620-55d991.err
### stdout ###
# make[1]: Entering directory `/home/travis/.opam/system/build/ocurl.0.7.8'
# make[1]: Leaving directory `/home/travis/.opam/system/build/ocurl.0.7.8'
# make[1]: Entering directory `/home/travis/.opam/system/build/ocurl.0.7.8'
# ocamlc.opt -c -g -bin-annot curl.mli -o curl.cmi
# ocamlc.opt -c -g -bin-annot curl.ml -o curl.cmo
# ocamlc.opt -c -ccopt "-g -O2   -DHAVE_CONFIG_H -Wall" curl-helper.c
# make[1]: Leaving directory `/home/travis/.opam/system/build/ocurl.0.7.8'
### stderr ###
# curl-helper.c: In function ‘handle_SSLVERSION’:
# curl-helper.c:1855:17: error: ‘CURL_SSLVERSION_TLSv1_0’ undeclared (first use in this function)
# curl-helper.c:1855:17: note: each undeclared identifier is reported only once for each function it appears in
# curl-helper.c:1856:17: error: ‘CURL_SSLVERSION_TLSv1_1’ undeclared (first use in this function)
# curl-helper.c:1857:17: error: ‘CURL_SSLVERSION_TLSv1_2’ undeclared (first use in this function)
# make[1]: *** [curl-helper.o] Error 2
# make: *** [all] Error 2
ygrek commented 7 years ago

Please try 0.7.9 - https://github.com/ocaml/opam-repository/pull/7555 Thanks again for reporting. Also, ocurl now has CI scripts (thanks @talex5 !) which should help to catch such problems in the future

ivg commented 7 years ago

Checked, 0.7.9 works fine on 12.02.

Thanks, guys!