This is an automated email from the git hooks/post-receive script.

andyli-guest pushed a commit to branch master
in repository xml-light.

commit 9685a45f45b8fb4f29419ee93959ce501ceeb9a2
Author: Andy Li <a...@onthewings.net>
Date:   Thu Jul 6 11:49:16 2017 +0800

      * New upstream version.
        - Removed 01_installopt.diff, 02_cmi_depends.diff, 04_dtd_trace.diff,
          05_cmxs_plugin.diff, and 06_CVE-2012-3514, which are all applied in
          upstream.
        - Updated 03_cflags.diff.
        - Updated rules to work with upstream Makefile changes.
      * Update to reference new upstream repository.
        - update d/watch, d/control
      * Use secure uri for d/control Vcs-* fields.
      * Bump Standards-Version to 4.0.0 (no changes).
      * Bump d/compat to 9 (no changes).
---
 debian/META.xml-light.in             |   4 -
 debian/changelog                     |  17 ++++
 debian/compat                        |   2 +-
 debian/control                       |  16 ++--
 debian/libxml-light-ocaml.install.in |   1 -
 debian/patches/01_installopt.diff    |  17 ----
 debian/patches/02_cmi_depends.diff   |  11 ---
 debian/patches/03_cflags.diff        |  44 ----------
 debian/patches/04_dtd_trace.diff     |  19 -----
 debian/patches/05_cmxs_plugin.diff   |  28 -------
 debian/patches/06_CVE-2012-3514.diff | 153 -----------------------------------
 debian/patches/cflags.diff           |  48 +++++++++++
 debian/patches/series                |   7 +-
 debian/rules                         |   5 +-
 14 files changed, 75 insertions(+), 297 deletions(-)

diff --git a/debian/META.xml-light.in b/debian/META.xml-light.in
deleted file mode 100644
index bbfb3d9..0000000
--- a/debian/META.xml-light.in
+++ /dev/null
@@ -1,4 +0,0 @@
-version="@VERSION@"
-directory="+xml-light"
-archive(byte)="xml-light.cma"
-archive(native)="xml-light.cmxa"
diff --git a/debian/changelog b/debian/changelog
index a8ceb3a..f676712 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,20 @@
+xml-light (2.4-1) unstable; urgency=low
+
+  * Team upload
+  * New upstream version.
+    - Removed 01_installopt.diff, 02_cmi_depends.diff, 04_dtd_trace.diff,
+      05_cmxs_plugin.diff, and 06_CVE-2012-3514, which are all applied in
+      upstream.
+    - Updated 03_cflags.diff.
+    - Updated rules to work with upstream Makefile changes.
+  * Reference new upstream repository.
+    - update d/watch, d/control
+  * Use secure uri for d/control Vcs-* fields.
+  * Bump Standards-Version to 4.0.0 (no changes).
+  * Bump d/compat to 9 (no changes).
+
+ -- Andy Li <a...@onthewings.net>  Thu, 06 Jul 2017 10:01:34 +0800
+
 xml-light (2.2-17) unstable; urgency=low
 
   * Team upload
diff --git a/debian/compat b/debian/compat
index 7f8f011..ec63514 100644
--- a/debian/compat
+++ b/debian/compat
@@ -1 +1 @@
-7
+9
diff --git a/debian/control b/debian/control
index 9cb78fb..377d3ce 100644
--- a/debian/control
+++ b/debian/control
@@ -7,12 +7,12 @@ Uploaders:
 Build-Depends:
  cdbs (>= 0.4.23-1.1),
  ocaml-nox (>= 4),
- debhelper (>= 7.0.50~),
+ debhelper (>= 9),
  dh-ocaml (>= 0.9)
-Standards-Version: 3.9.2
-Vcs-Git: git://anonscm.debian.org/pkg-ocaml-maint/packages/xml-light.git
-Vcs-Browser: 
http://anonscm.debian.org/gitweb/?p=pkg-ocaml-maint/packages/xml-light.git
-Homepage: http://tech.motion-twin.com/xmllight.html
+Standards-Version: 4.0.0
+Vcs-Git: https://anonscm.debian.org/git/pkg-ocaml-maint/packages/xml-light.git
+Vcs-Browser: 
https://anonscm.debian.org/cgit/pkg-ocaml-maint/packages/xml-light.git
+Homepage: https://github.com/ncannasse/xml-light
 
 Package: libxml-light-ocaml-dev
 Architecture: any
