mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
removed extra/sane
This commit is contained in:
parent
fa5350a35d
commit
3e03aa77d8
6 changed files with 0 additions and 241 deletions
|
@ -1,73 +0,0 @@
|
|||
# Maintainer: Tobias Powalowski <tpowa@archlinux.org>
|
||||
# Contributor: Sarah Hay <sarahhay@mb.sympatico.ca>
|
||||
# Contributor: Simo L. <neotuli@yahoo.com>
|
||||
# Contributor: eric <eric@archlinux.org>
|
||||
|
||||
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org
|
||||
# - remove v4l-utils depend, which disables v4l backend, which causes random floating point exceptions
|
||||
|
||||
pkgname=sane
|
||||
pkgver=1.0.27
|
||||
pkgrel=2
|
||||
pkgdesc="Scanner Access Now Easy"
|
||||
url="http://www.sane-project.org/"
|
||||
arch=('x86_64')
|
||||
license=('GPL')
|
||||
depends=('libtiff>=4.0.0' 'libgphoto2' 'libjpeg>=8' 'libusbx' 'libcups' 'libieee1284' 'avahi' 'bash' 'net-snmp')
|
||||
makedepends=('texlive-latexextra')
|
||||
backup=(etc/sane.d/{abaton.conf,agfafocus.conf,apple.conf,artec.conf,artec_eplus48u.conf,avision.conf,bh.conf,canon.conf,canon630u.conf,canon_dr.conf,canon_pp.conf,cardscan.conf,coolscan2.conf,coolscan3.conf,coolscan.conf,dc25.conf,dc210.conf,dc240.conf,dell1600n_net.conf,dll.conf,dmc.conf,epjitsu.conf,epson.conf,epson2.conf,epsonds.conf,fujitsu.conf,genesys.conf,gphoto2.conf,gt68xx.conf,hp.conf,hp3900.conf,hp4200.conf,hp5400.conf,hpsj5s.conf,hs2p.conf,ibm.conf,kodak.conf,kodakaio.conf,leo.conf,lexmark.conf,ma1509.conf,magicolor.conf,matsushita.conf,microtek.conf,microtek2.conf,mustek.conf,mustek_pp.conf,mustek_usb.conf,nec.conf,net.conf,p5.conf,pie.conf,pieusb.conf,pixma.conf,plustek.conf,plustek_pp.conf,qcam.conf,ricoh.conf,rts8891.conf,s9036.conf,saned.conf,sceptre.conf,sharp.conf,sm3840.conf,snapscan.conf,sp15c.conf,st400.conf,stv680.conf,tamarack.conf,teco1.conf,teco2.conf,teco3.conf,test.conf,u12.conf,umax.conf,umax1220u.conf,umax_pp.conf,xerox_mfp.conf,v4l.conf} etc/xinetd.d/sane)
|
||||
source=(https://sources.archlinux.org/other/sane/$pkgname-backends-$pkgver.tar.gz
|
||||
'sane.xinetd'
|
||||
'saned.socket'
|
||||
'saned.service'
|
||||
'network.patch')
|
||||
|
||||
prepare() {
|
||||
cd "${srcdir}/${pkgname}-backends-${pkgver}"
|
||||
# fix http://vasks.debian.org/tracker/?func=detail&atid=410366&aid=313760&group_id=30186
|
||||
patch -Np1 -i ${srcdir}/network.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
cd "${srcdir}/${pkgname}-backends-${pkgver}"
|
||||
|
||||
./configure --prefix=/usr --sbindir=/usr/bin \
|
||||
--sysconfdir=/etc \
|
||||
--localstatedir=/var \
|
||||
--with-docdir=/usr/share/doc/sane \
|
||||
--enable-avahi \
|
||||
--enable-pthread \
|
||||
--disable-rpath \
|
||||
--enable-libusb_1_0 \
|
||||
--disable-locking
|
||||
make
|
||||
}
|
||||
|
||||
package () {
|
||||
cd "${srcdir}/${pkgname}-backends-${pkgver}"
|
||||
make DESTDIR="${pkgdir}" install
|
||||
# fix hp officejets
|
||||
echo "#hpaio" >> "${pkgdir}/etc/sane.d/dll.conf"
|
||||
# install udev files
|
||||
install -D -m0644 tools/udev/libsane.rules \
|
||||
"${pkgdir}/usr/lib/udev/rules.d/49-sane.rules"
|
||||
# fix udev rules
|
||||
sed -i 's|NAME="%k", ||g' "${pkgdir}/usr/lib/udev/rules.d/49-sane.rules"
|
||||
|
||||
# install xinetd file
|
||||
install -D -m644 "${srcdir}/sane.xinetd" "${pkgdir}/etc/xinetd.d/sane"
|
||||
|
||||
# Install the pkg-config file
|
||||
install -D -m644 tools/sane-backends.pc \
|
||||
"${pkgdir}/usr/lib/pkgconfig/sane-backends.pc"
|
||||
# install systemd files
|
||||
install -D -m644 ${srcdir}/saned.socket \
|
||||
"${pkgdir}/usr/lib/systemd/system/saned.socket"
|
||||
install -D -m644 ${srcdir}/saned.service \
|
||||
"${pkgdir}/usr/lib/systemd/system/saned@.service"
|
||||
}
|
||||
sha512sums=('c6552768bfc10216730fc11011c82f74ca0952182019ded3916072147ec09be5c975ce1d37dc3ccea050c488dbdf983c2ca17dcd702644060ba796ae2591f9c5'
|
||||
'8f9f18d432087e5445aa533be375a811daf320512069c108d41a79121868937e1a7ffa21ee7d33adcf9fbb670bca460ff06423ce39602f35151eccc243d9d4ec'
|
||||
'62654a59fae3216be9c0ae4f810375de1232133ab12732529a3e064cc83d94563560e01950dea4b25aa298294c5f0421436c5e095a3a00ad8ef78b471f3105f4'
|
||||
'c4cd4427ee8e5cb128c5d54006fafbb4f846508582dffc293f16ab14ab638e6ee3dc5df0eb06f6d0d3839941ab74623c7163ac13bcdfec87b10308587a697536'
|
||||
'04b65a06d2c76dde6fce501ba823e999eb89ea41573f887f9e7d5347f3aa5e35310fad69313e99f873640e29a9849372d2ff995678593a0781fba73b464bec0d')
|
|
@ -1,42 +0,0 @@
|
|||
diff --git a/sanei/sanei_tcp.c b/sanei/sanei_tcp.c
|
||||
index a57d7c7..d0a1e92 100644
|
||||
--- a/sanei/sanei_tcp.c
|
||||
+++ b/sanei/sanei_tcp.c
|
||||
@@ -45,6 +45,7 @@
|
||||
#include <unistd.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
+#include <time.h>
|
||||
|
||||
#ifdef HAVE_WINSOCK2_H
|
||||
#include <winsock2.h>
|
||||
@@ -123,14 +124,27 @@ sanei_tcp_write(int fd, const u_char * buf, int count)
|
||||
ssize_t
|
||||
sanei_tcp_read(int fd, u_char * buf, int count)
|
||||
{
|
||||
- ssize_t bytes_recv = 0, rc = 1;
|
||||
+ ssize_t bytes_recv = 0, rc = 1;
|
||||
+ int retry = 5;
|
||||
|
||||
while (bytes_recv < count && rc > 0)
|
||||
{
|
||||
rc = recv(fd, buf+bytes_recv, count-bytes_recv, 0);
|
||||
+ DBG(1, "%s: bytes received %d\n", __FUNCTION__, rc);
|
||||
if (rc > 0)
|
||||
bytes_recv += rc;
|
||||
-
|
||||
+ else {
|
||||
+ if ( errno == EAGAIN && retry-- ) {
|
||||
+ DBG(1, "%s: waiting %d\n", __FUNCTION__, retry);
|
||||
+ /* wait for max 1s */
|
||||
+ struct timespec req;
|
||||
+ struct timespec rem;
|
||||
+ req.tv_sec = 0;
|
||||
+ req.tv_nsec= 100000000;
|
||||
+ nanosleep(&req, &rem);
|
||||
+ rc = 1;
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
return bytes_recv;
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
service sane-port
|
||||
{
|
||||
port = 6566
|
||||
socket_type = stream
|
||||
wait = no
|
||||
user = nobody
|
||||
group = scanner
|
||||
server = /usr/bin/saned
|
||||
# disabled by default!
|
||||
disable = yes
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
[Unit]
|
||||
Description=Scanner Service
|
||||
|
||||
[Service]
|
||||
Group=scanner
|
||||
ExecStart=/usr/bin/saned
|
||||
StandardInput=socket
|
||||
StandardError=syslog
|
|
@ -1,9 +0,0 @@
|
|||
[Unit]
|
||||
Description=saned incoming socket
|
||||
|
||||
[Socket]
|
||||
ListenStream=6566
|
||||
Accept=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=sockets.target
|
|
@ -1,98 +0,0 @@
|
|||
From 37523b867d411c2f82d08128246be7e38bc9812c Mon Sep 17 00:00:00 2001
|
||||
From: Paul Newall <quandry@ntlworld.com>
|
||||
Date: Mon, 14 Oct 2013 22:22:53 +0100
|
||||
Subject: [PATCH] Bugfix in kodakaio.c to fix segfault when non kodak scanners
|
||||
return unexpected data via avahi auto discovery
|
||||
|
||||
---
|
||||
backend/kodakaio.c | 43 ++++++++++++++++++++++++++++++----------
|
||||
doc/descriptions/kodakaio.desc | 2 +-
|
||||
3 files changed, 37 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/backend/kodakaio.c b/backend/kodakaio.c
|
||||
index 8c4583a..b442e50 100644
|
||||
--- a/backend/kodakaio.c
|
||||
+++ b/backend/kodakaio.c
|
||||
@@ -127,7 +127,7 @@ for ubuntu 12.10
|
||||
|
||||
#define KODAKAIO_VERSION 02
|
||||
#define KODAKAIO_REVISION 4
|
||||
-#define KODAKAIO_BUILD 6
|
||||
+#define KODAKAIO_BUILD 7
|
||||
|
||||
/* for usb (but also used for net though it's not required). */
|
||||
#define MAX_BLOCK_SIZE 32768
|
||||
@@ -2184,6 +2184,7 @@ static void resolve_callback(
|
||||
AvahiLookupResultFlags flags,
|
||||
AVAHI_GCC_UNUSED void* userdata) {
|
||||
|
||||
+ AvahiStringList *vid_pair_list = NULL, *pid_pair_list = NULL;
|
||||
char *pidkey, *pidvalue;
|
||||
char *vidkey, *vidvalue;
|
||||
size_t valuesize;
|
||||
@@ -2204,20 +2205,40 @@ static void resolve_callback(
|
||||
avahi_address_snprint(a, sizeof(a), address);
|
||||
|
||||
/* Output short for Kodak ESP */
|
||||
- DBG(min(10,DBG_AUTO), "%s:%u %s ", a,port,host_name);
|
||||
- avahi_string_list_get_pair(avahi_string_list_find(txt, "vid"),
|
||||
- &vidkey, &vidvalue, &valuesize);
|
||||
- DBG(min(10,DBG_AUTO), "%s=%s ", vidkey, vidvalue);
|
||||
- avahi_string_list_get_pair(avahi_string_list_find(txt, "pid"),
|
||||
- &pidkey, &pidvalue, &valuesize);
|
||||
- DBG(min(10,DBG_AUTO), "%s=%s\n", pidkey, pidvalue);
|
||||
+ DBG(min(10,DBG_AUTO), "%s:%u %s\n", a,port,host_name);
|
||||
|
||||
+ vid_pair_list = avahi_string_list_find(txt, "vid");
|
||||
+ if(vid_pair_list != NULL) {
|
||||
+ avahi_string_list_get_pair(vid_pair_list, &vidkey, &vidvalue, &valuesize);
|
||||
+ DBG(min(10,DBG_AUTO), "%s=%s ", vidkey, vidvalue);
|
||||
+ }
|
||||
+ else DBG(min(10,DBG_AUTO), "failed to find key vid\n");
|
||||
+
|
||||
+ pid_pair_list = avahi_string_list_find(txt, "pid");
|
||||
+ if(pid_pair_list != NULL) {
|
||||
+ avahi_string_list_get_pair(pid_pair_list, &pidkey, &pidvalue, &valuesize);
|
||||
+ DBG(min(10,DBG_AUTO), "%s=%s\n", pidkey, pidvalue);
|
||||
+ }
|
||||
+ else DBG(min(10,DBG_AUTO), "failed to find key pid\n");
|
||||
+
|
||||
+ if(pid_pair_list != NULL && vid_pair_list != NULL) {
|
||||
ProcessAvahiDevice(name, vidvalue, pidvalue, a);
|
||||
- avahi_free(vidkey); avahi_free(vidvalue);
|
||||
- avahi_free(pidkey); avahi_free(pidvalue);
|
||||
+ }
|
||||
+ else DBG(min(10,DBG_AUTO), "didn't call ProcessAvahiDevice\n");
|
||||
+
|
||||
+ if(vid_pair_list != NULL) {
|
||||
+ avahi_free(vidkey);
|
||||
+ avahi_free(vidvalue);
|
||||
+ DBG(min(15,DBG_AUTO), "vidkey and vidvalue freed\n");
|
||||
+ }
|
||||
+ if(pid_pair_list != NULL) {
|
||||
+ avahi_free(pidkey);
|
||||
+ avahi_free(pidvalue);
|
||||
+ DBG(min(15,DBG_AUTO), "pidkey and pidvalue freed\n");
|
||||
+ }
|
||||
}
|
||||
}
|
||||
-
|
||||
+ DBG(min(10,DBG_AUTO), "ending resolve_callback\n");
|
||||
avahi_service_resolver_free(r);
|
||||
}
|
||||
|
||||
diff --git a/doc/descriptions/kodakaio.desc b/doc/descriptions/kodakaio.desc
|
||||
index 7882513..5fb18ed 100644
|
||||
--- a/doc/descriptions/kodakaio.desc
|
||||
+++ b/doc/descriptions/kodakaio.desc
|
||||
@@ -1,6 +1,6 @@
|
||||
:backend "kodakaio"
|
||||
:url "http://sourceforge.net/projects/cupsdriverkodak/"
|
||||
-:version "2.4.6"
|
||||
+:version "2.4.7"
|
||||
:manpage "sane-kodakaio"
|
||||
:comment "Backend for Kodak AiO ESP and Hero printers. Also possibly Advent AWL10"
|
||||
:devicetype :scanner
|
||||
--
|
||||
1.7.10.4
|
||||
|
Loading…
Reference in a new issue