[arch-commits] Commit in python-pg8000/repos/community-any (PKGBUILD PKGBUILD)

Chih-Hsuan Yen yan12125 at archlinux.org
Mon Feb 8 17:22:13 UTC 2021


    Date: Monday, February 8, 2021 @ 17:22:13
  Author: yan12125
Revision: 849441

archrelease: copy trunk to community-any

Added:
  python-pg8000/repos/community-any/PKGBUILD
    (from rev 849440, python-pg8000/trunk/PKGBUILD)
Deleted:
  python-pg8000/repos/community-any/PKGBUILD

----------+
 PKGBUILD |  109 +++++++++++++++++++++++++++++++------------------------------
 1 file changed, 56 insertions(+), 53 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2021-02-08 17:21:34 UTC (rev 849440)
+++ PKGBUILD	2021-02-08 17:22:13 UTC (rev 849441)
@@ -1,53 +0,0 @@
-# Maintainer: Chih-Hsuan Yen <yan12125 at archlinux.org>
-# Contributor: quomoow <quomoow at gmail.com>
-
-pkgname=python-pg8000
-pkgver=1.16.6
-pkgrel=3
-pkgdesc="Pure-Python PostgreSQL database driver, DB-API compatible"
-arch=(any)
-url='https://github.com/tlocke/pg8000'
-license=(BSD)
-makedepends=(python-setuptools)
-checkdepends=(python-pytest python-pytest-mock python-pytest-benchmark
-              python-pytz pifpaf postgresql)
-depends=(python python-scramp)
-source=("https://files.pythonhosted.org/packages/source/p/pg8000/pg8000-$pkgver.tar.gz"{,.asc})
-sha256sums=('8fc1e6a62ccb7c9830f1e7e9288e2d20eaf373cc8875b5c55b7d5d9b7717be91'
-            'SKIP')
-validpgpkeys=(
-  'D5681B7EC7292511C4CC1450892B00AB699851E8'  # Tony Locke <tlocke at tlocke.org.uk>, proven by https://keybase.io/tlocke
-)
-
-prepare() {
-  cd pg8000-$pkgver
-
-  # Remove upper bounds of dependencies
-  sed --in-place=.orig -r 's#,?<[0-9.]+,?##;s#==([0-9.]+)#>=\1#' setup.py
-  diff -u setup.py{.orig,} || true
-}
-
-build() {
-  cd pg8000-$pkgver
-  python setup.py build
-}
-
-check() {
-  cd pg8000-$pkgver
-  # See upstream .travis.yml for initialization SQL commands
-  # XXX: The postgres plugin in pifpaf does not listen on a TCP port
-  #      without --host
-  # XXX: testGss and testSsl needs custom pg_hba.conf and postgresql.conf,
-  #      and pifpaf does not support that yet
-  PYTHONPATH="$PWD" pifpaf run postgresql --host localhost -- bash -c "
-    psql -c \"CREATE ROLE postgres WITH LOGIN SUPERUSER PASSWORD 'pw';\"
-    psql -c \"create extension hstore;\"
-    pytest -v test -k 'not testGss and not testSsl'
-  "
-}
-
-package() {
-  cd pg8000-$pkgver
-  python setup.py install --root="$pkgdir" --optimize=1 --skip-build
-  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
-}

Copied: python-pg8000/repos/community-any/PKGBUILD (from rev 849440, python-pg8000/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2021-02-08 17:22:13 UTC (rev 849441)
@@ -0,0 +1,56 @@
+# Maintainer: Chih-Hsuan Yen <yan12125 at archlinux.org>
+# Contributor: quomoow <quomoow at gmail.com>
+
+pkgname=python-pg8000
+pkgver=1.17.0
+pkgrel=1
+pkgdesc="Pure-Python PostgreSQL database driver, DB-API compatible"
+arch=(any)
+url='https://github.com/tlocke/pg8000'
+license=(BSD)
+makedepends=(python-setuptools)
+checkdepends=(python-pytest python-pytest-mock python-pytest-benchmark
+              python-pytz pifpaf postgresql)
+depends=(python python-scramp)
+source=("https://files.pythonhosted.org/packages/source/p/pg8000/pg8000-$pkgver.tar.gz"{,.asc}
+        pghost-unix-sock.patch::https://github.com/tlocke/pg8000/pull/64.patch)
+sha256sums=('14198c5afeb289106e40ee6e5e4c0529c5369939f6ca588a028b371a75fe20dd'
+            'SKIP'
+            '0a851dbbc0f8d0116795eb0d875e9178659bdf7c6964bff8b26c6b014c37e9c9')
+validpgpkeys=(
+  'D5681B7EC7292511C4CC1450892B00AB699851E8'  # Tony Locke <tlocke at tlocke.org.uk>, proven by https://keybase.io/tlocke
+)
+
+prepare() {
+  cd pg8000-$pkgver
+
+  # Remove upper bounds of dependencies
+  sed --in-place=.orig -r 's#,?<[0-9.]+,?##;s#==([0-9.]+)#>=\1#' setup.py
+  diff -u setup.py{.orig,} || true
+
+  patch -Np1 -i ../pghost-unix-sock.patch
+}
+
+build() {
+  cd pg8000-$pkgver
+  python setup.py build
+}
+
+check() {
+  cd pg8000-$pkgver
+  # GSS tests: need custom pg_hba.conf, while pifpaf does not support it yet
+  # SSL tests: need TCP connections [1][2], while pifpaf uses unix domain sockets
+  # [1] https://github.com/postgres/postgres/blob/REL_13_1/src/backend/postmaster/postmaster.c#L2027
+  # [2] https://www.postgresql.org/message-id/flat/200801041713.22341.peter_e%40gmx.net
+  PYTHONPATH="$PWD" pifpaf run postgresql -- bash -c "
+    psql -c \"CREATE ROLE postgres WITH LOGIN SUPERUSER PASSWORD 'pw';\"
+    psql -c \"create extension hstore;\"
+    pytest test -k 'not testGss and not test_gss and not testSsl and not test_ssl'
+  "
+}
+
+package() {
+  cd pg8000-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1 --skip-build
+  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
+}



More information about the arch-commits mailing list