Making it possible to build the pnm test backend. Disabled by default because of...
authorPatrick Kursawe <phosphan@gentoo.org>
Thu, 10 Nov 2011 21:27:20 +0000 (21:27 +0000)
committerPatrick Kursawe <phosphan@gentoo.org>
Thu, 10 Nov 2011 21:27:20 +0000 (21:27 +0000)
Package-Manager: portage-2.1.10.11/cvs/Linux i686

media-gfx/sane-backends/ChangeLog
media-gfx/sane-backends/Manifest
media-gfx/sane-backends/sane-backends-1.0.22-r2.ebuild [new file with mode: 0644]

index 71c7b1b4583f51d8dcff577cbf3458fd784f627e..9949baef7fb6e1f6383ac60b46a5513f7b5767b0 100644 (file)
@@ -1,6 +1,13 @@
 # ChangeLog for media-gfx/sane-backends
 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/sane-backends/ChangeLog,v 1.195 2011/10/23 15:18:39 armin76 Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/sane-backends/ChangeLog,v 1.196 2011/11/10 21:27:20 phosphan Exp $
+
+*sane-backends-1.0.22-r2 (10 Nov 2011)
+
+  10 Nov 2011; Patrick Kursawe <phosphan@gentoo.org>
+  +sane-backends-1.0.22-r2.ebuild:
+  Making it possible to build the pnm test backend. Disabled by default because
+  of security concerns, see bug #389911.
 
   23 Oct 2011; Raúl Porcel <armin76@gentoo.org>
   sane-backends-1.0.22-r1.ebuild:
index 08cacb7cd4d0e1db7a96253e6e3c4f964f54059e..ec41fd09b4cd8da5511b338b25ac21f9dc904466 100644 (file)
@@ -1,6 +1,3 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
 AUX 1.0.20-unbreak-udev.diff 688 RMD160 467154092c84c81c6444b788fa9a10d909930a84 SHA1 63d5f52ae04e17a9d1722d55f6e1b6f8ca5094a4 SHA256 467a170a9f4c5d825893029607dcdcb45110c3f2838e9ee230fdbbc1f8f0567e
 AUX broken_coolscan.patch 442 RMD160 9935934fe6963b7da31b544c7f3baa9065c39bab SHA1 2f1bda3b6bb54cae882005eb709cda33cfd17af8 SHA256 87b327a370f4f7e2884a9715dc880362f313611badf978ba1a1dd23f46284c98
 AUX epson2fixes-1.0.19.patch 922 RMD160 bdfa3ffb1bbdf78000531093663c134e7b63958e SHA1 daa5e62c01370c788a25448472fc9d5b55abaf9f SHA256 630aa0ed61c8d426f2b06c557a148caaf2ca07d659e97425fd121c5f896dc203
@@ -30,12 +27,10 @@ EBUILD sane-backends-1.0.19-r2.ebuild 4529 RMD160 eefe04dde29997ea05d0a01c2d37c4
 EBUILD sane-backends-1.0.20-r3.ebuild 4462 RMD160 5be64742bac6fe9f3187ac2147034a03fa470c6a SHA1 92640bea67d69c4ccc1abbc1671e4d1851998020 SHA256 83595e9ac052f4f32b2130f457dd47077f742de603a618bcc6de44f7325dceac
 EBUILD sane-backends-1.0.21-r1.ebuild 4748 RMD160 300d19dc149bacb0a5f797596547c3870859bfa2 SHA1 242cfadaa6c4e87b35e1646fc131fc3e76d206d9 SHA256 59c7a673da2bd800037a734c847febb5a8af3a6abdb1d46f9b5c4d3b09023aa7
 EBUILD sane-backends-1.0.22-r1.ebuild 4708 RMD160 70ed09e05fbb1ddb1bd03e2faf0fb6dd1ee4fa11 SHA1 f9ae30ac92e9ce72bee2b1d9b3ff3f472b3ff7b9 SHA256 6b6ab20823421276384031b413c0957d2abc18fba4088a5002b794a5cf33c892
