Visitar URL original
bpo-46968: Check for 'sys/auxv.h' in the configure script by pablogsal · Pull Request #31961 · python/cpython · GitHub
Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
bpo-46968: Check for 'sys/auxv.h' in the configure script
  • Loading branch information
pablogsal committed Mar 17, 2022
commit 39123b090c14bd9e7749b18e6dd5e91b016c99b7
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Check for the existence of the "sys/auxv.h" header in :mod:`faulthandler` to
avoid compilation problems in systems where this header doesn't exist. Patch
by Pablo Galindo
4 changes: 2 additions & 2 deletions Modules/faulthandler.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "Python.h"
#include "Python.h" && defined(HAVE_SYS_AUXV_H)
Comment thread
pablogsal marked this conversation as resolved.
Outdated
#include "pycore_initconfig.h" // _PyStatus_ERR
#include "pycore_pyerrors.h" // _Py_DumpExtensionModules
#include "pycore_pystate.h" // _PyThreadState_GET()
Expand Down Expand Up @@ -26,7 +26,7 @@
# define FAULTHANDLER_USE_ALT_STACK
#endif

#if defined(FAULTHANDLER_USE_ALT_STACK) && defined(HAVE_LINUX_AUXVEC_H)
#if defined(FAULTHANDLER_USE_ALT_STACK) && defined(HAVE_LINUX_AUXVEC_H) && defined(HAVE_SYS_AUXV_H)
# include <linux/auxvec.h>
# include <sys/auxv.h>
Comment thread
pablogsal marked this conversation as resolved.
Outdated
#endif
Expand Down
2 changes: 1 addition & 1 deletion configure

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2375,7 +2375,7 @@ AC_DEFINE(STDC_HEADERS, 1, [Define to 1 if you have the ANSI C header files.])
# checks for header files
AC_CHECK_HEADERS([ \
alloca.h asm/types.h bluetooth.h conio.h crypt.h direct.h dlfcn.h endian.h errno.h fcntl.h grp.h \
ieeefp.h io.h langinfo.h libintl.h libutil.h linux/auxvec.h linux/memfd.h linux/random.h linux/soundcard.h \
ieeefp.h io.h langinfo.h libintl.h libutil.h linux/auxvec.h sys/auxv.h linux/memfd.h linux/random.h linux/soundcard.h \
linux/tipc.h linux/wait.h netinet/in.h netpacket/packet.h poll.h process.h pthread.h pty.h \
sched.h setjmp.h shadow.h signal.h spawn.h stropts.h sys/audioio.h sys/bsdtty.h sys/devpoll.h \
sys/endian.h sys/epoll.h sys/event.h sys/eventfd.h sys/file.h sys/ioctl.h sys/kern_control.h \
Expand Down
3 changes: 3 additions & 0 deletions pyconfig.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -1188,6 +1188,9 @@
/* Define to 1 if you have the <sys/audioio.h> header file. */
#undef HAVE_SYS_AUDIOIO_H

/* Define to 1 if you have the <sys/auxv.h> header file. */
#undef HAVE_SYS_AUXV_H

/* Define to 1 if you have the <sys/bsdtty.h> header file. */
#undef HAVE_SYS_BSDTTY_H

Expand Down