File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22#define Py_PYTHON_H
33/* Since this is a "meta-include" file, no #ifdef __cplusplus / extern "C" { */
44
5-
6- /* Enable compiler features; switching on C lib defines doesn't work
7- here, because the symbols haven't necessarily been defined yet. */
8- #ifndef _GNU_SOURCE
9- # define _GNU_SOURCE 1
10- #endif
11-
12- #ifndef _XOPEN_SOURCE
13- # define _XOPEN_SOURCE 500
14- #endif
15-
165/* Include nearly all Python header files */
176
187#include "patchlevel.h"
Original file line number Diff line number Diff line change 11#! /bin/sh
2- # From configure.in Revision: 1.333 .
2+ # From configure.in Revision: 1.334 .
33# Guess values for system-dependent variables and create Makefiles.
44# Generated by GNU Autoconf 2.53.
55#
@@ -1225,6 +1225,23 @@ VERSION=2.3
12251225
12261226SOVERSION=1.0
12271227
1228+ # The later defininition of _XOPEN_SOURCE disables certain features
1229+ # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1230+
1231+ cat >> confdefs.h << \_ACEOF
1232+ #define _GNU_SOURCE 1
1233+ _ACEOF
1234+
1235+
1236+ # The definition of _GNU_SOURCE potentially causes a change of the value
1237+ # of _XOPEN_SOURCE. So define it only conditionally.
1238+
1239+
1240+ cat >> confdefs.h << \_ACEOF
1241+ #define _XOPEN_SOURCE 500
1242+ _ACEOF
1243+
1244+
12281245# Arguments passed to configure.
12291246
12301247CONFIG_ARGS=" $ac_configure_args "
Original file line number Diff line number Diff line change @@ -20,6 +20,19 @@ VERSION=2.3
2020AC_SUBST(SOVERSION)
2121SOVERSION=1.0
2222
23+ # The later defininition of _XOPEN_SOURCE disables certain features
24+ # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
25+ AC_DEFINE(_GNU_SOURCE, 1, [Define on Linux to activate all library features])
26+
27+ # The definition of _GNU_SOURCE potentially causes a change of the value
28+ # of _XOPEN_SOURCE. So define it only conditionally.
29+ AH_VERBATIM([_XOPEN_SOURCE],
30+ [/* Define on UNIX to activate XPG/5 features. */
31+ #ifndef _XOPEN_SOURCE
32+ # define _XOPEN_SOURCE 500
33+ #endif])
34+ AC_DEFINE(_XOPEN_SOURCE, 500)
35+
2336# Arguments passed to configure.
2437AC_SUBST(CONFIG_ARGS)
2538CONFIG_ARGS="$ac_configure_args"
Original file line number Diff line number Diff line change 754754/* This must be set to 64 on some systems to enable large file support. */
755755#undef _FILE_OFFSET_BITS
756756
757+ /* Define on Linux to activate all library features */
758+ #undef _GNU_SOURCE
759+
757760/* This must be defined on some systems to enable large file support. */
758761#undef _LARGEFILE_SOURCE
759762
773776/* Define to force use of thread-safe errno, h_errno, and other functions */
774777#undef _REENTRANT
775778
779+ /* Define on UNIX to activate XPG/5 features. */
780+ #ifndef _XOPEN_SOURCE
781+ # define _XOPEN_SOURCE 500
782+ #endif
783+
776784/* Define to 1 if type `char' is unsigned and you are not using gcc. */
777785#ifndef __CHAR_UNSIGNED__
778786# undef __CHAR_UNSIGNED__
You can’t perform that action at this time.
0 commit comments