public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jitka Plesnikova <jplesnik@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/mupdf] rawhide: Replace removed Python 2 C API macros for SWIG 4.5.0 compatibility
Date: Fri, 31 Jul 2026 09:03:30 GMT [thread overview]
Message-ID: <178548861097.1.4290633158296234865.rpms-mupdf-398a6d897744@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/mupdf
Branch : rawhide
Commit : 398a6d8977441313ca5bb152c0c54c3007887d63
Author : Jitka Plesnikova <jplesnik@redhat.com>
Date : 2026-07-28T15:29:18+02:00
Stats : +15/-0 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/mupdf/c/398a6d8977441313ca5bb152c0c54c3007887d63?branch=rawhide
Log:
Replace removed Python 2 C API macros for SWIG 4.5.0 compatibility
---
diff --git a/mupdf-swig45.patch b/mupdf-swig45.patch
new file mode 100644
index 0000000..53ca2f1
--- /dev/null
+++ b/mupdf-swig45.patch
@@ -0,0 +1,12 @@
+diff -up mupdf-1.27.2-source/scripts/wrap/swig.py.swig45 mupdf-1.27.2-source/scripts/wrap/swig.py
+--- mupdf-1.27.2-source/scripts/wrap/swig.py.swig45 2026-07-28 09:53:02.845224055 +0200
++++ mupdf-1.27.2-source/scripts/wrap/swig.py 2026-07-28 09:53:02.851224187 +0200
+@@ -738,7 +738,7 @@ def build_swig(
+ {
+ message += "Traceback (from traceback.format_tb()):\\n";
+ PyObject* traceback_dict = PyModule_GetDict(traceback);
+- PyObject* format_tb = PyDict_GetItem(traceback_dict, PyString_FromString("format_tb"));
++ PyObject* format_tb = PyDict_GetItem(traceback_dict, PyUnicode_FromString("format_tb"));
+ PyObject* ret = PyObject_CallFunctionObjArgs(format_tb, trace, NULL);
+ PyObject* iter = PyObject_GetIter(ret);
+ for(;;)
diff --git a/mupdf.spec b/mupdf.spec
index 4d3df7b..8f48d52 100644
--- a/mupdf.spec
+++ b/mupdf.spec
@@ -46,6 +46,9 @@ Patch: 0001-do-not-use-CXXFLAGS-with-swig.patch
Patch: 0001-pdf_font-report-font-name-in-warning.patch
# Upstreamable:
Patch: 0001-mupdfwrap_test-adjust-to-mupdf-1.27.x.patch
+# Replace removed Python 2 C API macros with Python 3 equivalents
+# for compatibility with SWIG 4.5.0
+Patch: mupdf-swig45.patch
BuildRequires: gcc gcc-c++ make binutils desktop-file-utils coreutils pkgconfig
BuildRequires: openjpeg2-devel desktop-file-utils
reply other threads:[~2026-07-31 9:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=178548861097.1.4290633158296234865.rpms-mupdf-398a6d897744@fedoraproject.org \
--to=jplesnik@redhat.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox