summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2005-02-18 00:08:56 +0000
committerRoland McGrath <roland@gnu.org>2005-02-18 00:08:56 +0000
commit4cf0d9359dea28e1e5779276e1f751f9118a1050 (patch)
tree23cee8889398a43d729f3fe8e26cb9155a728905
parent372166f9d9302dbfbea6f8f1d672b043d8cbccd7 (diff)
2004-07-23 Jakub Jelinek <jakub@redhat.com>
[BZ #284] * include/features.h (_POSIX_SOURCE, _POSIX_C_SOURCE): Define if _XOPEN_SOURCE >= 500 even if __STRICT_ANSI__ is defined.
-rw-r--r--include/features.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/features.h b/include/features.h
index 8b03e165f9..5733b9b17c 100644
--- a/include/features.h
+++ b/include/features.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-1993,1995-2003, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1991-1993,1995-2003,2004,2005 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -181,8 +181,8 @@
/* If none of the ANSI/POSIX macros are defined, use POSIX.1 and POSIX.2
(and IEEE Std 1003.1b-1993 unless _XOPEN_SOURCE is defined). */
-#if (!defined __STRICT_ANSI__ && !defined _POSIX_SOURCE && \
- !defined _POSIX_C_SOURCE)
+#if ((!defined __STRICT_ANSI__ || (_XOPEN_SOURCE - 0) >= 500) && \
+ !defined _POSIX_SOURCE && !defined _POSIX_C_SOURCE)
# define _POSIX_SOURCE 1
# if defined _XOPEN_SOURCE && (_XOPEN_SOURCE - 0) < 500
# define _POSIX_C_SOURCE 2