Gentoo Archives: gentoo-commits

From: Joonas Niilola <juippis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-gfx/sane-backends/
Date: Sat, 27 Jun 2020 06:18:31
Message-Id: 1593238696.a0e49052d0e68eaf771d08e34dbe88e341d16eda.juippis@gentoo
1 commit: a0e49052d0e68eaf771d08e34dbe88e341d16eda
2 Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jun 27 06:17:53 2020 +0000
4 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
5 CommitDate: Sat Jun 27 06:18:16 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a0e49052
7
8 media-gfx/sane-backends: remove old 1.0.30
9
10 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
11
12 .../sane-backends/sane-backends-1.0.30.ebuild | 344 ---------------------
13 1 file changed, 344 deletions(-)
14
15 diff --git a/media-gfx/sane-backends/sane-backends-1.0.30.ebuild b/media-gfx/sane-backends/sane-backends-1.0.30.ebuild
16 deleted file mode 100644
17 index 19095de1445..00000000000
18 --- a/media-gfx/sane-backends/sane-backends-1.0.30.ebuild
19 +++ /dev/null
20 @@ -1,344 +0,0 @@
21 -# Copyright 1999-2020 Gentoo Authors
22 -# Distributed under the terms of the GNU General Public License v2
23 -
24 -EAPI=7
25 -
26 -inherit autotools eutils flag-o-matic multilib-minimal systemd toolchain-funcs udev user
27 -
28 -# gphoto and v4l are handled by their usual USE flags.
29 -# The pint backend was disabled because I could not get it to compile.
30 -IUSE_SANE_BACKENDS="
31 - abaton
32 - agfafocus
33 - apple
34 - artec
35 - artec_eplus48u
36 - as6e
37 - avision
38 - bh
39 - canon
40 - canon630u
41 - canon_dr
42 - canon_pp
43 - cardscan
44 - coolscan
45 - coolscan2
46 - coolscan3
47 - dc210
48 - dc240
49 - dc25
50 - dell1600n_net
51 - dmc
52 - epjitsu
53 - epson
54 - epson2
55 - fujitsu
56 - genesys
57 - gt68xx
58 - hp
59 - hp3500
60 - hp3900
61 - hp4200
62 - hp5400
63 - hp5590
64 - hpljm1005
65 - hpsj5s
66 - hs2p
67 - ibm
68 - kodak
69 - kodakaio
70 - kvs1025
71 - kvs20xx
72 - kvs40xx
73 - leo
74 - lexmark
75 - ma1509
76 - magicolor
77 - matsushita
78 - microtek
79 - microtek2
80 - mustek
81 - mustek_pp
82 - mustek_usb
83 - mustek_usb2
84 - nec
85 - net
86 - niash
87 - p5
88 - pie
89 - pixma
90 - plustek
91 - plustek_pp
92 - pnm
93 - qcam
94 - ricoh
95 - rts8891
96 - s9036
97 - sceptre
98 - sharp
99 - sm3600
100 - sm3840
101 - snapscan
102 - sp15c
103 - st400
104 - stv680
105 - tamarack
106 - teco1
107 - teco2
108 - teco3
109 - test
110 - u12
111 - umax
112 - umax1220u
113 - umax_pp
114 - xerox_mfp"
115 -
116 -IUSE="gphoto2 ipv6 snmp systemd threads usb v4l xinetd zeroconf"
117 -
118 -for backend in ${IUSE_SANE_BACKENDS}; do
119 - case ${backend} in
120 - # Disable backends that require parallel ports as no one has those anymore.
121 - canon_pp|hpsj5s|mustek_pp|\
122 - pnm)
123 - IUSE+=" -sane_backends_${backend}"
124 - ;;
125 - mustek_usb2|kvs40xx)
126 - IUSE+=" sane_backends_${backend}"
127 - ;;
128 - *)
129 - IUSE+=" +sane_backends_${backend}"
130 - esac
131 -done
132 -
133 -REQUIRED_USE="
134 - sane_backends_mustek_usb2? ( threads )
135 - sane_backends_kvs40xx? ( threads )
136 -"
137 -
138 -MY_PN=${PN//sane-/}
139 -MY_P="${MY_PN}-${PV}"
140 -
141 -DESCRIPTION="Scanner Access Now Easy - Backends"
142 -HOMEPAGE="http://www.sane-project.org/"
143 -SRC_URI="https://gitlab.com/sane-project/${MY_PN}/-/archive/${PV}/${MY_P}.tar.gz"
144 -
145 -LICENSE="GPL-2 public-domain"
146 -SLOT="0"
147 -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
148 -
149 -RDEPEND="
150 - sane_backends_dc210? ( >=virtual/jpeg-0-r2:0=[${MULTILIB_USEDEP}] )
151 - sane_backends_dc240? ( >=virtual/jpeg-0-r2:0=[${MULTILIB_USEDEP}] )
152 - sane_backends_dell1600n_net? (
153 - >=virtual/jpeg-0-r2:0=[${MULTILIB_USEDEP}]
154 - >=media-libs/tiff-3.9.7-r1:0=[${MULTILIB_USEDEP}]
155 - )
156 - sane_backends_canon_pp? ( >=sys-libs/libieee1284-0.2.11-r3[${MULTILIB_USEDEP}] )
157 - sane_backends_hpsj5s? ( >=sys-libs/libieee1284-0.2.11-r3[${MULTILIB_USEDEP}] )
158 - sane_backends_mustek_pp? ( >=sys-libs/libieee1284-0.2.11-r3[${MULTILIB_USEDEP}] )
159 - usb? ( >=virtual/libusb-1-r1:1=[${MULTILIB_USEDEP}] )
160 - gphoto2? (
161 - >=media-libs/libgphoto2-2.5.3.1:=[${MULTILIB_USEDEP}]
162 - >=virtual/jpeg-0-r2:0=[${MULTILIB_USEDEP}]
163 - )
164 - v4l? ( >=media-libs/libv4l-0.9.5[${MULTILIB_USEDEP}] )
165 - xinetd? ( sys-apps/xinetd )
166 - snmp? ( net-analyzer/net-snmp:0= )
167 - systemd? ( sys-apps/systemd:0= )
168 - zeroconf? ( >=net-dns/avahi-0.6.31-r2[${MULTILIB_USEDEP}] )
169 -"
170 -
171 -DEPEND="${RDEPEND}
172 - v4l? ( sys-kernel/linux-headers )
173 - >=sys-devel/gettext-0.18.1
174 - virtual/pkgconfig
175 -"
176 -
177 -PATCHES=(
178 - "${FILESDIR}"/${PN}-1.0.24-saned_pidfile_location.patch
179 - "${FILESDIR}"/${PN}-1.0.27-disable-usb-tests.patch
180 - "${FILESDIR}"/${P}-missing-stdint-include.patch
181 -)
182 -
183 -S="${WORKDIR}/${MY_P}"
184 -
185 -MULTILIB_CHOST_TOOLS=(
186 - /usr/bin/sane-config
187 -)
188 -
189 -pkg_setup() {
190 - enewgroup scanner
191 - enewuser saned -1 -1 -1 scanner
192 -}
193 -
194 -src_prepare() {
195 - default
196 -
197 - cat >> backend/dll.conf.in <<-EOF
198 - # Add support for the HP-specific backend. Needs net-print/hplip installed.
199 - hpaio
200 - # Add support for the Epson-specific backend. Needs media-gfx/iscan installed.
201 - epkowa
202 - EOF
203 -
204 - # Patch out the git reference so we can run eautoreconf
205 - sed -i -e "s/m4_esyscmd_s(\[git describe --dirty\])/${PV}/" configure.ac || die
206 - eautoreconf
207 -
208 - # Fix for "make check". Upstream sometimes forgets to update this.
209 - local ver=$(./configure --version | awk '{print $NF; exit 0}')
210 - sed -i \
211 - -e "/by sane-desc 3.5 from sane-backends/s:sane-backends .*:sane-backends ${ver}:" \
212 - testsuite/tools/data/html* || die
213 -
214 -}
215 -
216 -src_configure() {
217 - append-flags -fno-strict-aliasing # From Fedora
218 -
219 - # if LINGUAS is set, just use the listed and supported localizations.
220 - if [[ ${LINGUAS+set} == "set" ]]; then
221 - mkdir -p po || die
222 - strip-linguas -u po
223 - printf '%s\n' ${LINGUAS} > po/LINGUAS
224 - fi
225 -
226 - multilib-minimal_src_configure
227 -}
228 -
229 -multilib_src_configure() {
230 - # the blank is intended - an empty string would result in building ALL backends.
231 - local BACKENDS=" "
232 -
233 - use gphoto2 && BACKENDS="gphoto2"
234 - use v4l && BACKENDS="${BACKENDS} v4l"
235 - for backend in ${IUSE_SANE_BACKENDS}; do
236 - if use "sane_backends_${backend}" && [ ${backend} != pnm ]; then
237 - BACKENDS="${BACKENDS} ${backend}"
238 - fi
239 - done
240 -
241 - local myconf=(
242 - $(use_with usb)
243 - $(multilib_native_use_with snmp)
244 - )
245 -
246 - # you can only enable this backend, not disable it...
247 - if use sane_backends_pnm; then
248 - myconf+=( --enable-pnm-backend )
249 - fi
250 - if use sane_backends_mustek_pp; then
251 - myconf+=( --enable-parport-directio )
252 - fi
253 - if ! { use sane_backends_canon_pp || use sane_backends_hpsj5s || use sane_backends_mustek_pp; }; then
254 - myconf+=( sane_cv_use_libieee1284=no )
255 - fi
256 -
257 - # relative path must be used for tests to work properly
258 - # All distributions pass --disable-locking because /var/lock/sane/ would be a world-writable directory
259 - # --without-api-spec to not automagically depend on tons of stuff
260 - # that break in many ways, bug #636202, #668232, #668350
261 - # People can refer to the "Programmer's Documentation" at http://www.sane-project.org/docs.html
262 - ECONF_SOURCE=${S} \
263 - SANEI_JPEG="sanei_jpeg.o" SANEI_JPEG_LO="sanei_jpeg.lo" \
264 - BACKENDS="${BACKENDS}" \
265 - econf \
266 - --disable-locking \
267 - --without-api-spec \
268 - $(use_with gphoto2) \
269 - $(multilib_native_use_with systemd) \
270 - $(use_with v4l) \
271 - $(use_enable ipv6) \
272 - $(use_enable threads pthread) \
273 - $(use_enable zeroconf avahi) \
274 - "${myconf[@]}"
275 -}
276 -
277 -multilib_src_compile() {
278 - emake VARTEXFONTS="${T}/fonts"
279 -
280 - if tc-is-cross-compiler; then
281 - pushd "${BUILD_DIR}"/tools >/dev/null || die
282 -
283 - # The build system sucks and doesn't handle this properly.
284 - # https://alioth.debian.org/tracker/index.php?func=detail&aid=314236&group_id=30186&atid=410366
285 - tc-export_build_env BUILD_CC
286 - ${BUILD_CC} ${BUILD_CPPFLAGS} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} \
287 - -I. -I../include -I"${S}"/include \
288 - "${S}"/sanei/sanei_config.c "${S}"/sanei/sanei_constrain_value.c \
289 - "${S}"/sanei/sanei_init_debug.c "${S}"/tools/sane-desc.c -o sane-desc || die
290 - local dirs=( hal hotplug hotplug-ng udev )
291 - local targets=(
292 - hal/libsane.fdi
293 - hotplug/libsane.usermap
294 - hotplug-ng/libsane.db
295 - udev/libsane.rules
296 - )
297 - mkdir -p "${dirs[@]}" || die
298 - emake "${targets[@]}"
299 -
300 - popd >/dev/null
301 - fi
302 -
303 - if use usb; then
304 - sed -i -e '/^$/d' \
305 - tools/hotplug/libsane.usermap || die
306 - fi
307 -}
308 -
309 -multilib_src_install() {
310 - emake INSTALL_LOCKPATH="" DESTDIR="${D}" install \
311 - docdir="${EPREFIX}"/usr/share/doc/${PF}
312 -
313 - if multilib_is_native_abi; then
314 - if use usb; then
315 - insinto /etc/hotplug/usb
316 - doins tools/hotplug/libsane.usermap
317 - fi
318 -
319 - udev_newrules tools/udev/libsane.rules 41-libsane.rules
320 - insinto "/usr/share/pkgconfig"
321 - doins tools/sane-backends.pc
322 - fi
323 -}
324 -
325 -multilib_src_install_all() {
326 - keepdir /var/lib/lock/sane
327 - fowners root:scanner /var/lib/lock/sane
328 - fperms g+w /var/lib/lock/sane
329 - dodir /etc/env.d
330 -
331 - if use systemd; then
332 - systemd_newunit "${FILESDIR}"/saned_at.service "saned@.service"
333 - systemd_newunit "${FILESDIR}"/saned.socket saned.socket
334 - fi
335 -
336 - if use usb; then
337 - exeinto /etc/hotplug/usb
338 - doexe tools/hotplug/libusbscanner
339 - newdoc tools/hotplug/README README.hotplug
340 - fi
341 -
342 - dodoc NEWS AUTHORS PROBLEMS README README.linux
343 - find "${D}" -name '*.la' -delete || die
344 -
345 - if use xinetd; then
346 - insinto /etc/xinetd.d
347 - doins "${FILESDIR}"/saned
348 - fi
349 -
350 - newinitd "${FILESDIR}"/saned.initd saned
351 - newconfd "${FILESDIR}"/saned.confd saned
352 -}
353 -
354 -pkg_postinst() {
355 - if use xinetd; then
356 - elog "If you want remote clients to connect, edit"
357 - elog "/etc/sane.d/saned.conf and /etc/hosts.allow"
358 - fi
359 -
360 - if ! use systemd; then
361 - elog "If you are using a USB scanner, add all users who want"
362 - elog "to access your scanner to the \"scanner\" group."
363 - fi
364 -}