@@ -27,9 +27,6 @@ Description: mininal XML parser and printer for OCaml 
(development package)
  into OCaml data structures and printing it back to a XML document.
  .
  It also supports DTD.
- .
- You can find more information about xml-light at
- http://tech.motion-twin.com/xmllight.html
 
 Package: libxml-light-ocaml
 Architecture: any
@@ -48,6 +45,3 @@ Description: mininal XML parser and printer for OCaml 
(runtime package)
  into OCaml data structures and printing it back to a XML document.
  .
  It also supports DTD.
- .
- You can find more information about xml-light at
- http://tech.motion-twin.com/xmllight.html
diff --git a/debian/libxml-light-ocaml.install.in 
b/debian/libxml-light-ocaml.install.in
deleted file mode 100644
index 98b39ca..0000000
--- a/debian/libxml-light-ocaml.install.in
+++ /dev/null
@@ -1 +0,0 @@
-debian/META.xml-light @OCamlStdlibDir@/METAS/
diff --git a/debian/patches/01_installopt.diff 
b/debian/patches/01_installopt.diff
deleted file mode 100755
index 9eeba42..0000000
--- a/debian/patches/01_installopt.diff
+++ /dev/null
@@ -1,17 +0,0 @@
-diff -urNad xml-light-2.2~/Makefile xml-light-2.2/Makefile
---- xml-light-2.2~/Makefile    2005-10-11 23:26:41.000000000 +0200
-+++ xml-light-2.2/Makefile     2005-10-11 23:28:00.000000000 +0200
-@@ -11,8 +11,11 @@
- 
- opt: xml-light.cmxa test_opt.exe
- 
--install: all opt
--      cp xml-light.cmxa xml-light.a xml-light.cma xml.mli xmlParser.mli 
dtd.mli xml.cmi xmlParser.cmi dtd.cmi xml.cmx dtd.cmx xmlParser.cmx 
$(INSTALLDIR)
-+install: all 
-+      cp xml-light.cma xml.mli xmlParser.mli dtd.mli xml.cmi xmlParser.cmi 
dtd.cmi  $(INSTALLDIR)
-+
-+installopt: opt all 
-+      cp xml-light.a xml-light.cmxa xml.cmx dtd.cmx xmlParser.cmx 
$(INSTALLDIR)
- 
- doc:
-       mkdir doc
diff --git a/debian/patches/02_cmi_depends.diff 
b/debian/patches/02_cmi_depends.diff
deleted file mode 100755
index 7e40f2a..0000000
--- a/debian/patches/02_cmi_depends.diff
+++ /dev/null
@@ -1,11 +0,0 @@
-diff -urNad xml-light-2.2~/Makefile xml-light-2.2/Makefile
---- xml-light-2.2~/Makefile    2006-01-03 17:34:23.000000000 +0100
-+++ xml-light-2.2/Makefile     2006-01-03 17:35:04.000000000 +0100
-@@ -82,6 +82,6 @@
- .mll.ml:
-       ocamllex $<
- 
--.mly.ml:
-+%.mli %.ml: %.mly
-       ocamlyacc $<
- 
diff --git a/debian/patches/03_cflags.diff b/debian/patches/03_cflags.diff
deleted file mode 100755
index fd58404..0000000
--- a/debian/patches/03_cflags.diff
+++ /dev/null
@@ -1,44 +0,0 @@
-diff -urNad xml-light-2.2~/Makefile xml-light-2.2/Makefile
---- xml-light-2.2~/Makefile    2006-10-26 00:22:41.000000000 +0200
-+++ xml-light-2.2/Makefile     2006-10-26 00:24:45.000000000 +0200
-@@ -3,8 +3,8 @@
- .SUFFIXES : .ml .mli .cmo .cmx .cmi .mll .mly
- 
- INSTALLDIR=`ocamlc -where`
--CFLAGS=
--LFLAGS= -a
-+XML_LIGHT_OCAML_CFLAGS= $(OCAML_CFLAGS)
-+XML_LIGHT_OCAML_LFLAGS= $(OCAML_LFLAGS) -a
- LIBS=
- 
- all: xml-light.cma test.exe doc
-@@ -28,10 +28,10 @@
-       ocamlopt xml-light.cmxa test.ml -o test_opt.exe
- 
- xml-light.cma: xml_parser.cmo xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo 
--      ocamlc -o xml-light.cma $(LFLAGS) $(LIBS) xml_parser.cmo xml_lexer.cmo 
dtd.cmo xmlParser.cmo xml.cmo
-+      ocamlc -o xml-light.cma $(XML_LIGHT_OCAML_LFLAGS) $(LIBS) 
xml_parser.cmo xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo
- 
- xml-light.cmxa: xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx 
--      ocamlopt -o xml-light.cmxa $(LFLAGS) $(LIBS) xml_parser.cmx 
xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
-+      ocamlopt -o xml-light.cmxa $(XML_LIGHT_OCAML_LFLAGS) $(LIBS) 
xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
- 
- dtd.cmo: xml.cmi xml_lexer.cmi dtd.cmi
- 
-@@ -71,13 +71,13 @@
- 
- # SUFFIXES
- .ml.cmo:
--      ocamlc $(CFLAGS) -c $<
-+      ocamlc $(XML_LIGHT_OCAML_CFLAGS) -c $<
- 
- .ml.cmx:
--      ocamlopt $(CFLAGS) -c $<
-+      ocamlopt $(XML_LIGHT_OCAML_CFLAGS) -c $<
- 
- .mli.cmi:
--      ocamlc $(CFLAGS) $<
-+      ocamlc $(XML_LIGHT_OCAML_CFLAGS) $<
- 
- .mll.ml:
-       ocamllex $<
diff --git a/debian/patches/04_dtd_trace.diff b/debian/patches/04_dtd_trace.diff
deleted file mode 100755
index ac72387..0000000
--- a/debian/patches/04_dtd_trace.diff
+++ /dev/null
@@ -1,19 +0,0 @@
-diff -urNad xml-light-2.2~/dtd.ml xml-light-2.2/dtd.ml
---- xml-light-2.2~/dtd.ml      2005-02-18 10:01:54.000000000 +0100
-+++ xml-light-2.2/dtd.ml       2006-10-26 23:22:25.000000000 +0200
-@@ -267,7 +267,7 @@
- exception TmpResult of dtd_result
- 
- let prove_child dtd tag = 
--      trace dtd tag;
-+      (*trace dtd tag;*)
-       match dtd.current with
-       | DTDEmpty -> raise (Prove_error EmptyExpected)
-       | DTDAny -> ()
-@@ -505,4 +505,4 @@
-               sprintf "<!ELEMENT %s %s>" tag (etype_to_string etype)
- 
- ;;
--to_string_ref := to_string
-\ No newline at end of file
-+to_string_ref := to_string
diff --git a/debian/patches/05_cmxs_plugin.diff 
b/debian/patches/05_cmxs_plugin.diff
deleted file mode 100644
index 0f41270..0000000
--- a/debian/patches/05_cmxs_plugin.diff
+++ /dev/null
@@ -1,28 +0,0 @@
---- a/Makefile
-+++ b/Makefile
-@@ -9,13 +9,13 @@
- 
- all: xml-light.cma test.exe doc
- 
--opt: xml-light.cmxa test_opt.exe
-+opt: xml-light.cmxs test_opt.exe
- 
- install: all 
-       cp xml-light.cma xml.mli xmlParser.mli dtd.mli xml.cmi xmlParser.cmi 
dtd.cmi  $(INSTALLDIR)
- 
- installopt: opt all 
--      cp xml-light.a xml-light.cmxa xml.cmx dtd.cmx xmlParser.cmx 
$(INSTALLDIR)
-+      cp xml-light.a xml-light.cmxa xml-light.cmxs xml.cmx dtd.cmx 
xmlParser.cmx $(INSTALLDIR)
- 
- doc:
-       mkdir doc
-@@ -33,6 +33,9 @@
- xml-light.cmxa: xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx 
-       ocamlopt -o xml-light.cmxa $(XML_LIGHT_OCAML_LFLAGS) $(LIBS) 
xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
- 
-+xml-light.cmxs: xml-light.cmxa
-+      ocamlopt -o xml-light.cmxs -shared -linkall xml-light.cmxa
-+
- dtd.cmo: xml.cmi xml_lexer.cmi dtd.cmi
- 
- dtd.cmx: xml.cmi xml_lexer.cmi dtd.cmi
diff --git a/debian/patches/06_CVE-2012-3514.diff 
b/debian/patches/06_CVE-2012-3514.diff
deleted file mode 100644
index 8db0bc9..0000000
--- a/debian/patches/06_CVE-2012-3514.diff
+++ /dev/null
@@ -1,153 +0,0 @@
---- a/dtd.ml
-+++ b/dtd.ml
-@@ -93,16 +93,18 @@
- 
- type dtd = dtd_item list
- 
--type ('a,'b) hash = ('a,'b) Hashtbl.t
-+module StringMap = Map.Make(String)
-+
-+type 'a map = 'a StringMap.t ref
- 
- type checked = {
--      c_elements : (string,dtd_element_type) hash;
--      c_attribs : (string,(string,(dtd_attr_type * dtd_attr_default)) hash) 
hash;
-+      c_elements : dtd_element_type map;
-+      c_attribs : (dtd_attr_type * dtd_attr_default) map map;
- }
- 
- type dtd_state = {
--      elements : (string,dtd_element_type) hash;
--      attribs : (string,(string,(dtd_attr_type * dtd_attr_default)) hash) 
hash;
-+      elements : dtd_element_type map;
-+      attribs : (dtd_attr_type * dtd_attr_default) map map;
-       mutable current : dtd_element_type;
-       mutable curtag : string;
-       state : (string * dtd_element_type) Stack.t;
-@@ -113,7 +115,21 @@
- let _raises e =
-       file_not_found := e
- 
--let empty_hash = Hashtbl.create 0
-+let create_map() = ref StringMap.empty
-+
-+let empty_map = create_map()
-+
-+let find_map m k = StringMap.find k (!m)
-+
-+let set_map m k v = m := StringMap.add k v (!m)
-+
-+let unset_map m k = m := StringMap.remove k (!m)
-+
-+let iter_map f m = StringMap.iter f (!m)
-+
-+let fold_map f m = StringMap.fold f (!m)
-+
-+let mem_map m k = StringMap.mem k (!m)
- 
- let pos source =
-       let line, lstart, min, max = Xml_lexer.pos source in
-@@ -158,45 +174,45 @@
-                       raise e
- 
- let check dtd =
--      let attribs = Hashtbl.create 0 in
--      let hdone = Hashtbl.create 0 in
--      let htodo = Hashtbl.create 0 in
-+      let attribs = create_map () in
-+      let hdone = create_map () in
-+      let htodo = create_map () in
-       let ftodo tag from =
-               try
--                      ignore(Hashtbl.find hdone tag);
-+                      ignore(find_map hdone tag);
-               with
-                       Not_found ->
-                               try
--                                      match Hashtbl.find htodo tag with
--                                      | None -> Hashtbl.replace htodo tag from
-+                                      match find_map htodo tag with
-+                                      | None -> set_map htodo tag from
-                                       | Some _ -> ()
-                               with
-                                       Not_found ->
--                                              Hashtbl.add htodo tag from
-+                                              set_map htodo tag from
-       in
-       let fdone tag edata =
-               try 
--                      ignore(Hashtbl.find hdone tag);
-+                      ignore(find_map hdone tag);
-                       raise (Check_error (ElementDefinedTwice tag));
-               with
-                       Not_found ->
--                              Hashtbl.remove htodo tag;
--                              Hashtbl.add hdone tag edata
-+                              unset_map htodo tag;
-+                              set_map hdone tag edata
-       in
-       let fattrib tag aname adata =
-               let h = (try
--                              Hashtbl.find attribs tag
-+                              find_map attribs tag
-                       with
-                               Not_found ->
--                                      let h = Hashtbl.create 1 in
--                                      Hashtbl.add attribs tag h;
-+                                      let h = create_map () in
-+                                      set_map attribs tag h;
-                                       h) in
-               try
--                      ignore(Hashtbl.find h aname);
-+                      ignore(find_map h aname);
-                       raise (Check_error (AttributeDefinedTwice (tag,aname)));
-               with
-                       Not_found ->
--                              Hashtbl.add h aname adata
-+                              set_map h aname adata
-       in
-       let check_item = function
-               | DTDAttribute (tag,aname,atype,adef) ->
-@@ -229,7 +245,7 @@
-                       check_type etype
-       in
-       List.iter check_item dtd;
--      Hashtbl.iter (fun t from ->
-+      iter_map (fun t from ->
-               match from with
-               | None -> raise (Check_error (ElementNotDeclared t))
-               | Some tag -> raise (Check_error (ElementReferenced (t,tag)))
-@@ -248,7 +264,7 @@
-               curtag = "_root";
-       } in
-       try
--              ignore(Hashtbl.find d.elements (String.uppercase root));
-+              ignore(find_map d.elements (String.uppercase root));
-               d
-       with
-               Not_found -> raise (Check_error (ElementNotDeclared root))
-@@ -365,7 +381,7 @@
- 
- let check_attrib ahash (aname,_) =
-       try
--              ignore(Hashtbl.find ahash aname);
-+              ignore(find_map ahash aname);
-       with
-               Not_found -> raise (Prove_error (UnexpectedAttribute aname))
- 
-@@ -378,12 +394,12 @@
-               let uattr = List.map (fun (aname,aval) -> String.uppercase 
aname , aval) attr in
-               prove_child dtd (Some utag);
-               Stack.push (dtd.curtag,dtd.current) dtd.state;
--              let elt = (try Hashtbl.find dtd.elements utag with Not_found -> 
raise (Prove_error (UnexpectedTag tag))) in
--              let ahash = (try Hashtbl.find dtd.attribs utag with Not_found 
-> empty_hash) in
-+              let elt = (try find_map dtd.elements utag with Not_found -> 
raise (Prove_error (UnexpectedTag tag))) in
-+              let ahash = (try find_map dtd.attribs utag with Not_found -> 
empty_map) in
-               dtd.curtag <- tag;
-               dtd.current <- elt;
-               List.iter (check_attrib ahash) uattr;
--              let attr = Hashtbl.fold (prove_attrib dtd uattr) ahash [] in
-+              let attr = fold_map (prove_attrib dtd uattr) ahash [] in
-               let childs = ref (List.map (do_prove dtd) childs) in
-               (match dtd.current with
-               | DTDAny
diff --git a/debian/patches/cflags.diff b/debian/patches/cflags.diff
new file mode 100644
index 0000000..6872ad3
--- /dev/null
+++ b/debian/patches/cflags.diff
@@ -0,0 +1,48 @@
+Do not use CFLAGS and LFLAGS as custom variable names since they
+are special variables that have default values in Debian.
+
+Index: xml-light/Makefile
+===================================================================
+--- xml-light.orig/Makefile
++++ xml-light/Makefile
+@@ -8,8 +8,8 @@ OCAMLFIND=ocamlfind
+ .SUFFIXES : .ml .mli .cmo .cmx .cmi .mll .mly
+ 
+ INSTALLDIR=`$(OCAMLC) -where`
+-CFLAGS=
+-LFLAGS= -a
++XML_LIGHT_OCAML_CFLAGS= $(OCAML_CFLAGS)
++XML_LIGHT_OCAML_LFLAGS= $(OCAML_LFLAGS) -a
+ LIBS=
+ 
+ NATDYNLINK := $(shell if [ -f `ocamlc -where`/dynlink.cmxa ]; then echo YES; 
else echo NO; fi)
+@@ -54,10 +54,10 @@ test_opt.exe: xml-light.cmxa
+       $(OCAMLOPT) xml-light.cmxa test.ml -o test_opt.exe
+ 
+ xml-light.cma: xml_parser.cmo xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo 
+-      $(OCAMLC) -o xml-light.cma $(LFLAGS) $(LIBS) xml_parser.cmo 
xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo
++      $(OCAMLC) -o xml-light.cma $(XML_LIGHT_OCAML_LFLAGS) $(LIBS) 
xml_parser.cmo xml_lexer.cmo dtd.cmo xmlParser.cmo xml.cmo
+ 
+ xml-light.cmxa: xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx 
+-      $(OCAMLOPT) -o xml-light.cmxa $(LFLAGS) $(LIBS) xml_parser.cmx 
xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
++      $(OCAMLOPT) -o xml-light.cmxa $(XML_LIGHT_OCAML_LFLAGS) $(LIBS) 
xml_parser.cmx xml_lexer.cmx dtd.cmx xmlParser.cmx xml.cmx
+ 
+ xml-light.cmxs: xml-light.cmxa
+       $(OCAMLOPT) -shared -linkall -I . -o xml-light.cmxs xml-light.cmxa
+@@ -99,13 +99,13 @@ clean:
+ 
+ # SUFFIXES
+ .ml.cmo:
+-      $(OCAMLC) $(CFLAGS) -c $<
++      $(OCAMLC) $(XML_LIGHT_OCAML_CFLAGS) -c $<
+ 
+ .ml.cmx:
+-      $(OCAMLOPT) $(CFLAGS) -c $<
++      $(OCAMLOPT) $(XML_LIGHT_OCAML_CFLAGS) -c $<
+ 
+ .mli.cmi:
+-      $(OCAMLC) $(CFLAGS) $<
++      $(OCAMLC) $(XML_LIGHT_OCAML_CFLAGS) $<
+ 
+ .mll.ml:
+       ocamllex $<
diff --git a/debian/patches/series b/debian/patches/series
index 4fe10ca..27176b8 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,6 +1 @@
-01_installopt.diff
-02_cmi_depends.diff
-03_cflags.diff
-04_dtd_trace.diff
-05_cmxs_plugin.diff
-06_CVE-2012-3514.diff
+cflags.diff
diff --git a/debian/rules b/debian/rules
index 3cd5a50..4429134 100755
--- a/debian/rules
+++ b/debian/rules
@@ -32,7 +32,7 @@ ifeq ($(OCAML_HAVE_OCAMLOPT),yes)
 DEB_MAKE_BUILD_TARGET    += opt
 endif
 
-DEB_MAKE_INSTALL_TARGET  := install
+DEB_MAKE_INSTALL_TARGET  := installbyte
 ifeq ($(OCAML_HAVE_OCAMLOPT),yes)
 DEB_MAKE_INSTALL_TARGET  += installopt
 endif
@@ -44,7 +44,8 @@ clean::
 install/libxml-light-ocaml:: install/libxml-light-ocaml-dev
        VERSION=$(DEB_NOEPOCH_VERSION); \
        VERSION=$${VERSION%%-*}; \
-       sed -i "s/@VERSION@/$$VERSION/g" '$(CURDIR)/debian/META.xml-light'
+       cp META.in $(DESTDIR_RUN)/$(OCAML_STDLIB_DIR)/xml-light/META; \
+       sed -i "s/@VERSION@/$$VERSION/g" 
'$(DESTDIR_RUN)/$(OCAML_STDLIB_DIR)/xml-light/META'
 
        mv $(DESTDIR_DEV)/$(OCAML_STDLIB_DIR)/xml-light/xml-light.cma \
                $(DESTDIR_RUN)/$(OCAML_STDLIB_DIR)/xml-light

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-ocaml-maint/packages/xml-light.git

_______________________________________________
Pkg-ocaml-maint-commits mailing list
Pkg-ocaml-maint-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-ocaml-maint-commits

Reply via email to