[packages/dmtx-utils] - fix building with ImageMagick 7 - fix counfigure.ac regen - rel 2
baggins
baggins at pld-linux.org
Sun Dec 25 17:58:20 CET 2016
commit 46d60da9fcf3d50aaea527df2ada1fc1079d96d1
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Sun Dec 25 17:57:16 2016 +0100
- fix building with ImageMagick 7
- fix counfigure.ac regen
- rel 2
ac.patch | 10 ++++++++++
dmtx-utils.spec | 14 +++++++++++++-
imagemagick7.patch | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 71 insertions(+), 1 deletion(-)
---
diff --git a/dmtx-utils.spec b/dmtx-utils.spec
index 2199092..94c2d19 100644
--- a/dmtx-utils.spec
+++ b/dmtx-utils.spec
@@ -1,12 +1,17 @@
Summary: Utilities for libdmtx
Name: dmtx-utils
Version: 0.7.4
-Release: 1
+Release: 2
License: LGPL v2+
Group: Applications/System
Source0: http://downloads.sourceforge.net/libdmtx/%{name}-%{version}.tar.bz2
# Source0-md5: b132ab9fb1d289869469b8bb4959a08a
+Patch0: ac.patch
+Patch1: imagemagick7.patch
URL: http://www.libdmtx.org/
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: libtool
BuildRequires: libdmtx-devel
BuildRequires: pkgconfig
BuildRequires: rpmbuild(macros) >= 1.219
@@ -18,8 +23,15 @@ This package contains utilities that use libdmtx.
%prep
%setup -q
+%patch0 -p1
+%patch1 -p1
%build
+%{__libtoolize}
+%{__aclocal}
+%{__autoconf}
+%{__autoheader}
+%{__automake}
%configure
%{__make}
diff --git a/ac.patch b/ac.patch
new file mode 100644
index 0000000..32caf9b
--- /dev/null
+++ b/ac.patch
@@ -0,0 +1,10 @@
+--- dmtx-utils-0.7.4/configure.ac~ 2016-12-25 17:41:49.000000000 +0100
++++ dmtx-utils-0.7.4/configure.ac 2016-12-25 17:43:52.006935201 +0100
+@@ -20,7 +20,6 @@
+
+ AC_CHECK_HEADERS([sysexits.h])
+ AC_CHECK_HEADERS([getopt.h])
+-AC_CHECK_FUNC([getopt_long], [], [ AC_LIBOBJ([getopt]) AC_LIBOBJ([getopt1]) ])
+
+ AC_ARG_ENABLE(
+ [dmtxquery],
diff --git a/imagemagick7.patch b/imagemagick7.patch
new file mode 100644
index 0000000..3cf991c
--- /dev/null
+++ b/imagemagick7.patch
@@ -0,0 +1,48 @@
+diff -ur dmtx-utils-0.7.4/configure.ac dmtx-utils-0.7.4-im7/configure.ac
+--- dmtx-utils-0.7.4/configure.ac 2016-12-25 17:54:31.633992016 +0100
++++ dmtx-utils-0.7.4-im7/configure.ac 2016-12-25 17:43:52.006935201 +0100
+@@ -59,7 +59,7 @@
+ fi
+
+ if test x$dmtxread = xyes -o x$dmtxwrite = xyes; then
+- PKG_CHECK_MODULES(MAGICK, Wand >= 6.2.4, [], AC_MSG_ERROR([dmtxread/dmtxwrite requires Wand >= 6.2.4]))
++ PKG_CHECK_MODULES(MAGICK, MagickWand >= 6.2.4, [], AC_MSG_ERROR([dmtxread/dmtxwrite requires Wand >= 6.2.4]))
+ AC_SUBST(MAGICK_CFLAGS)
+ AC_SUBST(MAGICK_LIBS)
+ fi
+diff -ur dmtx-utils-0.7.4/dmtxread/dmtxread.c dmtx-utils-0.7.4-im7/dmtxread/dmtxread.c
+--- dmtx-utils-0.7.4/dmtxread/dmtxread.c 2011-06-03 07:13:10.000000000 +0200
++++ dmtx-utils-0.7.4-im7/dmtxread/dmtxread.c 2016-12-25 17:52:06.070673612 +0100
+@@ -114,7 +114,7 @@
+ }
+
+ /* Copy pixels to known format */
+- success = MagickGetImagePixels(wand, 0, 0, width, height, "RGB", CharPixel, pxl);
++ success = MagickImportImagePixels(wand, 0, 0, width, height, "RGB", CharPixel, pxl);
+ if(success == MagickFalse || pxl == NULL) {
+ CleanupMagick(&wand, DmtxTrue);
+ FatalError(EX_OSERR, "malloc() error");
+diff -ur dmtx-utils-0.7.4/dmtxread/dmtxread.h dmtx-utils-0.7.4-im7/dmtxread/dmtxread.h
+--- dmtx-utils-0.7.4/dmtxread/dmtxread.h 2011-06-03 07:13:10.000000000 +0200
++++ dmtx-utils-0.7.4-im7/dmtxread/dmtxread.h 2016-12-25 17:53:16.762275566 +0100
+@@ -33,7 +33,7 @@
+ #include <math.h>
+ #include <stdarg.h>
+ #include <assert.h>
+-#include <wand/magick-wand.h>
++#include <MagickWand/MagickWand.h>
+ #include <dmtx.h>
+ #include "../common/dmtxutil.h"
+
+diff -ur dmtx-utils-0.7.4/dmtxwrite/dmtxwrite.h dmtx-utils-0.7.4-im7/dmtxwrite/dmtxwrite.h
+--- dmtx-utils-0.7.4/dmtxwrite/dmtxwrite.h 2011-06-03 07:13:10.000000000 +0200
++++ dmtx-utils-0.7.4-im7/dmtxwrite/dmtxwrite.h 2016-12-25 17:53:07.285393032 +0100
+@@ -34,7 +34,7 @@
+ #include <sys/stat.h>
+ #include <fcntl.h>
+ #include <assert.h>
+-#include <wand/magick-wand.h>
++#include <MagickWand/MagickWand.h>
+ #include <dmtx.h>
+ #include "../common/dmtxutil.h"
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/dmtx-utils.git/commitdiff/46d60da9fcf3d50aaea527df2ada1fc1079d96d1
More information about the pld-cvs-commit
mailing list