Date: Sunday, November 3, 2019 @ 10:02:56
  Author: arojas
Revision: 522421

Restore python2 version, it is still needed by some packages

Modified:
  python-psycopg2/trunk/PKGBUILD

----------+
 PKGBUILD |   21 ++++++++++++++++-----
 1 file changed, 16 insertions(+), 5 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2019-11-03 09:29:36 UTC (rev 522420)
+++ PKGBUILD    2019-11-03 10:02:56 UTC (rev 522421)
@@ -4,15 +4,16 @@
 # Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve>
 # Contributor: Douglas Soares de Andrade <d...@aur.archlinux.org>
 
-pkgname=python-psycopg2
+pkgbase=python-psycopg2
+pkgname=('python-psycopg2' 'python2-psycopg2')
 pkgver=2.8.4
-pkgrel=2
+pkgrel=3
 pkgdesc="A PostgreSQL database adapter for the Python programming language."
 arch=('x86_64')
 url="http://initd.org/psycopg/";
 license=('LGPL3')
-depends=('python' 'postgresql-libs')
-makedepends=('python-setuptools' 'postgresql-libs')
+makedepends=('python2' 'python2-setuptools'
+             'python' 'python-setuptools' 'postgresql-libs')
 
source=(http://initd.org/psycopg/tarballs/PSYCOPG-2-8/psycopg2-$pkgver.tar.gz{,.asc})
 validpgpkeys=('8AD609956CF1899418E19A856013BD3AFCF957DE')
 
sha512sums=('d4590c6e4e310d280b6b341cb23427b56b04c1ef08e877f0d99a79c6b00b959307bb18defaf1d9cea58482fb974a78760c5f26a3ece8c1f34ae1840570a71a28'
@@ -21,9 +22,19 @@
   cd "$srcdir/psycopg2-$pkgver"
   sed -i 's/,PSYCOPG_DEBUG$//' setup.cfg
   python setup.py build
+  python2 setup.py build
 }
 
-package() {
+package_python-psycopg2() {
+  depends=('python' 'postgresql-libs')
+
   cd "$srcdir/psycopg2-$pkgver"
   python setup.py install --root="$pkgdir" --optimize=1 --skip-build
 }
+
+package_python2-psycopg2() {
+  depends=('python2' 'postgresql-libs')
+
+  cd "$srcdir/psycopg2-$pkgver"
+  python2 setup.py install --root="$pkgdir" --optimize=1 --skip-build
+}

Reply via email to