]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
2004-07-23 Jakub Jelinek <jakub@redhat.com>
authorRoland McGrath <roland@gnu.org>
Fri, 18 Feb 2005 00:08:56 +0000 (00:08 +0000)
committerRoland McGrath <roland@gnu.org>
Fri, 18 Feb 2005 00:08:56 +0000 (00:08 +0000)
[BZ #284]
* include/features.h (_POSIX_SOURCE, _POSIX_C_SOURCE): Define
if _XOPEN_SOURCE >= 500 even if __STRICT_ANSI__ is defined.

include/features.h

index 8b03e165f9b45d274f95d40eac6d15f8323be50b..5733b9b17c9c7ff7778b7fa2bf29f8400a1c3aab 100644 (file)
@@ -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
 
 /* 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