[Pkg-ocaml-maint-commits] r6117 - in /trunk/packages/edos-debcheck/trunk/debian/edos-future: Makefile upclose.ml
treinen at users.alioth.debian.org
treinen at users.alioth.debian.org
Mon Jan 26 12:28:34 UTC 2009
Author: treinen
Date: Mon Jan 26 12:28:34 2009
New Revision: 6117
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/?sc=1&rev=6117
Log:
make it again compile with latest napkin
Modified:
trunk/packages/edos-debcheck/trunk/debian/edos-future/Makefile
trunk/packages/edos-debcheck/trunk/debian/edos-future/upclose.ml
Modified: trunk/packages/edos-debcheck/trunk/debian/edos-future/Makefile
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/edos-debcheck/trunk/debian/edos-future/Makefile?rev=6117&op=diff
==============================================================================
--- trunk/packages/edos-debcheck/trunk/debian/edos-future/Makefile (original)
+++ trunk/packages/edos-debcheck/trunk/debian/edos-future/Makefile Mon Jan 26 12:28:34 2009
@@ -1,16 +1,16 @@
OCAMLC=ocamlc
OCAMLOPT=ocamlopt
-FLAVOUR=native
+FLAVOUR=byte
MAIN=upclose
$(MAIN): $(MAIN).$(FLAVOUR)
ln -sf $(MAIN).$(FLAVOUR) $(MAIN)
$(MAIN).byte: $(MAIN).ml
- $(OCAMLC) -I +dose2 -o $(MAIN).byte nums.cma unix.cma zip/zip.cma str.cma dose2/util.cma ocamldeb.cma dose2/io.cma napkin.cma upclose.ml
+ $(OCAMLC) -I /usr/local/lib/ocaml/3.10.2/dose2 -o $(MAIN).byte nums.cma unix.cma zip/zip.cma str.cma util.cma pcre/pcre.cma ocamldeb.cma io.cma progress.cma napkin.cma upclose.ml
$(MAIN).native: $(MAIN).ml
- $(OCAMLOPT) -I +dose2 -I +zip -o $(MAIN).native nums.cmxa unix.cmxa zip/zip.cmxa str.cmxa dose2/util.cmxa ocamldeb.cmxa dose2/io.cmxa napkin.cmxa upclose.ml
+ $(OCAMLOPT) -I /usr/local/lib/ocaml/3.10.2/dose2 -I +zip -o $(MAIN).native nums.cmxa unix.cmxa zip/zip.cmxa str.cmxa dose2/util.cmxa ocamldeb.cmxa io.cmxa napkin.cmxa upclose.ml
clean:
-rm -f *.{cmo,cmi,cmx,o} $(MAIN).{byte,native} $(MAIN)
Modified: trunk/packages/edos-debcheck/trunk/debian/edos-future/upclose.ml
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/edos-debcheck/trunk/debian/edos-future/upclose.ml?rev=6117&op=diff
==============================================================================
--- trunk/packages/edos-debcheck/trunk/debian/edos-future/upclose.ml (original)
+++ trunk/packages/edos-debcheck/trunk/debian/edos-future/upclose.ml Mon Jan 26 12:28:34 2009
@@ -20,43 +20,34 @@
raise (Bad "Missing input file");;
(* the data from the Packages file *)
-let packages = read_pool_file !inputfile;;
+let packages = read_pool_file !inputfile Progress.dummy;;
(* associates to package names the list of versions with which the package is *)
(* mentioned in conflicts and depends relations. *)
let versions = Hashtbl.create 10000;;
-(* extract a pure version number from a napkin versioned *)
-let number_of_versionend (pn,vs) =
- match vs with
- | Sel_ANY -> ""
- | Sel_LEQ v -> v
- | Sel_LT v -> v
- | Sel_GEQ v -> v
- | Sel_GT v -> v
- | Sel_EQ v -> v
-;;
-
-(* c is a pair (packagename,version). Add it to the hashtable versions *)
-(* if it isn't already there. *)
-let process_relation c =
- let package = fst c
- and version = number_of_versionend c
- in
- try
- let oldversions = Hashtbl.find versions package
- in
- if not (List.mem version oldversions)
- then Hashtbl.replace versions package (version::oldversions)
- with
- Not_found -> Hashtbl.add versions package [version]
+(* c is a Napkin.versionend. Add it to the hashtable versions *)
+(* if it isn't already there. *)
+let store_versionend = function
+ | Glob_pattern _glob -> failwith "this cannot happen"
+ | Unit_version(package,versionend) -> match versionend with
+ Sel_ANY -> ()
+ | Sel_LEQ version | Sel_GEQ version | Sel_EQ version | Sel_LT version
+ | Sel_GT version ->
+ try
+ let oldversions = Hashtbl.find versions package
+ in
+ if not (List.mem version oldversions)
+ then Hashtbl.replace versions package (version::oldversions)
+ with
+ Not_found -> Hashtbl.add versions package [version]
;;
List.iter
(function p ->
- List.iter process_relation p.pk_conflicts;
- List.iter (List.iter process_relation) p.pk_depends)
- packages
+ List.iter store_versionend p.pk_conflicts;
+ List.iter (List.iter store_versionend) p.pk_depends)
+packages
;;
Hashtbl.iter
More information about the Pkg-ocaml-maint-commits
mailing list