ocsigen / eliom

Multi-tier framework for programming web and mobile applications in OCaml.
http://eliom.org
Other
306 stars 54 forks source link

`make byte` fails #241

Open vasilisp opened 8 years ago

vasilisp commented 8 years ago

make byte eventually fails with:

+ ocamlfind ocamlc -c -g -keep-locs -thread -syntax camlp4o -I src/lib/server -package lwt,ocsigenserver,ocsigenserver.ext,tyxml,calendar -package lwt.syntax -w +A-4-6-7-9-27-32-33-34-37-40-42-44-48 -I src/lib/server/monitor -o src/lib/server/monitor/eliom_monitor.cmo src/lib/server/monitor/eliom_monitor.ml
File "src/lib/server/monitor/eliom_monitor.ml", line 132, characters 29-69:
Error: Unbound module Eliommod_sessiongroups
Command exited with code 2.
Compilation unsuccessful after building 313 targets (3 cached) in 00:01:36.
Makefile:15: recipe for target 'byte' failed
make: *** [byte] Error 10

I haven't investigated this yet.

@glondu brought this up in the mailing list for 4.2, but unfortunately it affects master as well.

hhugo commented 8 years ago

Here is an inelegant quickfix.

diff --git a/build/build.ml b/build/build.ml
index 84f5c5d..55be730 100644
--- a/build/build.ml
+++ b/build/build.ml
@@ -70,6 +70,9 @@ let _ = dispatch (fun x ->
     add_syntax ~needs "pa_eliom_client_server" "src/syntax/";
     add_syntax ~needs "pa_eliom_type_filter" "src/syntax/";

+    pflag ["ocaml";"compile"] "depends_on" (fun name -> S [A "-I";P (Filename.dirname name) ]);
+    pdep  ["ocaml";"compile"] "depends_on" (fun name -> [name]);
+
     (* link executable aliases *)
     let link_exec f t =
       link (Printf.sprintf "src/tools/%s.byte" f)   (Printf.sprintf "src/tools/%s.byte" t);
diff --git a/src/_tags b/src/_tags
index e63ac2c..5dbb383 100644
--- a/src/_tags
+++ b/src/_tags
@@ -32,12 +32,12 @@ true:keep_locs
 <lib/server/extensions/*.ml{,i}>:thread
 <lib/server/extensions/*.ml{,i}>:package(lwt,ocsigenserver,ocsigenserver.ext,tyxml,calendar)
 <lib/server/extensions/*.ml{,i}>:syntax(camlp4o),package(deriving.syntax.std, js_of_ocaml.deriving.syntax),pkg_pa_include,sig_inc(../src/lib)
-<lib/server/extensions/*.ml{,i}>:I(src/lib/server)
+<lib/server/extensions/*.ml{,i}>:depends_on(src/lib/server/server.cma)

 <lib/server/monitor/*.ml>:syntax(camlp4o), package(lwt.syntax)
 <lib/server/monitor/*.ml{,i}>:thread
 <lib/server/monitor/*.ml{,i}>:package(lwt,ocsigenserver,ocsigenserver.ext,tyxml,calendar)
-<lib/server/monitor/*.ml{,i}>:I(src/lib/server)
+<lib/server/monitor/*.ml{,i}>:depends_on(src/lib/server/server.cma)

 <syntax/pa_*.*>: syntax(camlp4o),package(camlp4.quotations.o,camlp4.extend,bytes)
 <syntax/pa_*.ml{,i}>: I(+camlp4/Camlp4Parsers)