summaryrefslogtreecommitdiffstats
path: root/python/gst-python3
diff options
context:
space:
mode:
Diffstat (limited to 'python/gst-python3')
-rw-r--r--python/gst-python3/fix-builds-with-python-3.8.patch43
-rw-r--r--python/gst-python3/gst-python3.SlackBuild29
-rw-r--r--python/gst-python3/gst-python3.info6
3 files changed, 63 insertions, 15 deletions
diff --git a/python/gst-python3/fix-builds-with-python-3.8.patch b/python/gst-python3/fix-builds-with-python-3.8.patch
new file mode 100644
index 0000000000..edff445a7a
--- /dev/null
+++ b/python/gst-python3/fix-builds-with-python-3.8.patch
@@ -0,0 +1,43 @@
+From 10707f437f2fc3632067c6a0efa4432f7ebaf362 Mon Sep 17 00:00:00 2001
+From: Sebastian Dröge <sebastian@centricular.com>
+Date: Fri, 13 Dec 2019 10:46:20 +0200
+Subject: [PATCH] backport of "fix build with Python 3.8 by also checking for
+ python-3.X-embed.pc"
+
+Since Python 3.8 the normal checks don't include the Python libraries
+anymore and linking of the gst-python module would fail.
+
+See also https://github.com/mesonbuild/meson/issues/5629
+
+Fixes https://gitlab.freedesktop.org/gstreamer/gst-python/issues/28
+
+Upstream commit: 22f28155d86e27c4134de4ed2861264003fcfd23
+
+Signed-off-by: Sebastian Dröge <sebastian@centricular.com>
+Signed-off-by: Adam Duskett <aduskett@gmail.com>
+---
+ meson.build | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/meson.build b/meson.build
+index 744b7ce..492af1a 100644
+--- a/meson.build
++++ b/meson.build
+@@ -25,6 +25,14 @@ pygobject_dep = dependency('pygobject-3.0', fallback: ['pygobject', 'pygobject_d
+ pymod = import('python')
+ python = pymod.find_installation(get_option('python'))
+ python_dep = python.dependency(required : true)
++pythonver = python.language_version()
++
++# Workaround for https://github.com/mesonbuild/meson/issues/5629
++# https://gitlab.freedesktop.org/gstreamer/gst-python/issues/28
++python_dep = dependency('python-@0@-embed'.format(pythonver), version: '>=3', required: false)
++if not python_dep.found()
++ python_dep = python.dependency(required : true)
++endif
+
+ python_abi_flags = python.get_variable('ABIFLAGS', '')
+ pylib_loc = get_option('libpython-dir')
+--
+2.24.1
+
diff --git a/python/gst-python3/gst-python3.SlackBuild b/python/gst-python3/gst-python3.SlackBuild
index a9c2d7eb42..08ebb64e98 100644
--- a/python/gst-python3/gst-python3.SlackBuild
+++ b/python/gst-python3/gst-python3.SlackBuild
@@ -25,7 +25,7 @@
PRGNAM=gst-python3
SRCNAM=gst-python
-VERSION=${VERSION:-1.6.2}
+VERSION=${VERSION:-1.16.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -71,18 +71,23 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-CFLAGS="$SLKCFLAGS" \
-./configure \
- --prefix=/usr \
- --libdir=/usr/lib${LIBDIRSUFFIX} \
- --build=$ARCH-slackware-linux \
- PYTHON=/usr/bin/python3
+patch -p1 < $CWD/fix-builds-with-python-3.8.patch
-make
-make install DESTDIR=$PKG
-
-# Remove the .la file to prevent conflicts with the python2 version of gst-python
-rm $PKG/usr/lib${LIBDIRSUFFIX}/gstreamer-1.0/libgstpythonplugin.la
+mkdir build
+cd build
+ CFLAGS="$SLKCFLAGS" \
+ CXXFLAGS="$SLKCFLAGS" \
+ meson .. \
+ --buildtype=release \
+ --infodir=/usr/info \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --localstatedir=/var \
+ --mandir=/usr/man \
+ --prefix=/usr \
+ --sysconfdir=/etc
+ ninja
+ DESTDIR=$PKG ninja install
+cd ..
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
diff --git a/python/gst-python3/gst-python3.info b/python/gst-python3/gst-python3.info
index 71b1372970..1837d4e1ea 100644
--- a/python/gst-python3/gst-python3.info
+++ b/python/gst-python3/gst-python3.info
@@ -1,8 +1,8 @@
PRGNAM="gst-python3"
-VERSION="1.6.2"
+VERSION="1.16.2"
HOMEPAGE="https://gstreamer.freedesktop.org/modules/gst-python.html"
-DOWNLOAD="https://gstreamer.freedesktop.org/src/gst-python/gst-python-1.6.2.tar.xz"
-MD5SUM="14b6cfe1a0db5cc01c6a58f7b4af6184"
+DOWNLOAD="https://gstreamer.freedesktop.org/src/gst-python/gst-python-1.16.2.tar.xz"
+MD5SUM="6ac709767334d8d0a71cb4e016f6abeb"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="python3"