summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Sun2019-11-15 21:28:22 -0500
committerAndrew Sun2019-11-15 21:28:22 -0500
commitb16577a74c044dc2f6bf696eccb464c41080d703 (patch)
treea3fbab19ef5907e180d5359829b3b5cf6d249ad8
parent81061f3f3e08180874ed389bad0221d2a3f4baa8 (diff)
downloadaur-b16577a74c044dc2f6bf696eccb464c41080d703.tar.gz
python 3.8 fix
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD10
-rw-r--r--python38-fix.patch13
3 files changed, 23 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index a68f87dc8a78..a6ad4295a8b3 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -16,7 +16,9 @@ pkgbase = clingo
depends = python
conflicts = clasp
source = git+https://github.com/potassco/clingo#tag=v5.4.0
+ source = python38-fix.patch
sha256sums = SKIP
+ sha256sums = 782d9fa710e59cba36bc3bfb922d52de0469cd3d0c5c591308f8e459139bd72f
pkgname = clingo
diff --git a/PKGBUILD b/PKGBUILD
index 1f90c751b42a..7576d167acc4 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -12,11 +12,17 @@ license=('MIT')
depends=('lua' 'python')
makedepends=('clang' 'cmake' 'git' 'ninja' 're2c')
conflicts=('clasp')
-source=("git+https://github.com/potassco/clingo#tag=v${pkgver}")
-sha256sums=('SKIP')
+source=("git+https://github.com/potassco/clingo#tag=v${pkgver}"
+ "python38-fix.patch")
+sha256sums=('SKIP'
+ '782d9fa710e59cba36bc3bfb922d52de0469cd3d0c5c591308f8e459139bd72f')
prepare() {
sed '/#include <xlocale.h>/d' -i "${srcdir}"/clingo/clasp/libpotassco/src/string_convert.cpp
+
+ cd "${srcdir}/${pkgname}"
+ # Upstream patch
+ patch -Np1 -i "${srcdir}/python38-fix.patch"
}
build() {
diff --git a/python38-fix.patch b/python38-fix.patch
new file mode 100644
index 000000000000..6593a5764766
--- /dev/null
+++ b/python38-fix.patch
@@ -0,0 +1,13 @@
+diff --git a/libpyclingo/pyclingo.cc b/libpyclingo/pyclingo.cc
+index 9480203..6a7068c 100644
+--- a/libpyclingo/pyclingo.cc
++++ b/libpyclingo/pyclingo.cc
+@@ -1177,7 +1177,7 @@ PyTypeObject ObjectBase<T>::type = {
+ sizeof(T), // tp_basicsize
+ 0, // tp_itemsize
+ PythonDetail::Get_tp_dealloc<T>::value, // tp_dealloc
+- nullptr, // tp_print
++ 0, // tp_print
+ nullptr, // tp_getattr
+ nullptr, // tp_setattr
+ nullptr, // tp_compare