Bug#699304: libmng: diff for NMU version 1.0.10+dfsg-3.1

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Bug#699304: libmng: diff for NMU version 1.0.10+dfsg-3.1

Tobias Frost-3
tags 699304 + patch
tags 699304 + pending
tags 745525 + patch
tags 745525 + pending
thanks

Dear maintainer,

I've prepared an NMU for libmng (versioned as 1.0.10+dfsg-3.1) and uploaded it
to DELAYED/5. Please feel free to tell me if I should delay it longer.

Regards.

--
tobi

Binary files /tmp/gpYxIQ67pL/libmng-1.0.10/contrib/msvc/mngview/sRGB.icm and /tmp/OiF0VWc2ny/libmng-1.0.10+dfsg/contrib/msvc/mngview/sRGB.icm differ
diff -Nru libmng-1.0.10/debian/changelog libmng-1.0.10+dfsg/debian/changelog
--- libmng-1.0.10/debian/changelog 2011-09-16 17:41:19.000000000 +0200
+++ libmng-1.0.10+dfsg/debian/changelog 2014-08-03 13:30:49.000000000 +0200
@@ -1,3 +1,13 @@
+libmng (1.0.10+dfsg-3.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Buld against lcms2: new patch support-lcms2.patch (Closes: #745525)
+    The patch cherry-picks the relevant changes from the new upstream version.
+  * Repack tarball using Exclude-Files in d/copyright to remove non-free
+    file contrib/msvc/mngview/sRGB.icm (Closes: #699304).
+
+ --  Tobias Frost <[hidden email]>  Sun, 03 Aug 2014 13:20:17 +0000
+
 libmng (1.0.10-3) unstable; urgency=low
 
   * debian/control:
diff -Nru libmng-1.0.10/debian/control libmng-1.0.10+dfsg/debian/control
--- libmng-1.0.10/debian/control 2011-09-16 18:18:21.000000000 +0200
+++ libmng-1.0.10+dfsg/debian/control 2014-08-03 13:06:38.000000000 +0200
@@ -3,7 +3,7 @@
 Priority: optional
 Build-Depends: debhelper (>= 8.1.3),
                libjpeg-dev,
-               liblcms1-dev,
+               liblcms2-dev,
                libtool,
                zlib1g-dev
 Maintainer: Kartik Mistry <[hidden email]>
@@ -31,7 +31,7 @@
 Depends: ${misc:Depends},
          libmng1 (= ${binary:Version}),
          libjpeg-dev,
-         liblcms1-dev,
+         liblcms2-dev,
          zlib1g-dev
 Description: M-N-G library (Development headers)
  The libmng library supports decoding, displaying, encoding, and various other
diff -Nru libmng-1.0.10/debian/copyright libmng-1.0.10+dfsg/debian/copyright
--- libmng-1.0.10/debian/copyright 2011-09-16 17:22:20.000000000 +0200
+++ libmng-1.0.10+dfsg/debian/copyright 2014-08-03 13:19:56.000000000 +0200
@@ -1,6 +1,7 @@
-Format: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=174
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
 Upstream-Name: libmng
 Source: http://www.libmng.com
+Files-Excluded: contrib/msvc/mngview/sRGB.icm
 
 Files: *
 Copyright: (C) 2000, Gerard Juyn <[hidden email]>
diff -Nru libmng-1.0.10/debian/patches/series libmng-1.0.10+dfsg/debian/patches/series
--- libmng-1.0.10/debian/patches/series 2010-06-12 11:27:40.000000000 +0200
+++ libmng-1.0.10+dfsg/debian/patches/series 2014-08-03 13:01:59.000000000 +0200
@@ -1,3 +1,4 @@
 linux-makefile.diff
 kfreebsd-build-fix.diff
 manpage-typo-fixes.diff
+support-lcms2.patch
diff -Nru libmng-1.0.10/debian/patches/support-lcms2.patch libmng-1.0.10+dfsg/debian/patches/support-lcms2.patch
--- libmng-1.0.10/debian/patches/support-lcms2.patch 1970-01-01 01:00:00.000000000 +0100
+++ libmng-1.0.10+dfsg/debian/patches/support-lcms2.patch 2014-08-03 13:25:42.000000000 +0200
@@ -0,0 +1,189 @@
+Description: Patch to support lcms2
+ Cherry-pick lcms2-support from new upstream version 2.0.2
+Author: Tobias Frost <[hidden email]>
+Forwarded: not-needed
+Last-Update: 2014-08-03
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/libmng_cms.c
++++ b/libmng_cms.c
+@@ -86,6 +86,9 @@
+ #pragma option -A                      /* force ANSI-C */
+ #endif
+
++#undef HAVE_LIBLCMS1
++#define HAVE_LIBLCMS2
++
+ /* ************************************************************************** */
+
+ #ifdef MNG_INCLUDE_DISPLAY_PROCS
+@@ -104,7 +107,9 @@
+
+ void mnglcms_initlibrary ()
+ {
++#ifdef HAVE_LIBLCMS1
+   cmsErrorAction (LCMS_ERROR_IGNORE);  /* LCMS should ignore errors! */
++#endif
+ }
+
+ /* ************************************************************************** */
+@@ -132,14 +137,30 @@
+                                       {0.3000, 0.6000, 1.0},
+                                       {0.1500, 0.0600, 1.0}
+                                     };
++#ifdef HAVE_LIBLCMS1
+   LPGAMMATABLE    Gamma24[3];
++#elif defined(HAVE_LIBLCMS2)
++  cmsToneCurve* Gamma24[3];
++#endif
+   mng_cmsprof     hsRGB;
+
++#ifdef HAVE_LIBLCMS1
+   cmsWhitePointFromTemp(6504, &D65);
+-  Gamma24[0] = Gamma24[1] = Gamma24[2] = cmsBuildGamma(256, 2.4);
++#elif defined(HAVE_LIBLCMS2)
++  cmsWhitePointFromTemp(&D65, 6504);
++#endif
++  Gamma24[0] = Gamma24[1] = Gamma24[2] =
++#ifdef HAVE_LIBLCMS1
++ cmsBuildGamma(256, 2.4);
++#elif defined(HAVE_LIBLCMS2)
++ cmsBuildGamma(NULL, 2.4);
++#endif
+   hsRGB = cmsCreateRGBProfile(&D65, &Rec709Primaries, Gamma24);
++#ifdef HAVE_LIBLCMS1
+   cmsFreeGamma(Gamma24[0]);
+-
++#elif defined(HAVE_LIBLCMS2)
++  cmsFreeToneCurve(Gamma24[0]);
++#endif
+   return hsRGB;
+ }
+
+@@ -368,16 +389,22 @@
+
+       pGammatable [0] =                /* and build the lookup tables */
+       pGammatable [1] =
+-      pGammatable [2] = cmsBuildGamma (256, dGamma);
+-
++      pGammatable [2] =
++#ifdef HAVE_LIBLCMS1
++ cmsBuildGamma (256, dGamma);
++#elif defined(HAVE_LIBLCMS2)
++ cmsBuildGamma(NULL, dGamma);
++#endif
+       if (!pGammatable [0])            /* enough memory ? */
+         MNG_ERRORL (pData, MNG_LCMS_NOMEM);
+                                        /* create the profile */
+       hProf = cmsCreateRGBProfile (&sWhitepoint, &sPrimaries, pGammatable);
+-
++#ifdef HAVE_LIBLCMS1
+       cmsFreeGamma (pGammatable [0]);  /* free the temporary gamma tables ? */
+                                        /* yes! but just the one! */
+-
++#elif defined(HAVE_LIBLCMS2)
++  cmsFreeToneCurve(pGammatable [0]);
++#endif
+       pData->hProf1 = hProf;           /* save for future use */
+
+       if (!hProf)                      /* handle error ? */
+--- a/makefiles/makefile.linux
++++ b/makefiles/makefile.linux
+@@ -50,7 +50,7 @@
+ -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) \
+ -L$(JPEGLIB) -Wl,-rpath,$(JPEGLIB) \
+ -L$(LCMSLIB) -Wl,-rpath,$(LCMSLIB) \
+- -lmng -lz -ljpeg -llcms -lm
++ -lmng -lz -ljpeg -llcms2 -lm
+
+ RANLIB=ranlib
+ #RANLIB=echo
+@@ -107,7 +107,7 @@
+ # $(CC) -shared -Wl,-soname,libmng.so.$(MNGMAJ) -o libmng.so.$(MNGVER) \
+ # $(OBJSDLL) -L$(ZLIBLIB) -L$(JPEGLIB) -L$(LCMSLIB) -lz -lm -lc
+ $(CC) -shared -Wl,-soname,libmng.so.$(MNGMAJ) -o libmng.so.$(MNGVER) \
+- $(OBJSDLL) -L$(ZLIBLIB) -L$(JPEGLIB) -ljpeg -L$(LCMSLIB) -llcms \
++ $(OBJSDLL) -L$(ZLIBLIB) -L$(JPEGLIB) -ljpeg -L$(LCMSLIB) -llcms2 \
+     -lz -lm -lc
+
+ install: libmng.a libmng.so.$(MNGVER)
+--- a/libmng_types.h
++++ b/libmng_types.h
+@@ -133,6 +133,9 @@
+
+ /* ************************************************************************** */
+
++#undef HAVE_LIBLCMS1
++#define HAVE_LIBLCMS2
++
+ #ifdef __BORLANDC__
+ #pragma option -AT                     /* turn off strict ANSI-C for the moment */
+ #endif
+@@ -151,12 +154,13 @@
+ /* *  together)                                                             * */
+ /* *                                                                        * */
+ /* ************************************************************************** */
+-
++#ifdef HIDDEN_FOR_NOW
+ #ifdef WIN32                           /* only include needed stuff */
+ #ifndef WIN32_LEAN_AND_MEAN
+ #define WIN32_LEAN_AND_MEAN
+ #endif
+ #endif
++#endif /* HIDDEN_FOR_NOW */
+
+ #ifdef MNG_USE_DLL
+ #ifdef MNG_SKIP_ZLIB
+@@ -178,27 +182,32 @@
+ #ifndef ZLIB_DLL
+ #undef FAR
+ #endif
+-#if defined(WIN32) || defined(linux) || defined(__GNU__) || defined(__FreeBSD_kernel__)   /* different header locations */
+-#include "lcms.h"
+-#else
+-#include "lcms/lcms.h"
++#ifdef HAVE_LIBLCMS1
++#include <lcms.h>
++#elif defined(HAVE_LIBLCMS2)
++#include <lcms2.h>
+ #endif
+ #endif /* MNG_INCLUDE_LCMS */
+
+ #ifdef MNG_INCLUDE_IJG6B               /* IJG's jpgsrc6b */
+-#include <stdio.h>
++#define JPEG_INTERNAL_OPTIONS          /* for RGB_PIXELSIZE */
+ #ifdef MNG_USE_SETJMP
+ #include <setjmp.h>                    /* needed for error-recovery (blergh) */
+ #else
+ #ifdef WIN32
+-#define USE_WINDOWS_MESSAGEBOX         /* display a messagebox under Windoze */
++/* #define USE_WINDOWS_MESSAGEBOX */        /* display a messagebox under Windoze */
+ #endif
+ #endif /* MNG_USE_SETJMP */
+ #ifdef FAR
+ #undef FAR                             /* possibly defined by zlib or lcms */
+ #endif
+ #define JPEG_INTERNAL_OPTIONS          /* for RGB_PIXELSIZE */
+-#include <jpeglib.h>                   /* all that for JPEG support  :-) */
++/* There has been a change in jpeg-9 : */
++#ifndef _WIN32
++#define HAVE_BOOLEAN
++typedef int boolean;
++#endif
++#include <jpeglib.h>
+ #endif /* MNG_INCLUDE_IJG6B */
+
+ #if defined(MNG_INTERNAL_MEMMNGMT) || defined(MNG_INCLUDE_FILTERS)
+@@ -392,7 +401,12 @@
+ typedef cmsHTRANSFORM       mng_cmstrans;
+ typedef cmsCIExyY           mng_CIExyY;
+ typedef cmsCIExyYTRIPLE     mng_CIExyYTRIPLE;
++
++#ifdef HAVE_LIBLCMS1
+ typedef LPGAMMATABLE        mng_gammatabp;
++#elif defined(HAVE_LIBLCMS2)
++typedef cmsToneCurve*       mng_gammatabp;
++#endif
+ #endif /* MNG_INCLUDE_LCMS */
+
+ /* ************************************************************************** */
diff -Nru libmng-1.0.10/debian/README.source libmng-1.0.10+dfsg/debian/README.source
--- libmng-1.0.10/debian/README.source 1970-01-01 01:00:00.000000000 +0100
+++ libmng-1.0.10+dfsg/debian/README.source 2014-08-03 13:21:29.000000000 +0200
@@ -0,0 +1,10 @@
+libmng for Debian
+-----------------
+
+Upstream includes one non-free file: /contrib/msvc/mngview/sRGB.icm
+Therefore the source is repacked to be DFSG free.
+
+As since devscripts' uscan (>2.13.5) can remove files automatically there is
+no get-orig-source target in d/rules needed.
+
+ -- Tobias Frost <[hidden email]>  Sun, 03 Aug 2014 10:18:53 +0000
diff -Nru libmng-1.0.10/debian/watch libmng-1.0.10+dfsg/debian/watch
--- libmng-1.0.10/debian/watch 2010-06-02 13:01:51.000000000 +0200
+++ libmng-1.0.10+dfsg/debian/watch 2014-08-03 13:14:10.000000000 +0200
@@ -1,2 +1,3 @@
 version=3
