[Pkg-ocaml-maint-commits] [SCM] camlimages packaging branch, master, updated. debian/3.0.1-5-14-g682d33e

Sylvain Le Gall gildor at debian.org
Fri Jul 2 01:26:54 UTC 2010


The following commit has been merged in the master branch:
commit dd8d14d21f7c7442efd641d045f8e73bb064a602
Author: Sylvain Le Gall <gildor at debian.org>
Date:   Mon Mar 1 23:46:28 2010 +0000

    Switch to dpkg-source 3.0 (quilt) format

diff --git a/debian/changelog b/debian/changelog
index 056ffb4..8177c91 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,8 @@ camlimages (1:3.0.2-1) UNRELEASED; urgency=low
 
   [ Sylvain Le Gall ]
   * New upstream release
+  * Update debian/watch files
+  * Switch to dpkg-source 3.0 (quilt) format
 
  -- Sylvain Le Gall <gildor at debian.org>  Mon, 01 Mar 2010 22:55:18 +0000
 
diff --git a/debian/control b/debian/control
index d0a6bc6..50662ab 100644
--- a/debian/control
+++ b/debian/control
@@ -8,9 +8,7 @@ Uploaders:  Ralf Treinen <treinen at debian.org>,
  Mehdi Dogguy <mehdi at debian.org>
 Build-Depends: cdbs (>= 0.4.23), 
  debhelper (>= 5), 
- dpatch, 
- ocaml-nox (>= 3.11.1),
- ocaml, 
+ ocaml (>= 3.11.1), 
  ocaml-findlib (>> 1.2.5),
  libpng12-dev, 
  libjpeg62-dev, 
diff --git a/debian/patches/00list b/debian/patches/00list
deleted file mode 100644
index 1df093e..0000000
--- a/debian/patches/00list
+++ /dev/null
@@ -1 +0,0 @@
-tiffread
diff --git a/debian/patches/tiffread.dpatch b/debian/patches/Integer-Overflows-tiffread.c
old mode 100755
new mode 100644
similarity index 56%
rename from debian/patches/tiffread.dpatch
rename to debian/patches/Integer-Overflows-tiffread.c
index 78b2bca..92fbef7
--- a/debian/patches/tiffread.dpatch
+++ b/debian/patches/Integer-Overflows-tiffread.c
@@ -1,13 +1,7 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## tiffread.dpatch by Mehdi Dogguy <mehdi at debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Fix integer overflows in tiffread.c (CVE-2009-3296)
-
- at DPATCH@
-diff -urNad camlimages~/src/tiffread.c camlimages/src/tiffread.c
---- camlimages~/src/tiffread.c	2009-10-31 21:47:57.000000000 +0100
-+++ camlimages/src/tiffread.c	2009-11-01 13:51:58.000000000 +0100
+Index: camlimages/src/tiffread.c
+===================================================================
+--- camlimages.orig/src/tiffread.c	2010-03-01 23:20:20.000000000 +0000
++++ camlimages/src/tiffread.c	2010-03-01 23:41:11.000000000 +0000
 @@ -21,6 +21,8 @@
  #include <caml/memory.h>
  #include <caml/fail.h>
