This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Undefinied _Py_Sigset_Converter function when HAVE_SIGSET_T not set
Type: compile error Stage: resolved
Components: Versions: Python 3.9, Python 3.8
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Roman Yurchak, brett.cannon, christian.heimes, miss-islington, pablogsal, serhiy.storchaka
Priority: normal Keywords: patch

Created on 2020-08-06 20:20 by Roman Yurchak, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 29770 merged christian.heimes, 2021-11-25 09:08
PR 29773 merged miss-islington, 2021-11-25 11:28
PR 29774 merged christian.heimes, 2021-11-25 11:32
Messages (4)
msg374963 - (view) Author: Roman Yurchak (Roman Yurchak) Date: 2020-08-06 20:20
The `_Py_Sigset_Converter` function is conditionally defined  in https://github.com/python/cpython/blob/777b611c8c5676b80898a429f71d28e59bddc49d/Modules/posixmodule.h#L27 if `ifdef HAVE_SIGSET_T`

However this function is called unconditionally in https://github.com/python/cpython/blob/777b611c8c5676b80898a429f71d28e59bddc49d/Modules/clinic/signalmodule.c.h#L385 (there are 4 such occurrences), which leads to a compilation error when `HAVE_SIGSET_T` is not set.

This is regression in 3.8+ as far as I can tell due to changes in https://github.com/python/cpython/pull/6720 

I imagine the solution could be to always define this function but raise an exception if it is called when HAVE_SIGSET_T` is undefined, as done in the following patch: https://github.com/iodide-project/pyodide/blob/fc5495ffdb54a11fd588dc60ba6b8777f90c3724/cpython/patches/0006-fix-Py_Sigset_Converter.patch 

Would this be acceptable, or is there a better way of handling it? Thanks!
msg406989 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2021-11-25 11:29
New changeset dc19e8698327cae3d6274b73c135375955f1d0d0 by Christian Heimes in branch 'main':
bpo-41498: Fix build on platforms without sigset_t (GH-29770)
https://github.com/python/cpython/commit/dc19e8698327cae3d6274b73c135375955f1d0d0
msg406990 - (view) Author: miss-islington (miss-islington) Date: 2021-11-25 11:53
New changeset 632d589afcaac3b8441c8c042a98e1ae452533e0 by Miss Islington (bot) in branch '3.10':
[3.10] bpo-41498: Fix build on platforms without sigset_t (GH-29770) (GH-29773)
https://github.com/python/cpython/commit/632d589afcaac3b8441c8c042a98e1ae452533e0
msg406992 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2021-11-25 12:02
New changeset 71b414750eee7af98cc3cee3a64c59d48302a17a by Christian Heimes in branch '3.9':
[3.9] bpo-41498: Fix build on platforms without sigset_t (GH-29770) (GH-29774)
https://github.com/python/cpython/commit/71b414750eee7af98cc3cee3a64c59d48302a17a
History
Date User Action Args
2022-04-11 14:59:34adminsetgithub: 85670
2021-11-26 09:41:56christian.heimeslinkissue40280 dependencies
2021-11-25 18:36:19brett.cannonsetnosy: + brett.cannon
2021-11-25 12:06:59christian.heimessetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2021-11-25 12:02:58christian.heimessetmessages: + msg406992
2021-11-25 11:53:11miss-islingtonsetmessages: + msg406990
2021-11-25 11:32:49christian.heimessetpull_requests: + pull_request28011
2021-11-25 11:29:11christian.heimessetmessages: + msg406989
2021-11-25 11:28:50miss-islingtonsetnosy: + miss-islington
pull_requests: + pull_request28010
2021-11-25 09:08:09christian.heimessetkeywords: + patch
nosy: + christian.heimes

pull_requests: + pull_request28007
stage: patch review
2021-11-25 08:09:41christian.heimeslinkissue45895 superseder
2020-08-06 20:21:06Roman Yurchaksettype: compile error
2020-08-06 20:20:07Roman Yurchakcreate