[arch-commits] Commit in (zbar zbar/repos zbar/trunk zbar/trunk/PKGBUILD)

Felix Yan felixonmars at archlinux.org
Mon Aug 12 10:10:31 UTC 2019


    Date: Monday, August 12, 2019 @ 10:10:30
  Author: felixonmars
Revision: 359758

community2extra: Moving zbar from community to extra

Added:
  zbar/
  zbar/repos/
  zbar/trunk/
  zbar/trunk/PKGBUILD

----------+
 PKGBUILD |  102 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 102 insertions(+)

Added: zbar/trunk/PKGBUILD
===================================================================
--- zbar/trunk/PKGBUILD	                        (rev 0)
+++ zbar/trunk/PKGBUILD	2019-08-12 10:10:30 UTC (rev 359758)
@@ -0,0 +1,102 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Marti Raudsepp <marti at juffo.org>
+# Contributor: Radu Andries <admiral0 at tuxfamily.org>
+# Contributor: Andy Weidenbaum <archbaum at gmail.com>
+
+pkgbase=zbar
+pkgname=(zbar zbar-gtk zbar-qt python2-zbar)
+pkgver=0.23
+pkgrel=1
+pkgdesc="Application and library for reading bar codes from various sources"
+arch=('x86_64')
+url="https://github.com/mchehab/zbar"
+license=('LGPL')
+makedepends=('gtk3' 'libmagick' 'libxv' 'v4l-utils' 'qt5-x11extras' 'pygtk' 'python' 'xmlto' 'docbook-xsl')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/mchehab/zbar/archive/$pkgver.tar.gz")
+sha512sums=('bc2667a2a5a5f2e9fd3f39e57bf1d7f860b20a0b5faffc38791d222a6ff0414aff880295ce5ccb92acce7250503f2a7f48ac12651cf82cfb1933b302da26e393')
+
+build() {
+  cd zbar-$pkgver
+  autoreconf -vfi
+  PYTHON="/usr/bin/python2" \
+  ./configure --prefix=/usr --with-qt --with-gtk=gtk3 CFLAGS="$CFLAGS -DNDEBUG"
+  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
+  make
+}
+
+package_zbar() {
+  depends=('dbus' 'libmagick' 'libsm' 'libxv' 'v4l-utils')
+
+  cd zbar-$pkgver
+  make DESTDIR="$pkgdir" install
+
+  install -dm755 "$pkgdir"/usr/share/dbus-1/system.d
+  mv "$pkgdir"{/etc,/usr/share}/dbus-1/system.d/org.linuxtv.Zbar.conf
+
+  rm -r "$pkgdir"/usr/lib/libzbar{gtk,qt}.so* \
+        "$pkgdir"/usr/lib/*.a \
+        "$pkgdir"/usr/include/zbar/zbargtk.h \
+        "$pkgdir"/usr/include/zbar/QZBar*.h \
+        "$pkgdir"/usr/lib/pkgconfig/zbar-{gtk,qt}.pc \
+        "$pkgdir"/usr/lib/python2.7 \
+        "$pkgdir"/usr/bin/zbarcam-*
+
+  rmdir "$pkgdir"/etc{/dbus-1/system.d,/dbus-1,}
+}
+
+package_zbar-gtk() {
+  depends=('zbar' 'gtk3')
+
+  cd zbar-$pkgver
+  make DESTDIR="$pkgdir" install
+
+  mv "$pkgdir"/usr/include/zbar/zbargtk.h ./
+
+  rm -r "$pkgdir"/usr/lib/libzbar{,qt}.so* \
+        "$pkgdir"/usr/lib/*.a \
+        "$pkgdir"/usr/include/zbar/*.h \
+        "$pkgdir"/usr/include/zbar.h \
+        "$pkgdir"/usr/lib/pkgconfig/zbar{,-qt}.pc \
+        "$pkgdir"/usr/lib/python2.7 \
+        "$pkgdir"/usr/share \
+        "$pkgdir"/usr/bin/{zbarimg,zbarcam,zbarcam-qt} \
+        "$pkgdir"/etc
+
+  mv ./zbargtk.h "$pkgdir"/usr/include/zbar/
+}
+
+package_zbar-qt() {
+  depends=('zbar' 'qt5-x11extras')
+
+  cd zbar-$pkgver
+  make DESTDIR="$pkgdir" install
+
+  mv "$pkgdir"/usr/include/zbar/QZBar*.h ./
+
+  rm -r "$pkgdir"/usr/lib/libzbar{,gtk}.so* \
+        "$pkgdir"/usr/lib/*.a \
+        "$pkgdir"/usr/include/zbar/*.h \
+        "$pkgdir"/usr/include/zbar.h \
+        "$pkgdir"/usr/lib/pkgconfig/zbar{,-gtk}.pc \
+        "$pkgdir"/usr/lib/python2.7 \
+        "$pkgdir"/usr/share \
+        "$pkgdir"/usr/bin/{zbarimg,zbarcam,zbarcam-gtk} \
+        "$pkgdir"/etc
+
+  mv ./QZBar*.h "$pkgdir"/usr/include/zbar/
+}
+
+package_python2-zbar() {
+  depends=('zbar-gtk' 'pygtk')
+
+  cd zbar-$pkgver
+  make DESTDIR="$pkgdir" install
+
+  rm -r "$pkgdir"/usr/lib/*.so* \
+        "$pkgdir"/usr/include \
+        "$pkgdir"/usr/lib/pkgconfig \
+        "$pkgdir"/usr/{bin,share} \
+        "$pkgdir"/etc
+}
+
+# vim:set ts=2 sw=2 et:


More information about the arch-commits mailing list