-MISC ChangeLog 33760 RMD160 8e1c8d0f40acdd9da8f6c84f0298b1321ec032ad SHA1 238aeaddbffd1dc58f6cf6252a9745ca9b67e586 SHA256 64879075bb36d75847220c6a0245de9d464cce3d8bd5d0e2e90585f9a3f01ee7
+EBUILD sane-backends-1.0.22-r2.ebuild 4956 RMD160 e0e42a455ed7b64404b47ed6f4d8963346d9a9c9 SHA1 a56f2789e7339bbf74d0376ed77b85ed1d628c61 SHA256 d04213ae27dc80561362e1abd2a024237ad8548e9dbe2e23da7c8131df737944
+MISC ChangeLog 34011 RMD160 046d25411b5645c0e618f587e71cf105c4464df2 SHA1 dbce260167bf785e489db8702c21b901fc8dfb69 SHA256 02db9daea5f70f0c362e9d8c715108fa7dd76e90a01b5c624dd05481f70b14c0
 MISC metadata.xml 203 RMD160 300bee51281e761b0c22b6b7994210d0e02af2eb SHA1 becd8a4405785b35675e2e84ec4ef696f0278802 SHA256 fa46f560cb484f9b761d3b5c3f3fd3368d4d68c241fa2697225f139fe6e03476
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.17 (GNU/Linux)
-
-iEYEARECAAYFAk6kMFUACgkQuQc30/atMkA8VwCeMDVfB19MBcpW33NIs0QimrZi
-8TAAn23OxYRD/nkGaab/WDx8dGbdaRaV
-=Kgmz
------END PGP SIGNATURE-----
+MISC sane-backends-1.0.21-r1.ebuild.orig 4641 RMD160 fe0fa0fbeb1d2836379af62bea985461fb85302b SHA1 ac489d62b2e61b9d986bf33c359d18dbd6d443df SHA256 864f82c84673185907982c8192ecc8a6f253a9917dd0a8a768a4ebc901631ddf
+MISC sane-backends-1.0.21-r1.ebuild.rej 383 RMD160 ab238c107d34c87d9f2fd21e6b68117650d2fc08 SHA1 57ff56131cb4b464ca14a8c7d001e06376a249c4 SHA256 0ff45e0af845e8a245b5b36c559b507a1ae752098a8587d0dcde184f3c59194f
+MISC sane-backends-1.0.22-r2.ebuild.orig 4791 RMD160 fd8ce82595fa221f93cec67c5ce617f0a55e3645 SHA1 6c17f13a8bdb1cd7c11d1898977be96c944e5a4a SHA256 7ec2dd0e8644a41033ef43b5510f5b1480dd334c144a819a04f62ff05e32e166
+MISC sane-backends-1.0.22-r2.ebuild.rej 244 RMD160 59722b6f5d5874acd704d3d9d883c76fea14dc7c SHA1 cdfba30fa25d94c44b5c95ef712c7b33573a0679 SHA256 9b18e5cd8d25d34c94887c9c8776d95c06cbfff3ff2248f7341a472d7613b6d7
diff --git a/media-gfx/sane-backends/sane-backends-1.0.22-r2.ebuild b/media-gfx/sane-backends/sane-backends-1.0.22-r2.ebuild
new file mode 100644 (file)
index 0000000..be6d332
--- /dev/null
@@ -0,0 +1,231 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/sane-backends/sane-backends-1.0.22-r2.ebuild,v 1.1 2011/11/10 21:27:20 phosphan Exp $
+
+EAPI="4"
+
+inherit eutils flag-o-matic multilib
+
+# gphoto and v4l are handled by their usual USE flags.
+# The pint backend was disabled because I could not get it to compile.
+# The mustek_usb2 backend would force us to use --enable-pthreads which is off
+# by default for linux. Let's keep this one out until we find a way how to
+# handle this cleanly.
+IUSE_SANE_BACKENDS="
+       abaton
+       agfafocus
+       apple
+       artec
+       artec_eplus48u
+       as6e
+       avision
+       bh
+       canon
+       canon630u
+       canon_dr
+       canon_pp
+       cardscan
+       coolscan
+       coolscan2
+       coolscan3
+       dc25
+       dc210
+       dc240
+       dell1600n_net
+       dmc
+       epjitsu
+       epson
+       epson2
+       fujitsu
+       genesys
+       gt68xx
+       hp
+       hp3500
+       hp3900
+       hp4200
+       hp5400
+       hp5590
+       hpsj5s
+       hpljm1005
+       hs2p
+       ibm
+       kodak
+       kvs1025
+       kvs20xx
+       leo
+       lexmark
+       ma1509
+       magicolor
+       matsushita
+       microtek
+       microtek2
+       mustek
+       mustek_pp
+       mustek_usb
+       nec
+       net
+       niash
+       p5
+       pie
+       pixma
+       plustek
+       plustek_pp
+       pnm
+       qcam
+       ricoh
+       rts8891
+       s9036
+       sceptre
+       sharp
+       sm3600
+       sm3840
+       snapscan
+       sp15c
+       st400
+       stv680
+       tamarack
+       teco1
+       teco2
+       teco3
+       test
+       u12
+       umax
+       umax_pp
+       umax1220u
+       xerox_mfp"
+
+IUSE="avahi usb gphoto2 ipv6 v4l doc"
+
+for backend in ${IUSE_SANE_BACKENDS}; do
+       if [ ${backend} = pnm ]; then
+               IUSE="${IUSE} -sane_backends_pnm"
+       else
+               IUSE="${IUSE} +sane_backends_${backend}"
+       fi
+done
+
+DESCRIPTION="Scanner Access Now Easy - Backends"
+HOMEPAGE="http://www.sane-project.org/"
+
+RDEPEND="
+       sane_backends_dc210? ( virtual/jpeg )
+       sane_backends_dc240? ( virtual/jpeg )
+       sane_backends_dell1600n_net? ( virtual/jpeg )
+       avahi? ( >=net-dns/avahi-0.6.24 )
+       sane_backends_canon_pp? ( sys-libs/libieee1284 )
+       sane_backends_hpsj5s? ( sys-libs/libieee1284 )
+       sane_backends_mustek_pp? ( sys-libs/libieee1284 )
+       usb? ( virtual/libusb:0 )
+       gphoto2? (
+               media-libs/libgphoto2
+               virtual/jpeg
+       )
+       v4l? ( media-libs/libv4l )"
+
+DEPEND="${RDEPEND}
+       v4l? ( sys-kernel/linux-headers )
+       doc? (
+               virtual/latex-base
+               dev-texlive/texlive-latexextra
+       )
+       >=sys-apps/sed-4"
+
+# We now use new syntax construct (SUBSYSTEMS!="usb|usb_device)
+RDEPEND="${RDEPEND}
+       !<sys-fs/udev-114"
+
+SRC_URI="ftp://ftp.sane-project.org/pub/sane/${P}/${P}.tar.gz
+       ftp://ftp.sane-project.org/pub/sane/old-versions/${P}/${P}.tar.gz"
+SLOT="0"
+LICENSE="GPL-2 public-domain"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+
+pkg_setup() {
+       enewgroup scanner
+}
+
+src_prepare() {
+       cat >> backend/dll.conf.in <<-EOF
+       # Add support for the HP-specific backend.  Needs net-print/hplip installed.
+       hpaio
+       # Add support for the Epson-specific backend.  Needs media-gfx/iscan installed.
+       epkowa
+       EOF
+       #epatch "${DISTDIR}/${P}-i18n.patch"
+
+       # Bug #368083
+       epatch "${FILESDIR}"/${P}-xerox_mfp-usb.patch
+       # Bug #356919
+       epatch "${FILESDIR}"/${P}-libv4l-0.8.3.patch
+       # Bug #329047
+       epatch "${FILESDIR}"/niash_array_index.patch
+}
+
+src_configure() {
+       append-flags -fno-strict-aliasing
+
+       # the blank is intended - an empty string would result in building ALL backends.
+       local BACKENDS=" "
+
+       use gphoto2 && BACKENDS="gphoto2"
+       use v4l && BACKENDS="${BACKENDS} v4l"
+       for backend in ${IUSE_SANE_BACKENDS}; do
+               if use "sane_backends_${backend}" && [ ${backend} != pnm ]; then
+                       BACKENDS="${BACKENDS} ${backend}"
+               fi
+       done
+
+       local myconf=$(use_enable usb libusb)
+       # you can only enable this backend, not disable it...
+       if use sane_backends_pnm; then
+               myconf="${myconf} --enable-pnm-backend"
+       fi
+       if ! use doc; then
+               myconf="${myconf} --disable-latex"
+       fi
+       if use sane_backends_mustek_pp; then
+               myconf="${myconf} --enable-parport-directio"
+       fi
+       if ! ( use sane_backends_canon_pp || use sane_backends_hpsj5s || use sane_backends_mustek_pp ); then
+               myconf="${myconf} sane_cv_use_libieee1284=no"
+       fi
+       SANEI_JPEG="sanei_jpeg.o" SANEI_JPEG_LO="sanei_jpeg.lo" \
+       BACKENDS="${BACKENDS}" econf \
+               $(use_with gphoto2) \
+               $(use_enable ipv6) \
+               $(use_enable avahi) \
+               ${myconf}
+}
+
+src_compile() {
+       emake VARTEXFONTS="${T}/fonts" || die
+
+       if use usb; then
+               cd tools/hotplug
+               grep -v '^$' libsane.usermap > libsane.usermap.new
+               mv libsane.usermap.new libsane.usermap
+       fi
+}
+
+src_install () {
+       emake INSTALL_LOCKPATH="" DESTDIR="${D}" install \
+               docdir=/usr/share/doc/${PF} || die
+       keepdir /var/lib/lock/sane
+       fowners root:scanner /var/lib/lock/sane
+       fperms g+w /var/lib/lock/sane
+       dodir /etc/env.d
+       if use usb; then
+               insinto /etc/hotplug/usb
+               exeinto /etc/hotplug/usb
+               doins tools/hotplug/libsane.usermap
+               doexe tools/hotplug/libusbscanner
+               newdoc tools/hotplug/README README.hotplug
+               echo >> "${D}"/etc/env.d/30sane "USB_DEVFS_PATH=/dev/bus/usb"
+       fi
+       insinto /lib/udev/rules.d
+       newins tools/udev/libsane.rules 41-libsane.rules
+
+       dodoc NEWS AUTHORS ChangeLog* README README.linux
+       echo "SANE_CONFIG_DIR=/etc/sane.d" >> "${D}"/etc/env.d/30sane
+       find "${D}" -name "*.la" | while read file; do rm "${file}"; done
+}