Bug 2245787 - python-alsaaudio fails to build with Python 3.13: error: implicit declaration of function ‘PyEval_InitThreads’, 'PyUnicode_AS_DATA'
Summary: python-alsaaudio fails to build with Python 3.13: error: implicit declaration...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: python-alsaaudio
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Peter Robinson
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2023-10-24 07:33 UTC by Karolina Surma
Modified: 2023-12-29 01:13 UTC (History)
4 users (show)

Fixed In Version: python-alsaaudio-0.10.0-1.fc38 python-alsaaudio-0.10.0-1.fc39
Clone Of:
Environment:
Last Closed: 2023-12-29 01:04:13 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Karolina Surma 2023-10-24 07:33:20 UTC
python-alsaaudio fails to build with Python 3.13.0a1.

alsaaudio.c: In function ‘get_pcmtype’:
alsaaudio.c:172:38: error: implicit declaration of function ‘PyUnicode_AS_DATA’; did you mean ‘PyUnicode_DATA’? [-Werror=implicit-function-declaration]
  172 |                 const char *dirstr = PyUnicode_AS_DATA(obj);
      |                                      ^~~~~~~~~~~~~~~~~
      |                                      PyUnicode_DATA
alsaaudio.c:172:38: warning: initialization of ‘const char *’ from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
alsaaudio.c: In function ‘PyInit_alsaaudio’:
alsaaudio.c:2772:9: error: implicit declaration of function ‘PyEval_InitThreads’; did you mean ‘PyEval_SaveThread’? [-Werror=implicit-function-declaration]
 2772 |         PyEval_InitThreads();
      |         ^~~~~~~~~~~~~~~~~~
      |         PyEval_SaveThread
cc1: some warnings being treated as errors

According to https://docs.python.org/3.13/whatsnew/3.13.html:

Remove PyEval_InitThreads() and PyEval_ThreadsInitialized() functions, deprecated in Python 3.9. Since Python 3.7, Py_Initialize() always creates the GIL:
calling PyEval_InitThreads() did nothing and PyEval_ThreadsInitialized() always returned non-zero.
(Contributed by Victor Stinner in https://github.com/python/cpython/issues/105182.)


https://docs.python.org/3.13/whatsnew/3.13.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.13/fedora-rawhide-x86_64/06546761-python-alsaaudio/

For all our attempts to build python-alsaaudio with Python 3.13, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.13/package/python-alsaaudio/

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.13:
https://copr.fedorainfracloud.org/coprs/g/python/python3.13/

Let us know here if you have any questions.

Python 3.13 is planned to be included in Fedora 41.
To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.13.
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.

Comment 1 Fedora Update System 2023-12-20 10:40:49 UTC
FEDORA-2023-d870a65c9d has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2023-d870a65c9d

Comment 2 Fedora Update System 2023-12-20 10:40:50 UTC
FEDORA-2023-fc1142d945 has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-fc1142d945

Comment 3 Fedora Update System 2023-12-21 02:44:48 UTC
FEDORA-2023-d870a65c9d has been pushed to the Fedora 38 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-d870a65c9d`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-d870a65c9d

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 4 Fedora Update System 2023-12-21 03:23:09 UTC
FEDORA-2023-fc1142d945 has been pushed to the Fedora 39 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-fc1142d945`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-fc1142d945

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 5 Fedora Update System 2023-12-29 01:04:13 UTC
FEDORA-2023-d870a65c9d has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 6 Fedora Update System 2023-12-29 01:13:20 UTC
FEDORA-2023-fc1142d945 has been pushed to the Fedora 39 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.