From b7cd4b184f75d3d2b54b356e08f296df3a9afb38 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 30 Apr 2012 00:01:38 +0000 Subject: Mon Apr 30 00:01:38 UTC 2012 --- testing/thinkfinger/PKGBUILD | 44 +++++++++++++++++++++++ testing/thinkfinger/gcc46.patch | 22 ++++++++++++ testing/thinkfinger/thinkfinger-uinput-hack.patch | 13 +++++++ testing/thinkfinger/thinkfinger.install | 4 +++ 4 files changed, 83 insertions(+) create mode 100644 testing/thinkfinger/PKGBUILD create mode 100644 testing/thinkfinger/gcc46.patch create mode 100644 testing/thinkfinger/thinkfinger-uinput-hack.patch create mode 100644 testing/thinkfinger/thinkfinger.install (limited to 'testing/thinkfinger') diff --git a/testing/thinkfinger/PKGBUILD b/testing/thinkfinger/PKGBUILD new file mode 100644 index 000000000..7aae89b5d --- /dev/null +++ b/testing/thinkfinger/PKGBUILD @@ -0,0 +1,44 @@ +# $Id: PKGBUILD 157520 2012-04-28 21:41:20Z dreisner $ +# Maintainer: Tom Gundersen +# Contributor: François Charette +# Contributor: Damir Perisa +# Contributor: Björn Martensen + +pkgname=thinkfinger +pkgver=0.3 +pkgrel=6 +pkgdesc="A driver for the SGS Thomson Microelectronics fingerprint reader found in most IBM/Lenovo ThinkPads" +url="http://thinkfinger.sourceforge.net/" +arch=('i686' 'x86_64') +license=("GPL") +depends=('pam' 'libusb-compat') +install=thinkfinger.install +options=('!libtool' 'emptydirs') +source=("http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz" + 'thinkfinger-uinput-hack.patch' + 'gcc46.patch') +md5sums=('588565233bcbea5ff0a7f5314361c380' + '71dc334282d19e6db4f6254542ba563c' + '93c80f342329a5bd40f5f324fe670225') + +build() { + cd $srcdir/$pkgname-$pkgver + + # Patch from Ubuntu: see http://bugs.archlinux.org/task/12580 + patch -p0 -i "${srcdir}"/thinkfinger-uinput-hack.patch + + patch -p1 -i "${srcdir}"/gcc46.patch + + ./configure --prefix=/usr \ + --with-birdir=/etc/pam_thinkfinger + make +} + +package() { + cd $srcdir/$pkgname-$pkgver + + # create dir to store fingerprints + install -d $pkgdir/etc/pam_thinkfinger + + make DESTDIR=$pkgdir install +} diff --git a/testing/thinkfinger/gcc46.patch b/testing/thinkfinger/gcc46.patch new file mode 100644 index 000000000..24e4b534f --- /dev/null +++ b/testing/thinkfinger/gcc46.patch @@ -0,0 +1,22 @@ +--- a/pam/Makefile.am ++++ b/pam/Makefile.am +@@ -8,7 +8,7 @@ pam_thinkfinger_so_SOURCES = pam_thinkfinger-compat.c pam_thinkfinger-compat.h p + else + pam_thinkfinger_so_SOURCES = pam_thinkfinger-uinput.c pam_thinkfinger-uinput.h pam_thinkfinger.c + endif +-pam_thinkfinger_so_LDFLAGS = -shared --strip-all -Wl,-soname,pam_thinkfinger.so -Wl,--as-needed ++pam_thinkfinger_so_LDFLAGS = -shared -Wl,-soname,pam_thinkfinger.so -Wl,--as-needed + pam_thinkfinger_so_CFLAGS = $(CFLAGS) + pam_thinkfinger_so_LDADD = $(top_builddir)/libthinkfinger/libthinkfinger.la $(PAM_LIBS) $(PTHREAD_LIBS) + +--- a/pam/Makefile.in ++++ b/pam/Makefile.in +@@ -201,7 +201,7 @@ pamdir = $(SECUREDIR) + INCLUDES = -I$(top_srcdir)/libthinkfinger + @HAVE_OLD_PAM_FALSE@pam_thinkfinger_so_SOURCES = pam_thinkfinger-uinput.c pam_thinkfinger-uinput.h pam_thinkfinger.c + @HAVE_OLD_PAM_TRUE@pam_thinkfinger_so_SOURCES = pam_thinkfinger-compat.c pam_thinkfinger-compat.h pam_thinkfinger-uinput.c pam_thinkfinger-uinput.h pam_thinkfinger.c +-pam_thinkfinger_so_LDFLAGS = -shared --strip-all -Wl,-soname,pam_thinkfinger.so -Wl,--as-needed ++pam_thinkfinger_so_LDFLAGS = -shared -Wl,-soname,pam_thinkfinger.so -Wl,--as-needed + pam_thinkfinger_so_CFLAGS = $(CFLAGS) + pam_thinkfinger_so_LDADD = $(top_builddir)/libthinkfinger/libthinkfinger.la $(PAM_LIBS) $(PTHREAD_LIBS) + all: all-am diff --git a/testing/thinkfinger/thinkfinger-uinput-hack.patch b/testing/thinkfinger/thinkfinger-uinput-hack.patch new file mode 100644 index 000000000..0ac153464 --- /dev/null +++ b/testing/thinkfinger/thinkfinger-uinput-hack.patch @@ -0,0 +1,13 @@ +#Source: http://launchpadlibrarian.net/18515541/thinkfinger-uinput-hack.patch (26-12-2008) +Index: pam/pam_thinkfinger-uinput.c +=================================================================== +--- pam/pam_thinkfinger-uinput.c (revision 118) ++++ pam/pam_thinkfinger-uinput.c (working copy) +@@ -95,6 +95,7 @@ + /* our single key keyboard */ + i = ioctl (*fd, UI_SET_EVBIT, EV_KEY) < 0; + i |= ioctl (*fd, UI_SET_KEYBIT, KEY_ENTER) < 0; ++ i |= ioctl (*fd, UI_SET_KEYBIT, KEY_A) < 0; + + if (write (*fd, &device, device_size) != device_size) { + retval = errno; diff --git a/testing/thinkfinger/thinkfinger.install b/testing/thinkfinger/thinkfinger.install new file mode 100644 index 000000000..bb1f6dde0 --- /dev/null +++ b/testing/thinkfinger/thinkfinger.install @@ -0,0 +1,4 @@ +post_install() { + echo "==> To use thinkfinger, add 'uinput' to the MODULES=() in /etc/rc.conf." + echo " More Infos: http://wiki.archlinux.org/index.php/Thinkfinger" +} -- cgit v1.2.3-54-g00ecf