add gst-python
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
From 57d1f7e6b49149dd0f48ce9c5891f499ab689925 Mon Sep 17 00:00:00 2001
|
||||
From: Lubosz Sarnecki <lubosz@gmail.com>
|
||||
Date: Thu, 31 Jul 2014 11:50:50 +0200
|
||||
Subject: [PATCH 1/2] msys2: python3-config returns 1, so use which
|
||||
|
||||
---
|
||||
acinclude.m4 | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/acinclude.m4 b/acinclude.m4
|
||||
index c0d1a5e..4ecce7e 100644
|
||||
--- a/acinclude.m4
|
||||
+++ b/acinclude.m4
|
||||
@@ -45,7 +45,7 @@ AC_MSG_CHECKING(for headers required to compile python extensions)
|
||||
dnl deduce PYTHON_INCLUDES
|
||||
py_prefix=`$PYTHON -c "import sys; print(sys.prefix)"`
|
||||
py_exec_prefix=`$PYTHON -c "import sys; print(sys.exec_prefix)"`
|
||||
-if $PYTHON-config --help 1>/dev/null 2>/dev/null; then
|
||||
+if which $PYTHON-config; then
|
||||
PYTHON_INCLUDES=`$PYTHON-config --includes 2>/dev/null`
|
||||
if $PYTHON-config --abiflags 1>/dev/null 2>/dev/null; then
|
||||
PYTHON_ABI_FLAGS=`$PYTHON-config --abiflags 2>/dev/null`
|
||||
--
|
||||
2.0.4
|
||||
|
||||
43
mingw-w64-gst-python/0002-msys2-fix-linking-errors.patch
Normal file
43
mingw-w64-gst-python/0002-msys2-fix-linking-errors.patch
Normal file
@@ -0,0 +1,43 @@
|
||||
From 835e75d3e98a2860ffec1ffb4e4969a90efdee66 Mon Sep 17 00:00:00 2001
|
||||
From: Lubosz Sarnecki <lubosz@gmail.com>
|
||||
Date: Thu, 31 Jul 2014 12:32:21 +0200
|
||||
Subject: [PATCH 2/2] msys2: fix linking errors
|
||||
|
||||
* add python lib manually
|
||||
* fix libtool error: add no-undefined flag
|
||||
* add glib libs
|
||||
* add gmodule library manually
|
||||
---
|
||||
gi/overrides/Makefile.am | 4 ++--
|
||||
plugin/Makefile.am | 4 ++--
|
||||
2 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/gi/overrides/Makefile.am b/gi/overrides/Makefile.am
|
||||
index ee94f7c..4f04707 100644
|
||||
--- a/gi/overrides/Makefile.am
|
||||
+++ b/gi/overrides/Makefile.am
|
||||
@@ -1,6 +1,6 @@
|
||||
common_cflags = $(PYGOBJECT_CFLAGS) $(GST_CFLAGS) -fno-strict-aliasing
|
||||
-common_libadd = $(GST_LIBS) $(PYGOBJECT_LIBS)
|
||||
-common_ldflags = -module -avoid-version -shrext $(PYTHON_SO)
|
||||
+common_libadd = $(GST_LIBS) $(PYGOBJECT_LIBS) -lpython3.4m
|
||||
+common_ldflags = -module -avoid-version -no-undefined -shrext $(PYTHON_SO)
|
||||
|
||||
# We install everything in the gi/overrides folder
|
||||
pygioverridesdir = $(PYGI_OVERRIDES_DIR)
|
||||
diff --git a/plugin/Makefile.am b/plugin/Makefile.am
|
||||
index 042c2bc..4a9b60d 100644
|
||||
--- a/plugin/Makefile.am
|
||||
+++ b/plugin/Makefile.am
|
||||
@@ -8,6 +8,6 @@ INCLUDES = $(PYGOBJECT_CFLAGS) $(GST_CFLAGS)\
|
||||
$(PYTHON_INCLUDES)
|
||||
|
||||
libgstpythonplugin_la_SOURCES = gstpythonplugin.c
|
||||
-libgstpythonplugin_la_LDFLAGS = -avoid-version
|
||||
-libgstpythonplugin_la_LIBADD = $(PYTHON_LIBS) $(PYGOBJECT_LIBS) $(GST_LIBS)
|
||||
+libgstpythonplugin_la_LDFLAGS = -avoid-version -no-undefined
|
||||
+libgstpythonplugin_la_LIBADD = $(PYTHON_LIBS) $(PYGOBJECT_LIBS) $(GST_LIBS) -lgmodule-2.0
|
||||
libgstpythonplugin_la_CFLAGS = $(GST_CFLAGS) $(PYGOBJECT_CFLAGS) $(GST_PLUGINS_BASE_CFLAGS) $(PYTHON_INCLUDES)
|
||||
--
|
||||
2.0.4
|
||||
|
||||
59
mingw-w64-gst-python/PKGBUILD
Normal file
59
mingw-w64-gst-python/PKGBUILD
Normal file
@@ -0,0 +1,59 @@
|
||||
# Maintainer: Lubosz Sarnecki <lubosz@gmail.com>
|
||||
|
||||
_name=gst-python
|
||||
|
||||
pkgname="${MINGW_PACKAGE_PREFIX}-${_name}-git"
|
||||
|
||||
pkgver=1.3.0.1.1283.3483187
|
||||
pkgrel=1
|
||||
pkgdesc='GStreamer GObject Introspection overrides for Python 3'
|
||||
arch=('any')
|
||||
license=('LGPL')
|
||||
depends=("${MINGW_PACKAGE_PREFIX}-gstreamer"
|
||||
"${MINGW_PACKAGE_PREFIX}-python3"
|
||||
"${MINGW_PACKAGE_PREFIX}-gobject-introspection")
|
||||
url='http://gstreamer.freedesktop.org/modules/gst-python.html'
|
||||
|
||||
provides=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
||||
conflicts=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
||||
|
||||
options=(!libtool strip staticlibs)
|
||||
|
||||
source=("git://anongit.freedesktop.org/gstreamer/${_name}"
|
||||
'0001-msys2-python3-config-returns-1-so-use-which.patch'
|
||||
'0002-msys2-fix-linking-errors.patch')
|
||||
md5sums=('SKIP'
|
||||
'eb52a3ef8270c2d263c79799bcaf377a'
|
||||
'a1d96c7bf521664a76d424c1b9250ea8')
|
||||
|
||||
pkgver() {
|
||||
cd $_name
|
||||
version=$(grep AC_INIT configure.ac | sed 's/AC_INIT(GStreamer GObject Introspection overrides for Python , //' | sed 's/,//')
|
||||
hash=$(git log --pretty=format:'%h' -n 1)
|
||||
revision=$(git rev-list --count HEAD)
|
||||
echo $version.$revision.$hash
|
||||
}
|
||||
|
||||
prepare() {
|
||||
cd $_name
|
||||
git am ../0001-msys2-python3-config-returns-1-so-use-which.patch
|
||||
git am ../0002-msys2-fix-linking-errors.patch
|
||||
NOCONFIGURE=1 ./autogen.sh
|
||||
}
|
||||
|
||||
build() {
|
||||
cd $_name
|
||||
PYTHON=${MINGW_PREFIX}/bin/python3 \
|
||||
./autogen.sh --prefix=${MINGW_PREFIX} \
|
||||
--build=${MINGW_CHOST} \
|
||||
--host=${MINGW_CHOST} \
|
||||
--target=${MINGW_CHOST} \
|
||||
--disable-silent-rules
|
||||
make
|
||||
}
|
||||
|
||||
package() {
|
||||
cd $_name
|
||||
make DESTDIR="$pkgdir" install
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user