+opts=dversionmangle=s/\+(debian|dfsg|ds|deb)(\.\d+)?$//,uversionmangle=s/$/+dfsg/ \
 http://sf.net/libmng/libmng-(.+)\.tar\.gz


--
To UNSUBSCRIBE, email to [hidden email]
with a subject of "unsubscribe". Trouble? Contact [hidden email]

Reply | Threaded
Open this post in threaded view
|

Processed: libmng: diff for NMU version 1.0.10+dfsg-3.1

Debian Bug Tracking System
Processing commands for [hidden email]:

> tags 699304 + patch
Bug #699304 [src:libmng] libmng: sRGB.icm is non-free
Bug #736954 [src:libmng] [src:libmng] Non free file according to dfsg
Added tag(s) patch.
Added tag(s) patch.
> tags 699304 + pending
Bug #699304 [src:libmng] libmng: sRGB.icm is non-free
Bug #736954 [src:libmng] [src:libmng] Non free file according to dfsg
Added tag(s) pending.
Added tag(s) pending.
> tags 745525 + patch
Bug #745525 [libmng] Please migrate to lcms2
Added tag(s) patch.
> tags 745525 + pending
Bug #745525 [libmng] Please migrate to lcms2
Added tag(s) pending.
> thanks
Stopping processing here.

Please contact me if you need assistance.
--
699304: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=699304
736954: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=736954
745525: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=745525
Debian Bug Tracking System
Contact [hidden email] with problems


--
To UNSUBSCRIBE, email to [hidden email]
with a subject of "unsubscribe". Trouble? Contact [hidden email]