]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/software/components/library/librarian.ml
Use seed to avoid further name clashes.
[helm.git] / helm / software / components / library / librarian.ml
index aa6b2e81dd2e3997f96d41669e7ff245fc50e306..919edb36c4f9104eb88ec5be974016b12637533c 100644 (file)
@@ -153,7 +153,6 @@ module type Format =
     val mtime_of_source_object: source_object -> float option
     val mtime_of_target_object: target_object -> float option
     val is_readonly_buri_of: options -> source_object -> bool
-    val dotdothack: source_object -> source_object 
   end
 
 module Make = functor (F:Format) -> struct
@@ -357,7 +356,7 @@ module Make = functor (F:Format) -> struct
         make_aux root opts [] [] deps
       else
         make_aux root opts [] [] 
-          (purge_unwanted_roots (List.map F.dotdothack targets) deps)
+          (purge_unwanted_roots targets deps)
     in
     HLog.debug ("Leaving directory '"^root^"'");
     Sys.chdir old_root;
@@ -366,15 +365,15 @@ module Make = functor (F:Format) -> struct
 
 end
   
-let write_deps_file root deps =
-  let oc = open_out (root ^ "/depends") in
-  List.iter 
-    (fun (t,d) -> output_string oc (t^" "^String.concat " " d^"\n")) 
-    deps;
-  close_out oc;
-  HLog.message ("Generated: " ^ root ^ "/depends")
-;;
-
+let write_deps_file where deps = match where with 
+   | Some root ->
+      let oc = open_out (root ^ "/depends") in
+      let map (t, d) = output_string oc (t^" "^String.concat " " d^"\n") in
+      List.iter map deps; close_out oc;
+      HLog.message ("Generated: " ^ root ^ "/depends")
+   | None -> 
+      print_endline (String.concat " " (List.flatten (List.map snd deps)))
+      
 (* FG ***********************************************************************)
 
 (* scheme uri part as defined in URI Generic Syntax (RFC 3986) *)