diff --git a/debian/patches/fix_3_0_1_release.dpatch b/debian/patches/fix_3_0_1_release.dpatch
deleted file mode 100755
index 0e7c083..0000000
--- a/debian/patches/fix_3_0_1_release.dpatch
+++ /dev/null
@@ -1,97 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## fix_3_0_1_release.dpatch by Sylvain Le Gall <gildor at debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Fix bugs in the release 3.0.1 for OCaml 3.11 migration 
-
- at DPATCH@
-diff -urNad camlimages~/examples/liv/liv.ml camlimages/examples/liv/liv.ml
---- camlimages~/examples/liv/liv.ml	2009-03-17 22:47:59.000000000 +0100
-+++ camlimages/examples/liv/liv.ml	2009-03-17 22:49:11.000000000 +0100
-@@ -12,6 +12,9 @@
- 
- (* $Id: liv.ml,v 1.7 2006/09/29 13:21:41 rousse Exp $ *)
- 
-+module D = Display
-+open D
-+
- open Images;;
- open OImages;;
- 
-@@ -21,14 +24,13 @@
- 
- open Livmisc;;
- open Gui;;
--open Display;;
- open Tout;;
- 
- open Gc;;
- 
- exception Skipped;;
- 
--let base_filters = ref ([] : Display.filter list);;
-+let base_filters = ref ([] : D.filter list);;
- 
- let r = Gc.get () in
- r.max_overhead <- 0; Gc.set r;
-@@ -52,15 +54,15 @@
-   "-root",
-     Arg.String
-       (function
--       | "center" -> Display.root_mode := `CENTER
--       | "random" -> Display.root_mode := `RANDOM
-+       | "center" -> D.root_mode := `CENTER
-+       | "random" -> D.root_mode := `RANDOM
-        | _ -> raise (Failure "root mode")),
-     ": on root [center|random]";
-   "-transition",
-     Arg.String
-       (function
--       | "myst" -> Display.transition := `MYST
--       | "transparent" -> Display.transition := `TRANSPARENT
-+       | "myst" -> D.transition := `MYST
-+       | "transparent" -> D.transition := `TRANSPARENT
-        | _ -> raise (Failure "transition")),
-     ": transition [myst|transparent]";
-   "-transparentborder",
-diff -urNad camlimages~/src/Makefile.am camlimages/src/Makefile.am
---- camlimages~/src/Makefile.am	2009-03-17 22:47:59.000000000 +0100
-+++ camlimages/src/Makefile.am	2009-03-17 22:49:11.000000000 +0100
-@@ -85,6 +85,7 @@
- 		  oColor.mli \
- 		  oImages.mli \
- 		  reduce.mli \
-+		  geometry.mli \
- 	 	  blend.mli \
- 		  graphic_image.mli \
- 		  bmp.mli \
-diff -urNad camlimages~/src/Makefile.in camlimages/src/Makefile.in
---- camlimages~/src/Makefile.in	2009-03-17 22:47:59.000000000 +0100
-+++ camlimages/src/Makefile.in	2009-03-17 22:49:11.000000000 +0100
-@@ -341,6 +341,7 @@
- 	  	  images.mli \
- 		  oColor.mli \
- 		  oImages.mli \
-+		  geometry.mli \
- 		  reduce.mli \
- 	 	  blend.mli \
- 		  graphic_image.mli \
-diff -urNad camlimages~/src/geometry.mli camlimages/src/geometry.mli
---- camlimages~/src/geometry.mli	1970-01-01 01:00:00.000000000 +0100
-+++ camlimages/src/geometry.mli	2009-03-17 22:49:26.000000000 +0100
-@@ -0,0 +1,15 @@
-+type size = Scale of float | Pixel of int | Guess
-+type aspect_opts = Keep_at_most | Keep_at_least | Dont_keep
-+type resize_switch = Always | Bigger_only | Smaller_only
-+type from = TopLeft | BottomRight | Center
-+type position = AtPixel of from * int | AtScale of from * float
-+type t = { geom_width : int; geom_height : int; geom_x : int; geom_y : int; }
-+type spec = {
-+  spec_width : size;
-+  spec_height : size;
-+  spec_aspect : aspect_opts;
-+  spec_switch : resize_switch;
-+  spec_x : int;
-+  spec_y : int;
-+}
-+val compute : spec -> int -> int -> t
diff --git a/debian/patches/fix_integer_overflows.dpatch b/debian/patches/fix_integer_overflows.dpatch
deleted file mode 100755
index a2daeec..0000000
--- a/debian/patches/fix_integer_overflows.dpatch
+++ /dev/null
@@ -1,89 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## fix_integer_overflows.dpatch by Mehdi Dogguy <dogguy at pps.jussieu.fr>
-##
-## DP: Fix multiple integer overflows.
-## DP: http://www.ocert.org/advisories/ocert-2009-009.html
-
- at DPATCH@
-diff -urNad camlimages~/src/pngread.c camlimages/src/pngread.c
---- camlimages~/src/pngread.c	2009-06-23 11:22:20.000000000 +0200
-+++ camlimages/src/pngread.c	2009-07-03 17:51:31.000000000 +0200
-@@ -15,6 +15,8 @@
- #include "config.h"
- #endif
- 
-+#include <limits.h>
-+
- #include <png.h>
- 
- #include <caml/mlvalues.h>
-@@ -26,6 +28,12 @@
- #define PNG_TAG_INDEX16 2
- #define PNG_TAG_INDEX4 3
- 
-+/* Test if x or y are negative, or if multiplying x * y would cause an
-+ * arithmetic overflow.
-+ */
-+#define oversized(x, y)						\
-+  ((x) < 0 || (y) < 0 || ((y) != 0 && (x) > INT_MAX / (y)))
-+
- value read_png_file_as_rgb24( name )
-      value name;
- {
-@@ -81,6 +89,9 @@
-   png_get_IHDR(png_ptr, info_ptr, &width, &height, &bit_depth, &color_type,
- 	       &interlace_type, NULL, NULL);
- 
-+  if (oversized (width, height))
-+    failwith ("png error: image contains oversized or bogus width and height");
-+
-   if ( color_type == PNG_COLOR_TYPE_GRAY ||
-        color_type == PNG_COLOR_TYPE_GRAY_ALPHA ) { 
-     png_set_gray_to_rgb(png_ptr); 
-@@ -102,10 +113,16 @@
- 
-   rowbytes = png_get_rowbytes(png_ptr, info_ptr);
- 
-+  if (oversized (rowbytes, height))
-+    failwith ("png error: image contains oversized or bogus rowbytes and height");
-+
-   {
-     int i;
-     png_bytep *row_pointers;
- 
-+    if (oversized (sizeof (png_bytep), height))
-+      failwith ("png error: image contains oversized or bogus height");
-+
-     row_pointers = (png_bytep*) stat_alloc(sizeof(png_bytep) * height);
- 
-     res = alloc_tuple(3);
-@@ -235,6 +252,9 @@
-   png_get_IHDR(png_ptr, info_ptr, &width, &height, &bit_depth, &color_type,
- 	       &interlace_type, NULL, NULL);
- 
-+  if (oversized (width, height))
-+    failwith ("png error: image contains oversized or bogus width and height");
-+
-   if ( color_type == PNG_COLOR_TYPE_GRAY ||
-        color_type == PNG_COLOR_TYPE_GRAY_ALPHA ) { 
-     png_set_gray_to_rgb(png_ptr); 
-@@ -251,6 +271,9 @@
- 
-   rowbytes = png_get_rowbytes(png_ptr, info_ptr);
- 
-+  if (oversized (rowbytes, height))
-+    failwith ("png error: image contains oversized or bogus rowbytes and height");
-+
- /*
- fprintf(stderr, "pngread.c: actual loading\n"); fflush(stderr);
- */
-@@ -259,6 +282,9 @@
-     png_bytep *row_pointers;
-     char mesg[256];
-  
-+    if (oversized (sizeof (png_bytep), height))
-+      failwith ("png error: image contains oversized or bogus height");
-+
-     row_pointers = (png_bytep*)stat_alloc(sizeof(png_bytep) * height);
-     res = alloc_tuple(3);
- 
diff --git a/debian/patches/fix_more_integer_overflows.dpatch b/debian/patches/fix_more_integer_overflows.dpatch
deleted file mode 100755
index 9277d7c..0000000
--- a/debian/patches/fix_more_integer_overflows.dpatch
+++ /dev/null
@@ -1,167 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## fix_more_integer_overflows.dpatch by Sylvain Le Gall <gildor at debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Fix multiple integer overflows round 2.
-## DP: http://security-tracker.debian.net/tracker/CVE-2009-2660
-
- at DPATCH@
-diff -urNad camlimages~/src/gifread.c camlimages/src/gifread.c
---- camlimages~/src/gifread.c	2009-07-31 22:57:24.000000000 +0200
-+++ camlimages/src/gifread.c	2009-08-07 23:45:01.000000000 +0200
-@@ -20,6 +20,8 @@
- #include <caml/memory.h>
- #include <caml/fail.h>
- 
-+#include "oversized.h"
-+
- #include <stdio.h>
- #include <string.h>
- 
-@@ -191,6 +193,9 @@
- 
-   GifFileType *GifFile = (GifFileType*) hdl;
- 
-+  if( oversized( GifFile->Image.Width, sizeof(GifPixelType) ) ){
-+    failwith_oversized("gif");
-+  }
-   buf = alloc_string( GifFile->Image.Width * sizeof(GifPixelType) ); 
- 
-   if( DGifGetLine(GifFile, String_val(buf), GifFile->Image.Width ) 
-diff -urNad camlimages~/src/jpegread.c camlimages/src/jpegread.c
---- camlimages~/src/jpegread.c	2009-07-31 22:57:24.000000000 +0200
-+++ camlimages/src/jpegread.c	2009-08-07 23:45:01.000000000 +0200
-@@ -20,6 +20,8 @@
- #include <caml/memory.h>
- #include <caml/fail.h>
- 
-+#include "oversized.h"
-+
- #include <stdio.h>
- #include <string.h>
- 
-@@ -156,6 +158,12 @@
-    */ 
-   /* JSAMPLEs per row in output buffer */
- 
-+  if( oversized(cinfo.output_width, cinfo.output_components) ){
-+    jpeg_destroy_decompress(&cinfo);
-+    fclose(infile);
-+    failwith_oversized("jpeg");
-+  }
-+
-   row_stride = cinfo.output_width * cinfo.output_components;
- 
-   /* Make a one-row-high sample array that will go away when done with image */
-@@ -177,6 +185,12 @@
-     jpeg_read_scanlines(&cinfo, buffer + cinfo.output_scanline, 1); 
-   }
- 
-+  if( oversized(row_stride, cinfo.output_height) ){
-+    jpeg_destroy_decompress(&cinfo);
-+    fclose(infile);
-+    failwith_oversized("jpeg");
-+  }
-+
-   {
-     CAMLlocalN(r,3);
-     r[0] = Val_int(cinfo.output_width);
-@@ -352,6 +366,7 @@
- 
-   { 
-     CAMLlocalN(r,3);
-+    // CR jfuruse: integer overflow
-     r[0] = Val_int(cinfop->output_width);
-     r[1] = Val_int(cinfop->output_height);
-     r[2] = alloc_tuple(3);
-diff -urNad camlimages~/src/oversized.h camlimages/src/oversized.h
---- camlimages~/src/oversized.h	1970-01-01 01:00:00.000000000 +0100
-+++ camlimages/src/oversized.h	2009-08-07 23:45:01.000000000 +0200
-@@ -0,0 +1,9 @@
-+#include <limits.h>
-+/* Test if x or y are negative, or if multiplying x * y would cause an
-+ * arithmetic overflow.
-+ */
-+#define oversized(x, y)						\
-+  ((x) < 0 || (y) < 0 || ((y) != 0 && (x) > INT_MAX / (y)))
-+
-+#define failwith_oversized(lib) \
-+  failwith("#lib error: image contains oversized or bogus width and height");
-diff -urNad camlimages~/src/pngread.c camlimages/src/pngread.c
---- camlimages~/src/pngread.c	2009-08-07 23:44:02.000000000 +0200
-+++ camlimages/src/pngread.c	2009-08-07 23:51:15.000000000 +0200
-@@ -19,6 +19,8 @@
- 
- #include <png.h>
- 
-+#include "oversized.h"
-+
- #include <caml/mlvalues.h>
- #include <caml/alloc.h>
- #include <caml/memory.h>
-@@ -28,12 +30,6 @@
- #define PNG_TAG_INDEX16 2
- #define PNG_TAG_INDEX4 3
- 
--/* Test if x or y are negative, or if multiplying x * y would cause an
-- * arithmetic overflow.
-- */
--#define oversized(x, y)						\
--  ((x) < 0 || (y) < 0 || ((y) != 0 && (x) > INT_MAX / (y)))
--
- value read_png_file_as_rgb24( name )
-      value name;
- {
-@@ -90,7 +86,7 @@
- 	       &interlace_type, NULL, NULL);
- 
-   if (oversized (width, height))
--    failwith ("png error: image contains oversized or bogus width and height");
-+    failwith_oversized("png");
- 
-   if ( color_type == PNG_COLOR_TYPE_GRAY ||
-        color_type == PNG_COLOR_TYPE_GRAY_ALPHA ) { 
-@@ -114,14 +110,14 @@
-   rowbytes = png_get_rowbytes(png_ptr, info_ptr);
- 
-   if (oversized (rowbytes, height))
--    failwith ("png error: image contains oversized or bogus rowbytes and height");
-+    failwith_oversized("png");
- 
-   {
-     int i;
-     png_bytep *row_pointers;
- 
-     if (oversized (sizeof (png_bytep), height))
--      failwith ("png error: image contains oversized or bogus height");
-+      failwith_oversized("png");
- 
-     row_pointers = (png_bytep*) stat_alloc(sizeof(png_bytep) * height);
- 
-@@ -253,7 +249,7 @@
- 	       &interlace_type, NULL, NULL);
- 
-   if (oversized (width, height))
--    failwith ("png error: image contains oversized or bogus width and height");
-+    failwith_oversized("png");
- 
-   if ( color_type == PNG_COLOR_TYPE_GRAY ||
-        color_type == PNG_COLOR_TYPE_GRAY_ALPHA ) { 
-@@ -272,7 +268,7 @@
-   rowbytes = png_get_rowbytes(png_ptr, info_ptr);
- 
-   if (oversized (rowbytes, height))
--    failwith ("png error: image contains oversized or bogus rowbytes and height");
-+    failwith_oversized("png");
- 
- /*
- fprintf(stderr, "pngread.c: actual loading\n"); fflush(stderr);
-@@ -283,7 +279,7 @@
-     char mesg[256];
-  
-     if (oversized (sizeof (png_bytep), height))
--      failwith ("png error: image contains oversized or bogus height");
-+      failwith_oversized("png");
- 
-     row_pointers = (png_bytep*)stat_alloc(sizeof(png_bytep) * height);
-     res = alloc_tuple(3);
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..fd7c550
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+Integer-Overflows-tiffread.c
diff --git a/debian/rules b/debian/rules
index 1bd05c9..03d62a3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -17,10 +17,9 @@
 # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 # MA 02110-1301, USA.
 
-include /usr/share/cdbs/1/rules/dpatch.mk
+include /usr/share/cdbs/1/rules/ocaml.mk
 include /usr/share/cdbs/1/rules/debhelper.mk
 include /usr/share/cdbs/1/class/autotools.mk
-include /usr/share/cdbs/1/rules/ocaml.mk
 
 PACKAGE := libcamlimages-ocaml
 DESTDIR := $(CURDIR)/debian/$(PACKAGE)
@@ -35,7 +34,7 @@ LABLGTK2_DIR := $(shell ocamlfind query lablgtk2)
 
 DEB_CONFIGURE_EXTRA_FLAGS := --with-lablgtk2 --without-lablgtk
 
-DEB_MAKE_CLEAN_TARGET     := distclean
+DEB_MAKE_CLEAN_TARGET     := clean
 
 DEB_INSTALL_EXAMPLES_libcamlimages-ocaml-doc := -X Makefile -X .depend
 DEB_DH_INSTALL_ARGS                          := -X LICENSE -X README -X INSTALL -X Makefile
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)

-- 
camlimages packaging



More information about the Pkg-ocaml-maint-commits mailing list