vbmithr / ocaml-websocket

Websocket library for OCaml
ISC License
163 stars 44 forks source link

Compilation error #1

Closed olleharstedt closed 10 years ago

olleharstedt commented 11 years ago

olle@olle-ThinkPad-X220:~/ocaml/ocaml-websocket-master$ sudo ocaml setup.ml -build Finished, 0 targets (0 cached) in 00:00:00.

File "lib/websocket.mli", line 52, characters 22-27: Error: Unbound module Uri

Command exited with code 2. Compilation unsuccessful after building 2 targets (1 cached) in 00:00:00. E: Failure("Command ''/usr/bin/ocamlbuild' lib/websocket.cma lib/websocket.cmxa lib/websocket.a lib/websocket.cmxs tests/wscat.native -tag debug' terminated with error code 10")

How to include uri package? I've got it installed in ocamlfind and all.

Regards Olle

vbmithr commented 11 years ago

Hello. I’m going to check that asap and I’ll answer here. Sorry I miss this comment!

vbmithr commented 11 years ago

Cannot reproduce. Are you sure you did install Uri correctly ? It works for me…

olleharstedt commented 11 years ago

50% sure ;) build gives this:

Configuration: ocamlfind: ........................................... /usr/bin/ocamlfind ocamlc: .............................................. /usr/bin/ocamlc ocamlopt: ............................................ /usr/bin/ocamlopt ocamlbuild: .......................................... /usr/bin/ocamlbuild Package name: ........................................ websocket Package version: ..................................... 0.1 os_type: ............................................. Unix system: .............................................. linux_elf architecture: ........................................ i386 ccomp_type: .......................................... cc ocaml_version: ....................................... 3.12.1 standard_library_default: ............................ /usr/lib/ocaml standard_library: .................................... /usr/lib/ocaml standard_runtime: .................................... /usr/bin/ocamlrun bytecomp_c_compiler: ................................. gcc -D_FILE_OFFSET_BITS=64 -D_REENTRANT -fPIC native_c_compiler: ................................... gcc -D_FILE_OFFSET_BITS=64 -D_REENTRANT model: ............................................... default ext_obj: ............................................. .o ext_asm: ............................................. .s ext_lib: ............................................. .a ext_dll: ............................................. .so default_executable_name: ............................. a.out systhread_supported: ................................. true Install architecture-independent files dir: .......... /usr/local Install architecture-dependent files in dir: ......... $prefix User executables: .................................... $exec_prefix/bin System admin executables: ............................ $exec_prefix/sbin Program executables: ................................. $exec_prefix/libexec Read-only single-machine data: ....................... $prefix/etc Modifiable architecture-independent data: ............ $prefix/com Modifiable single-machine data: ...................... $prefix/var Object code libraries: ............................... $exec_prefix/lib Read-only arch-independent data root: ................ $prefix/share Read-only architecture-independent data: ............. $datarootdir Info documentation: .................................. $datarootdir/info Locale-dependent data: ............................... $datarootdir/locale Man documentation: ................................... $datarootdir/man Documentation root: .................................. $datarootdir/doc/$pkg_name HTML documentation: .................................. $docdir DVI documentation: ................................... $docdir PDF documentation: ................................... $docdir PS documentation: .................................... $docdir findlib_version: ..................................... 1.3.3 is_native: ........................................... true suffix_program: ...................................... Remove a file.: ...................................... rm -f Remove a directory.: ................................. rm -rf Turn ocaml debug flag on: ............................ true Turn ocaml profile flag on: .......................... false Compiler support generation of .cmxs.: ............... true OCamlbuild additional flags: ......................... Create documentations: ............................... true Compile tests executable and library and run them: ... false pkg_lwt: ............................................. /usr/lib/ocaml/site-lib/lwt pkg_lwt_syntax: ...................................... /usr/lib/ocaml/site-lib/lwt pkg_bitstring: ....................................... /usr/lib/ocaml/site-lib/bitstring pkg_bitstring_syntax: ................................ /usr/lib/ocaml/site-lib/bitstring pkg_cryptokit: ....................................... /usr/lib/ocaml/site-lib/cryptokit pkg_uri: ............................................. /usr/lib/ocaml/site-lib/uri pkg_cohttp: .......................................... /usr/lib/ocaml/site-lib/cohttp

olle@olle-ThinkPad-X220:~/ocaml/ocaml-websocket-master$ sudo ocaml setup.ml -build Finished, 0 targets (0 cached) in 00:00:00.

As you can see, packages Uri is not included by ocamlfind ocamlc ...

vbmithr commented 11 years ago

I changed the build system to obuild instead of oasis today. Could you please pull last trunk and retest ? uri is a dependency of cohttp, it should be handled correctly…

Cheers.

rgrinberg commented 11 years ago

Small note, obuild in opam does not support obuild install as of yet. Perhaps obuild from github does. But it means you have to install ocaml-websockets with ocamlfind yourself.