diff --git a/packages/graphene/build.sh b/packages/graphene/build.sh index 9ff05a292d..4178ab9a97 100644 --- a/packages/graphene/build.sh +++ b/packages/graphene/build.sh @@ -4,11 +4,33 @@ TERMUX_PKG_LICENSE="MIT" TERMUX_PKG_MAINTAINER="@termux" _MAJOR_VERSION=1.10 TERMUX_PKG_VERSION=${_MAJOR_VERSION}.8 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://download.gnome.org/sources/graphene/${_MAJOR_VERSION}/graphene-${TERMUX_PKG_VERSION}.tar.xz TERMUX_PKG_SHA256=a37bb0e78a419dcbeaa9c7027bcff52f5ec2367c25ec859da31dfde2928f279a TERMUX_PKG_DEPENDS="glib" +TERMUX_PKG_BUILD_DEPENDS="g-ir-scanner" TERMUX_PKG_CONFLICTS="gst-plugins-base (<< 1.20.3-1)" TERMUX_PKG_BREAKS="gst-plugins-base (<< 1.20.3-1)" +TERMUX_PKG_DISABLE_GIR=false TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" --Dintrospection=disabled +-Dintrospection=enabled " + +termux_step_pre_configure() { + termux_setup_gir + + if [ "$TERMUX_ON_DEVICE_BUILD" = "false" ]; then + local pywrap="$TERMUX_PKG_BUILDDIR/_bin/python-wrapper" + mkdir -p "$(dirname "$pywrap")" + cat > "$pywrap" <<-EOF + #!/bin/bash-static + unset LD_LIBRARY_PATH + exec /usr/bin/python3 "\$@" + EOF + chmod 0700 "$pywrap" + echo "Applying wrap-python.diff" + sed -e "s|@PYTHON_WRAPPER@|${pywrap}|g" \ + "$TERMUX_PKG_BUILDER_DIR/wrap-python.diff" \ + | patch --silent -p1 -d "$TERMUX_PKG_SRCDIR" + fi +} diff --git a/packages/graphene/gir/1.10.8/Graphene-1.0.xml b/packages/graphene/gir/1.10.8/Graphene-1.0.xml new file mode 100644 index 0000000000..b0908046e4 --- /dev/null +++ b/packages/graphene/gir/1.10.8/Graphene-1.0.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/packages/graphene/wrap-python.diff b/packages/graphene/wrap-python.diff new file mode 100644 index 0000000000..187cbddcb3 --- /dev/null +++ b/packages/graphene/wrap-python.diff @@ -0,0 +1,11 @@ +--- a/src/meson.build ++++ b/src/meson.build +@@ -101,7 +101,7 @@ + identfilter_py = join_paths(meson.current_source_dir(), 'identfilter.py') + + gir_extra_args = [ +- '--identifier-filter-cmd=@0@ @1@'.format(python.full_path(), identfilter_py), ++ '--identifier-filter-cmd=@0@ @1@'.format('@PYTHON_WRAPPER@', identfilter_py), + '--accept-unprefixed', + '--quiet', + '--warn-all',