[packages/jhbuild] Rel 7; builds with python 3.13
arekm
arekm at pld-linux.org
Sat May 24 20:23:26 CEST 2025
commit 695f9f718b90a62e0318d88cf498c3a887047146
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Sat May 24 20:09:34 2025 +0200
Rel 7; builds with python 3.13
build.patch | 46 ++++++++++++++++++++++++++++++++++++++++++++++
jhbuild.spec | 4 +++-
2 files changed, 49 insertions(+), 1 deletion(-)
---
diff --git a/jhbuild.spec b/jhbuild.spec
index 41683c0..89f7914 100644
--- a/jhbuild.spec
+++ b/jhbuild.spec
@@ -2,11 +2,12 @@ Summary: Tool to ease building collections of source packages
Summary(pl.UTF-8): Narzędzie ułatwiające budowanie zbioru pakietów źródłowych
Name: jhbuild
Version: 3.38.0
-Release: 6
+Release: 7
License: GPL v2+
Group: Development/Tools
Source0: http://ftp.gnome.org/pub/GNOME/sources/jhbuild/3.38/%{name}-%{version}.tar.xz
# Source0-md5: 8621b7757fe0d4e04a66183a380d8f10
+Patch0: build.patch
URL: https://wiki.gnome.org/Projects/Jhbuild
BuildRequires: gettext-tools >= 0.19.6
BuildRequires: pkgconfig
@@ -36,6 +37,7 @@ projektami.
%prep
%setup -q
+%patch -P0 -p1
%{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},' scripts/hg-update.py
%{__sed} -i -e '1s,/usr/bin/env @python@,%{__python3},' scripts/jhbuild.in
diff --git a/build.patch b/build.patch
new file mode 100644
index 0000000..072985b
--- /dev/null
+++ b/build.patch
@@ -0,0 +1,46 @@
+--- jhbuild-3.38.0/build-aux/py-compile~ 2020-09-12 17:26:52.000000000 +0200
++++ jhbuild-3.38.0/build-aux/py-compile 2025-05-24 20:07:27.671767908 +0200
+@@ -116,7 +116,7 @@ else
+ fi
+
+ $PYTHON -c "
+-import sys, os, py_compile, imp
++import sys, os, py_compile, importlib.util
+
+ files = '''$files'''
+
+@@ -129,15 +129,16 @@ for file in files.split():
+ continue
+ sys.stdout.write(file)
+ sys.stdout.flush()
+- if hasattr(imp, 'get_tag'):
+- py_compile.compile(filepath, imp.cache_from_source(filepath), path)
++ if hasattr(importlib.util, 'cache_from_source'):
++ py_compile.compile(filepath, importlib.util.cache_from_source(filepath), path)
+ else:
+- py_compile.compile(filepath, filepath + 'c', path)
++ py_compile.compile(filepath, filepath + 'c', path)
+ sys.stdout.write('\n')" || exit $?
+
+ # this will fail for python < 1.5, but that doesn't matter ...
+ $PYTHON -O -c "
+-import sys, os, py_compile, imp
++import sys, os, py_compile
++import importlib.util
+
+ # pypy does not use .pyo optimization
+ if hasattr(sys, 'pypy_translation_info'):
+@@ -153,10 +154,10 @@ for file in files.split():
+ continue
+ sys.stdout.write(file)
+ sys.stdout.flush()
+- if hasattr(imp, 'get_tag'):
+- py_compile.compile(filepath, imp.cache_from_source(filepath, False), path)
++ if hasattr(importlib.util, 'cache_from_source'):
++ py_compile.compile(filepath, importlib.util.cache_from_source(filepath, False), path)
+ else:
+- py_compile.compile(filepath, filepath + 'o', path)
++ py_compile.compile(filepath, filepath + 'o', path)
+ sys.stdout.write('\n')" 2>/dev/null || :
+
+ # Local Variables:
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/jhbuild.git/commitdiff/695f9f718b90a62e0318d88cf498c3a887047146
More information about the pld-cvs-commit
mailing list