summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/1.patch0
-rw-r--r--debian/changelog8
-rw-r--r--debian/control4
-rw-r--r--debian/patches/0045-disable_lock_test_at_build_time.patch21
-rw-r--r--debian/patches/0050-Use-python3-shebang.patch10
-rw-r--r--debian/patches/0055-Fix_build_error.patch30
-rw-r--r--debian/patches/0XXX-test.patch193
-rw-r--r--debian/patches/series4
-rwxr-xr-xdebian/rules2
9 files changed, 270 insertions, 2 deletions
diff --git a/debian/1.patch b/debian/1.patch
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/debian/1.patch
diff --git a/debian/changelog b/debian/changelog
index de3e42c..a4edef9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,14 @@ sane-backends (1.0.31-1~experimental1) UNRELEASED; urgency=medium
Thanks to Gianfranco Costamagna <locutusofborg@debian.org>.
* debian/copyright: Fix lintian *-globbing-patterns errors.
* Convert debian/po/de.po to utf-8.
+ * New patches:
+ - debian/patches/0045-disable_lock_test_at_build_time.patch
+ - debian/patches/0050-Use-python3-shebang.patch
+ - debian/patches/0055-Fix_build_error.patch
+ * debian/rules:
+ - Use --enable-locking instead --disable-locking.
+ * debian/control:
+ - Add libpoppler-glib-dev to Build-Depends.
-- Jörg Frings-Fürst <debian@jff.email> Mon, 01 Jun 2020 13:14:34 +0200
diff --git a/debian/control b/debian/control
index 57fa24c..7b4fb99 100644
--- a/debian/control
+++ b/debian/control
@@ -17,6 +17,7 @@ Build-Depends:
libieee1284-3-dev [!hurd-i386],
libjpeg-dev,
libltdl3-dev,
+ libpoppler-glib-dev,
libsnmp-dev [!kfreebsd-any],
libsystemd-dev [linux-any],
libtiff-dev,
@@ -24,7 +25,8 @@ Build-Depends:
libxml2-dev,
pkg-config,
po-debconf,
- xutils-dev
+ xutils-dev,
+ python3-minimal
Homepage: http://www.sane-project.org
Vcs-Git: git://jff.email/opt/git/sane-backends.git
Vcs-Browser: https://jff.email/cgit/sane-backends.git
diff --git a/debian/patches/0045-disable_lock_test_at_build_time.patch b/debian/patches/0045-disable_lock_test_at_build_time.patch
new file mode 100644
index 0000000..442798b
--- /dev/null
+++ b/debian/patches/0045-disable_lock_test_at_build_time.patch
@@ -0,0 +1,21 @@
+Index: trunk/acinclude.m4
+===================================================================
+--- trunk.orig/acinclude.m4
++++ trunk/acinclude.m4
+@@ -359,11 +359,11 @@ AC_DEFUN([SANE_CHECK_LOCKING],
+ touch sanetest.file
+ chgrp $LOCKPATH_GROUP sanetest.file 2>/dev/null || lasterror=$?
+ rm -f sanetest.file
+- if test ! -z "$lasterror"; then
+- AC_MSG_WARN([Group $LOCKPATH_GROUP does not exist on this system.])
+- AC_MSG_WARN([Locking feature will be disabled.])
+- use_locking=no
+- fi
++# if test ! -z "$lasterror"; then
++# AC_MSG_WARN([Group $LOCKPATH_GROUP does not exist on this system.])
++# AC_MSG_WARN([Locking feature will be disabled.])
++# use_locking=no
++# fi
+ fi
+ if test $use_locking = yes ; then
+ INSTALL_LOCKPATH=install-lockpath
diff --git a/debian/patches/0050-Use-python3-shebang.patch b/debian/patches/0050-Use-python3-shebang.patch
new file mode 100644
index 0000000..a50e412
--- /dev/null
+++ b/debian/patches/0050-Use-python3-shebang.patch
@@ -0,0 +1,10 @@
+Index: trunk/backend/pixma/scripts/pixma_gen_options.py
+===================================================================
+--- trunk.orig/backend/pixma/scripts/pixma_gen_options.py
++++ trunk/backend/pixma/scripts/pixma_gen_options.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++#!/usr/bin/env python3
+
+ from __future__ import print_function
+ import sys,os,re
diff --git a/debian/patches/0055-Fix_build_error.patch b/debian/patches/0055-Fix_build_error.patch
new file mode 100644
index 0000000..e947300
--- /dev/null
+++ b/debian/patches/0055-Fix_build_error.patch
@@ -0,0 +1,30 @@
+Index: trunk/po/POTFILES.in
+===================================================================
+--- trunk.orig/po/POTFILES.in
++++ trunk/po/POTFILES.in
+@@ -65,7 +65,7 @@ backend/p5.c
+ backend/p5.h
+ backend/p5_device.c
+ backend/pixma/pixma.c
+-backend/pixma/pixma_sane_options.c
++#backend/pixma/pixma_sane_options.c
+ backend/plustek.c
+ backend/plustek_pp.c
+ backend/pnm.c
+Index: trunk/backend/Makefile.am
+===================================================================
+--- trunk.orig/backend/Makefile.am
++++ trunk/backend/Makefile.am
+@@ -947,10 +947,10 @@ $(srcdir)/pixma/pixma.c: \
+
+ $(srcdir)/pixma/pixma_sane_options.h:
+ @echo Generating $@ from $(@D)/pixma.c
+- @(cd $(@D); python scripts/pixma_gen_options.py h < pixma.c > $(@F))
++ @(cd $(@D); python3 scripts/pixma_gen_options.py h < pixma.c > $(@F))
+ $(srcdir)/pixma/pixma_sane_options.c:
+ @echo Generating $@ from $(@D)/pixma.c
+- @(cd $(@D); python scripts/pixma_gen_options.py < pixma.c > $(@F))
++ @(cd $(@D); python3 scripts/pixma_gen_options.py < pixma.c > $(@F))
+
+ EXTRA_DIST += pixma/pixma_sane_options.c
+ EXTRA_DIST += pixma/pixma_sane_options.h
diff --git a/debian/patches/0XXX-test.patch b/debian/patches/0XXX-test.patch
new file mode 100644
index 0000000..940caba
--- /dev/null
+++ b/debian/patches/0XXX-test.patch
@@ -0,0 +1,193 @@
+Index: trunk/acinclude.m4
+===================================================================
+--- trunk.orig/acinclude.m4
++++ trunk/acinclude.m4
+@@ -613,7 +613,7 @@ for be in ${BACKENDS}; do
+ ;;
+
+ escl)
+- if test "x${with_avahi}" != "xyes"; then
++ if test "x${enable_avahi}" != "xyes"; then
+ echo "*** $be backend requires AVAHI library - $DISABLE_MSG"
+ backend_supported="no"
+ fi
+@@ -629,14 +629,7 @@ for be in ${BACKENDS}; do
+ if test "x${sane_cv_use_libjpeg}" != "xyes"; then
+ echo "*** $be backend currently requires JPEG library - $DISABLE_MSG"
+ backend_supported="no"
+- else
+- if test "x${ac_cv_func_jpeg_crop_scanline}" != "xyes" \
+- || test "x${ac_cv_func_jpeg_skip_scanlines}" != "xyes"; then
+- echo "*** $be backend requires a newer JPEG library - $DISABLE_MSG"
+- backend_supported="no"
+- fi
+ fi
+-
+ ;;
+
+ gphoto2)
+Index: trunk/configure.ac
+===================================================================
+--- trunk.orig/configure.ac
++++ trunk/configure.ac
+@@ -129,26 +129,17 @@ AC_ARG_WITH(v4l,
+ # as "$with_v4l" will be set to "no"])
+
+ if test "$with_v4l" != "no" ; then
+- PKG_CHECK_MODULES(LIBV4L, [libv4l1 >= 0.8.3], have_libv4l1=yes, have_libv4l1=no)
++ PKG_CHECK_MODULES(LIBV4L, libv4l1, have_libv4l1=yes, have_libv4l1=no)
+ fi
+
+-AC_ARG_WITH(avahi,
+- AS_HELP_STRING([--with-avahi],
+- [enable Avahi support @<:@default=check@:>@]),
+- [],
+- [with_avahi=check])
+-AC_DEFINE(WITH_AVAHI,
+- [0], [Define to 1 if Avahi support is available])
+-AS_IF([test xno != "x$with_avahi"],
+- [PKG_CHECK_MODULES(AVAHI, [avahi-client >= 0.6.24],
+- [AC_DEFINE([WITH_AVAHI], [1])
+- with_avahi=yes
+- ],
+- [AS_IF([test xcheck != "x$with_avahi"],
+- [AC_MSG_ERROR([Avahi support requested but not found])])
+- with_avahi=no
+- ])
+- ])
++AC_ARG_ENABLE(avahi,
++ AS_HELP_STRING([--enable-avahi], [enable Avahi support for saned and the net backend]),
++ [enable_avahi=$enableval], [enable_avahi=no])
++
++if test "$enable_avahi" = "yes"; then
++ PKG_CHECK_MODULES(AVAHI, [ avahi-client >= 0.6.24 ],
++ [AC_DEFINE(WITH_AVAHI, 1, [define if Avahi support is enabled for saned and the net backend])], enable_avahi=no)
++fi
+ AM_CONDITIONAL([have_libavahi], [test x != "x$AVAHI_LIBS"])
+
+ dnl check sane to make sure we don't have two installations
+@@ -463,28 +454,6 @@ AS_IF([test xno != "x$with_libcurl"],
+ AM_CONDITIONAL([have_libcurl], [test x != "x$libcurl_LIBS"])
+
+ dnl ******************************************************************
+-dnl Check for poppler-glib availability
+-dnl ******************************************************************
+-AC_ARG_WITH(poppler-glib,
+- AS_HELP_STRING([--with-poppler-glib],
+- [enable functionality that needs poppler-glib @<:@default=check@:>@]),
+- [],
+- [with_poppler_glib=check])
+-AC_DEFINE(HAVE_POPPLER_GLIB,
+- [0], [Define to 1 if libpoppler-glib is available])
+-AS_IF([test xno != "x$with_poppler_glib"],
+- [PKG_CHECK_MODULES(POPPLER_GLIB, [poppler-glib],
+- [AC_DEFINE([HAVE_POPPLER_GLIB], [1])
+- with_poppler_glib=yes
+- ],
+- [AS_IF([test xcheck != "x$with_poppler_glib"],
+- [AC_MSG_ERROR([poppler-glib requested but not found])])
+- with_poppler_glib=no
+- ])
+- ])
+-AM_CONDITIONAL([have_poppler_glib], [test x != "x$POPPLER_GLIB_LIBS"])
+-
+-dnl ******************************************************************
+ dnl Check for USB record/replay support
+ dnl ******************************************************************
+ AC_ARG_WITH(usb_record_replay,
+@@ -665,7 +634,7 @@ AC_ARG_ENABLE(local-backends,
+ [turn off compilation of all backends but net]))
+
+ ALL_BACKENDS="abaton agfafocus apple artec artec_eplus48u as6e \
+- avision bh canon canon630u canon_dr canon_lide70 canon_pp cardscan \
++ avision bh canon canon630u canon_dr canon_pp cardscan \
+ coolscan coolscan2 coolscan3 dc25 dc210 dc240 \
+ dell1600n_net dmc epjitsu epson epson2 epsonds escl fujitsu \
+ genesys gphoto2 gt68xx hp hp3500 hp3900 hp4200 hp5400 \
+@@ -695,18 +664,14 @@ else
+ fi
+ fi
+
++SANE_CHECK_BACKENDS
++
+ if test "${sane_cv_use_libjpeg}" = "yes"; then
+ SANEI_SANEI_JPEG_LO="../sanei/sanei_jpeg.lo"
+- saved_LIBS="${LIBS}"
+- LIBS="${JPEG_LIBS}"
+- AC_CHECK_FUNCS(jpeg_crop_scanline jpeg_skip_scanlines)
+- LIBS="${saved_LIBS}"
+ fi
+ AM_CONDITIONAL(HAVE_JPEG, test x$sane_cv_use_libjpeg = xyes)
+ AC_SUBST(SANEI_SANEI_JPEG_LO)
+
+-SANE_CHECK_BACKENDS
+-
+ AC_ARG_ENABLE(pnm-backend,
+ AS_HELP_STRING([--enable-pnm-backend],
+ [enable the pnm backend for testing frontends (possible security risk, see PROBLEMS file)]),
+@@ -804,6 +769,54 @@ AC_ARG_ENABLE(parport-directio,
+ fi
+ ])
+
++dnl ******************************************************************
++dnl SANE API specification format conversion support
++dnl ******************************************************************
++AC_ARG_WITH(api-spec,
++ AS_HELP_STRING([--with-api-spec],
++ [convert API spec to supported output formats @<:@default=check@:>@]),
++ [],
++ [with_api_spec=check])
++dnl Test for all tools that may be involved. These tests are fast and
++dnl running them allows for the Makefile targets to be formulated such
++dnl that any non-requested formats can be made using a one-off without
++dnl the need to reconfigure.
++AC_PATH_PROG(MAKEINDEX, makeindex, no)
++AC_PATH_PROG(DVIPS, dvips, no)
++AC_PATH_PROG(LATEX, latex, no)
++AC_PATH_PROG(PDFLATEX, pdflatex, no)
++AC_PATH_PROG(FIG2DEV, fig2dev, no)
++AC_PATH_PROG(GS, gs, no)
++AC_PATH_PROG(DLH, dlh, no)
++AC_PATH_PROG(PPMTOGIF, ppmtogif, no)
++AS_IF([test xno != "x$with_api_spec"],
++ [dnl Flag formats for which all required tools have been found
++ AS_IF([ test xno != "x$MAKEINDEX" \
++ && test xno != "x$DVIPS" \
++ && test xno != "x$FIG2DEV" \
++ && test xno != "x$LATEX"], [with_api_ps=yes])
++ AS_IF([ test xno != "x$MAKEINDEX" \
++ && test xno != "x$PDFLATEX" \
++ && test xno != "x$FIG2DEV" \
++ && test xno != "x$GS"], [with_api_pdf=yes])
++ AS_IF([ test xno != "x$MAKEINDEX" \
++ && test xno != "x$DVIPS" \
++ && test xno != "x$FIG2DEV" \
++ && test xno != "x$DLH" \
++ && test xno != "x$GS" \
++ && test xno != "x$PPMTOFIG" ], [with_api_html=yes])
++
++ AS_IF([test xyes = "x$with_api_spec" \
++ && test xyes != "x$with_api_ps" \
++ && test xyes != "x$with_api_pdf" \
++ && test xyes != "x$with_api_html"],
++ [AC_MSG_ERROR([tools to convert the API spec are missing])
++ ])
++ ])
++AM_CONDITIONAL(WITH_API_PS, [test x$with_api_ps = xyes])
++AM_CONDITIONAL(WITH_API_PDF, [test x$with_api_pdf = xyes])
++AM_CONDITIONAL(WITH_API_HTML, [test x$with_api_html = xyes])
++
+ dnl ***********************************************************************
+ dnl Write output files
+ dnl ***********************************************************************
+@@ -852,9 +865,8 @@ else
+ echo "Build saned: no"
+ fi
+ echo "IPv6 support: `eval eval echo ${ipv6}`"
+-echo "Avahi support: `eval eval echo ${with_avahi}`"
++echo "Avahi support: `eval eval echo ${enable_avahi}`"
+ echo "cURL support: `eval eval echo ${with_libcurl}`"
+-echo "POPPLER_GLIB support: `eval eval echo ${with_poppler_glib}`"
+ echo "SNMP support: `eval eval echo ${with_snmp}`"
+ echo "-> The following backends will be built:"
+ for backend in ${BACKENDS} ; do
diff --git a/debian/patches/series b/debian/patches/series
index a3a660d..bc2a892 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
+#0XXX-test.patch
0035-trim-libraries-in-sane-backends.pc.in.patch
0040-remove_git.patch
0100-source_spelling.patch
@@ -12,3 +13,6 @@
0150-i386-test.patch
0155-hurd_PATH_MAX.patch
#0160-big_endian.patch
+0045-disable_lock_test_at_build_time.patch
+0050-Use-python3-shebang.patch
+0055-Fix_build_error.patch
diff --git a/debian/rules b/debian/rules
index eac8ba3..125838a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -34,7 +34,7 @@ override_dh_auto_configure:
--datadir=\$${prefix}/share \
--mandir=\$${prefix}/share/man \
--docdir=\$${prefix}/share/doc/libsane \
- --disable-locking \
+ --enable-locking \
--enable-static \
--enable-pthread \
--with-gphoto2 \