summaryrefslogtreecommitdiff
path: root/testing/libgphoto2
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-03-10 00:01:15 +0000
committerroot <root@rshg054.dnsready.net>2012-03-10 00:01:15 +0000
commit3792e3874accbc868e7032042f1ecefdef25638e (patch)
tree2ba250e0011924d6172b918515475864187e84db /testing/libgphoto2
parent0a7c64736c0b026c3105928d89500a8af1ad5eac (diff)
Sat Mar 10 00:01:15 UTC 2012
Diffstat (limited to 'testing/libgphoto2')
-rw-r--r--testing/libgphoto2/PKGBUILD43
-rw-r--r--testing/libgphoto2/libgphoto2.install6
2 files changed, 49 insertions, 0 deletions
diff --git a/testing/libgphoto2/PKGBUILD b/testing/libgphoto2/PKGBUILD
new file mode 100644
index 000000000..323b863db
--- /dev/null
+++ b/testing/libgphoto2/PKGBUILD
@@ -0,0 +1,43 @@
+# $Id: PKGBUILD 152700 2012-03-08 23:18:37Z tomegun $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+# Contributor: Tom Gundersen <teg@jklm.no>
+# Contributor: Eduardo Romero <eduardo@archlinux.org>
+# Contributor: Damir Perisa <damir.perisa@bluewin.ch>
+
+pkgname=libgphoto2
+pkgver=2.4.13
+pkgrel=1
+pkgdesc="The core library of gphoto2, designed to allow access to digital camera by external programs."
+arch=(i686 x86_64)
+url="http://www.gphoto.org"
+license=(LGPL)
+depends=('libexif' 'libjpeg>=8' 'gd' 'libltdl' 'libusb-compat' 'libusb')
+install=libgphoto2.install
+options=('libtool')
+source=(http://downloads.sourceforge.net/gphoto/${pkgname}-${pkgver}.tar.gz)
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure \
+ --prefix=/usr \
+ --disable-rpath
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+
+ # Remove unused udev helper
+ rm -rf "${pkgdir}/usr/lib/udev"
+
+ install -m755 -d "${pkgdir}/lib/udev/rules.d"
+ LD_LIBRARY_PATH="${pkgdir}/usr/lib${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH" \
+ CAMLIBS="${pkgdir}/usr/lib/libgphoto2/${pkgver}" \
+ "${pkgdir}/usr/lib/libgphoto2/print-camera-list" udev-rules version 136 > \
+ "${pkgdir}/lib/udev/rules.d/40-gphoto.rules"
+
+ # Remove recursive symlink
+ rm -f "${pkgdir}/usr/include/gphoto2/gphoto2"
+}
+md5sums=('7d8a1d3ae02069af381f07a0bb4bfc15')
diff --git a/testing/libgphoto2/libgphoto2.install b/testing/libgphoto2/libgphoto2.install
new file mode 100644
index 000000000..c7944414f
--- /dev/null
+++ b/testing/libgphoto2/libgphoto2.install
@@ -0,0 +1,6 @@
+post_upgrade() {
+if [ "$(vercmp $2 2.14.13)" -lt 0 ]; then
+ groupdel camera &>/dev/null
+ echo "Users no longer need to be in the 'camera' group to use camera devices"
+fi
+}