Fedora Account System
Red Hat Associate
Red Hat Customer
python-crypto fails to build with Python 3.12.0a6. src/_fastmath.c: In function ‘longObjToMPZ’: src/_fastmath.c:73:23: error: ‘PyObject’ {aka ‘struct _object’} has no member named ‘ob_size’ 73 | if (p->ob_base.ob_size > 0) { | ^ src/_fastmath.c:74:34: error: ‘PyObject’ {aka ‘struct _object’} has no member named ‘ob_size’ 74 | size = p->ob_base.ob_size; | ^ src/_fastmath.c:77:35: error: ‘PyObject’ {aka ‘struct _object’} has no member named ‘ob_size’ 77 | size = -p->ob_base.ob_size; | ^ src/_fastmath.c:92:36: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 92 | mpz_set_ui (temp, p->ob_digit[i]); | ^~ src/_fastmath.c: In function ‘mpzToLongObj’: src/_fastmath.c:126:18: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 126 | l->ob_digit[i] = (digit) (mpz_get_ui (temp) & PyLong_MASK); | ^~ src/_fastmath.c:134:29: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 134 | while ((i > 0) && (l->ob_digit[i - 1] == 0)) | ^~ src/_fastmath.c:137:19: error: ‘PyObject’ {aka ‘struct _object’} has no member named ‘ob_size’ 137 | l->ob_base.ob_size = i * sgn; | ^ src/_fastmath.c: In function ‘rabinMillerTest’: src/_fastmath.c:1371:57: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare] 1371 | if (mpz_fits_ulong_p (n) && (mpz_get_ui (n) - 2 < rounds)) | ^ src/_fastmath.c:1373:23: warning: comparison of integer expressions of different signedness: ‘long unsigned int’ and ‘int’ [-Wsign-compare] 1373 | for (i = 0; i < rounds; ++i) | ^ error: command '/usr/bin/gcc' failed with exit code 1 https://github.com/python/cpython/pull/101292 https://docs.python.org/3.12/whatsnew/3.12.html For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.12/fedora-rawhide-x86_64/05623654-python-crypto/ For all our attempts to build python-crypto with Python 3.12, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.12/package/python-crypto/ Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.12: https://copr.fedorainfracloud.org/coprs/g/python/python3.12/ Let us know here if you have any questions. Python 3.12 is planned to be included in Fedora 39. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.12. A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon. We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.
FEDORA-2023-545bf49913 has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-545bf49913
The new build works with Python 3.12 for me in mock (x86_64). I'd really rather see this package retired, but a few of its dependents are still outstanding: python-bucky: Upstream switched to cryptography in 2017 but there has been no new release since then. https://bugzilla.redhat.com/show_bug.cgi?id=2061786 python-onionbalance: Upstream already switched to pycryptodomex, dependencies are wrong. The build dependency was fixed but the runtime one is still there. https://bugzilla.redhat.com/show_bug.cgi?id=2061839 winpdb: Should be trivially changed to use pycryptodomex, only uses DES. https://bugzilla.redhat.com/show_bug.cgi?id=2061881
FEDORA-2023-545bf49913 has been pushed to the Fedora 39 stable repository. If problem still persists, please make note of it in this bug report.