From 0b3ee6169e9e23af8fc98bffd85b27eeb206e1ca Mon Sep 17 00:00:00 2001 From: EnumDev Date: Wed, 6 May 2026 15:25:34 +0300 Subject: [PATCH] Rebuild with python 3.14 --- check-version.sh | 15 +++++++++++++++ pkg.info | 25 ++++++++++++++++++++++--- source.sh | 26 +++++--------------------- 3 files changed, 42 insertions(+), 24 deletions(-) create mode 100644 check-version.sh diff --git a/check-version.sh b/check-version.sh new file mode 100644 index 0000000..95e5e5b --- /dev/null +++ b/check-version.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +# Gitlab repository +REPO="dbus/dbus-python" + +# Replace slash with URL encoded representation +REPO=$(echo "$REPO" | sed 's|/|%2F|g') + +# Get tag name using Gitlab Rest API +TAG_NAME=$(curl -s -L https://gitlab.freedesktop.org/api/v4/projects/"$REPO"/repository/tags | jq -r '.[0].name') + +# Trim suffix +VERSION=${TAG_NAME//dbus-python-/} + +echo "$VERSION" diff --git a/pkg.info b/pkg.info index ebc3bc5..8f89dae 100644 --- a/pkg.info +++ b/pkg.info @@ -1,10 +1,29 @@ name: python-dbus description: Libdbus language binding (wrapper) for CPython version: 1.4.0 +revision: 2 url: https://pypi.org/project/dbus-python/ license: MIT +maintainers: + - enumdev@enumerated.dev architecture: any -depends: ["dbus","glib","glibc","python3"] -optional_depends: ["python-pygobject"] -make_depends: ["meson","python-pygobject"] type: source +depends: + - dbus + - glib + - glibc + - python3=3.14.* +optional_depends: + - python-pygobject:For D-Bus services via PyGi +make_depends: + - meson + - python-pygobject + - python-pyproject-metadata + - python-sphinx + - python-sphinx_rtd_theme + - python-sphinxcontrib-jquery +downloads: + - url: https://gitlab.freedesktop.org/dbus/dbus-python/-/archive/dbus-python-${BPM_PKG_VERSION}/dbus-python-dbus-python-${BPM_PKG_VERSION}.tar.gz + extract_to: ${BPM_SOURCE} + extract_strip_components: 1 + checksum: da4ee9bbb9eb901d463a7cc9f99dfdbe6c751c8b48b29b78d378985a3c9656ad diff --git a/source.sh b/source.sh index 6fd5588..f243776 100644 --- a/source.sh +++ b/source.sh @@ -2,40 +2,24 @@ # BPM Expects the source code to be extracted into the automatically created 'source' directory which can be accessed using $BPM_SOURCE # BPM Expects the output files to be present in the automatically created 'output' directory which can be accessed using $BPM_OUTPUT -DOWNLOAD="https://gitlab.freedesktop.org/dbus/dbus-python/-/archive/dbus-python-${BPM_PKG_VERSION}/dbus-python-dbus-python-${BPM_PKG_VERSION}.tar.gz" -FILENAME="${DOWNLOAD##*/}" - -# The prepare function is executed in the root of the temp directory -# This function is used for downloading files and putting them into the correct location -prepare() { - wget "$DOWNLOAD" - tar -xvf "$FILENAME" --strip-components=1 -C "$BPM_SOURCE" -} - # The build function is executed in the source directory # This function is used to compile the source code build() { - mkdir build - cd build - - meson setup --prefix=/usr -Ddoc=disabled - meson compile + meson setup build --prefix=/usr -Ddoc=enabled + meson compile -C build } # The check function is executed in the source directory # This function is used to run tests to verify the package has been compiled correctly check() { - cd build - - meson test + meson test -C build } # The package function is executed in the source directory # This function is used to move the compiled files into the output directory package() { - cd build - - meson install --destdir="$BPM_OUTPUT" + meson install -C build --destdir="$BPM_OUTPUT" + # Install package license install -Dm644 "$BPM_SOURCE"/COPYING "$BPM_OUTPUT"/usr/share/licenses/python-dbus/COPYING }