]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Add support for XPG7 testing.
authorUlrich Drepper <drepper@redhat.com>
Sat, 9 Jan 2010 18:56:41 +0000 (10:56 -0800)
committerUlrich Drepper <drepper@redhat.com>
Sat, 9 Jan 2010 18:56:41 +0000 (10:56 -0800)
The header conformance testing code needed extending for XPG7.  This
exposed a few bugs in the headers.  There are more changes to come.

115 files changed:
ChangeLog
bits/confname.h
conform/conformtest.pl
conform/data/ctype.h-data
conform/data/dirent.h-data
conform/data/errno.h-data
conform/data/fcntl.h-data
conform/data/fmtmsg.h-data
conform/data/fnmatch.h-data
conform/data/ftw.h-data
conform/data/glob.h-data
conform/data/grp.h-data
conform/data/iconv.h-data
conform/data/langinfo.h-data
conform/data/libgen.h-data
conform/data/limits.h-data
conform/data/locale.h-data
conform/data/math.h-data
conform/data/monetary.h-data
conform/data/mqueue.h-data
conform/data/ndbm.h-data
conform/data/netdb.h-data
conform/data/pthread.h-data
conform/data/pwd.h-data
conform/data/regex.h-data
conform/data/sched.h-data
conform/data/search.h-data
conform/data/semaphore.h-data
conform/data/setjmp.h-data
conform/data/signal.h-data
conform/data/spawn.h-data
conform/data/stdio.h-data
conform/data/stdlib.h-data
conform/data/string.h-data
conform/data/strings.h-data
conform/data/sys/ipc.h-data
conform/data/sys/msg.h-data
conform/data/sys/resource.h-data
conform/data/sys/sem.h-data
conform/data/sys/shm.h-data
conform/data/sys/socket.h-data
conform/data/sys/stat.h-data
conform/data/sys/time.h-data
conform/data/sys/types.h-data
conform/data/sys/uio.h-data
conform/data/sys/wait.h-data
conform/data/syslog.h-data
conform/data/tar.h-data
conform/data/termios.h-data
conform/data/time.h-data
conform/data/ulimit.h-data
conform/data/unistd.h-data
conform/data/utmpx.h-data
conform/data/wchar.h-data
conform/data/wctype.h-data
conform/data/wordexp.h-data
dirent/dirent.h
include/features.h
io/fcntl.h
locale/C-address.c
locale/C-collate.c
locale/C-ctype.c
locale/C-identification.c
locale/C-measurement.c
locale/C-messages.c
locale/C-monetary.c
locale/C-name.c
locale/C-numeric.c
locale/C-paper.c
locale/C-telephone.c
locale/C-time.c
locale/findlocale.c
locale/global-locale.c
locale/loadarchive.c
locale/loadlocale.c
locale/localeinfo.h
locale/nl_langinfo_l.c
locale/setlocale.c
locale/xlocale.c
locale/xlocale.h
nptl/ChangeLog
nptl/sysdeps/pthread/pthread.h
posix/confstr.c
stdio-common/vfscanf.c
stdlib/stdlib.h
stdlib/strfmon_l.c
stdlib/strtod_l.c
stdlib/strtol_l.c
string/strcoll_l.c
string/string.h
string/strxfrm_l.c
sysdeps/mach/hurd/bits/stat.h
sysdeps/unix/bsd/bits/stat.h
sysdeps/unix/sysv/bits/stat.h
sysdeps/unix/sysv/linux/bits/stat.h
sysdeps/unix/sysv/linux/i386/bits/fcntl.h
sysdeps/unix/sysv/linux/ia64/bits/fcntl.h
sysdeps/unix/sysv/linux/ia64/bits/stat.h
sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h
sysdeps/unix/sysv/linux/powerpc/bits/stat.h
sysdeps/unix/sysv/linux/s390/bits/fcntl.h
sysdeps/unix/sysv/linux/s390/bits/stat.h
sysdeps/unix/sysv/linux/sh/bits/fcntl.h
sysdeps/unix/sysv/linux/sparc/bits/fcntl.h
sysdeps/unix/sysv/linux/sparc/bits/stat.h
sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h
sysdeps/unix/sysv/linux/x86_64/bits/stat.h
time/alt_digit.c
time/asctime.c
time/era.c
time/lc-time-cleanup.c
time/strftime_l.c
time/strptime_l.c
wcsmbs/wcsmbsload.c
wcsmbs/wcsmbsload.h

index 6cbc86d2caafa23e9557b218e889f0c4d637cd39..a2f8d1b78feab32e30c43076c087f9dca6c5d4b3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,135 @@
+2010-01-09  Ulrich Drepper  <drepper@redhat.com>
+
+       * conform/conformtest.pl: Update for XPG7 and some bug fixes.
+       * conform/data/ctype.h-data: Likewise.
+       * conform/data/dirent.h-data: Likewise.
+       * conform/data/errno.h-data: Likewise.
+       * conform/data/fcntl.h-data: Likewise.
+       * conform/data/fmtmsg.h-data: Likewise.
+       * conform/data/fnmatch.h-data: Likewise.
+       * conform/data/ftw.h-data: Likewise.
+       * conform/data/glob.h-data: Likewise.
+       * conform/data/grp.h-data: Likewise.
+       * conform/data/iconv.h-data: Likewise.
+       * conform/data/langinfo.h-data: Likewise.
+       * conform/data/libgen.h-data: Likewise.
+       * conform/data/limits.h-data: Likewise.
+       * conform/data/locale.h-data: Likewise.
+       * conform/data/math.h-data: Likewise.
+       * conform/data/monetary.h-data: Likewise.
+       * conform/data/mqueue.h-data: Likewise.
+       * conform/data/ndbm.h-data: Likewise.
+       * conform/data/netdb.h-data: Likewise.
+       * conform/data/pthread.h-data: Likewise.
+       * conform/data/pwd.h-data: Likewise.
+       * conform/data/regex.h-data: Likewise.
+       * conform/data/sched.h-data: Likewise.
+       * conform/data/search.h-data: Likewise.
+       * conform/data/semaphore.h-data: Likewise.
+       * conform/data/setjmp.h-data: Likewise.
+       * conform/data/signal.h-data: Likewise.
+       * conform/data/spawn.h-data: Likewise.
+       * conform/data/stdio.h-data: Likewise.
+       * conform/data/stdlib.h-data: Likewise.
+       * conform/data/string.h-data: Likewise.
+       * conform/data/strings.h-data: Likewise.
+       * conform/data/sys/ipc.h-data: Likewise.
+       * conform/data/sys/msg.h-data: Likewise.
+       * conform/data/sys/resource.h-data: Likewise.
+       * conform/data/sys/sem.h-data: Likewise.
+       * conform/data/sys/shm.h-data: Likewise.
+       * conform/data/sys/socket.h-data: Likewise.
+       * conform/data/sys/stat.h-data: Likewise.
+       * conform/data/sys/time.h-data: Likewise.
+       * conform/data/sys/types.h-data: Likewise.
+       * conform/data/sys/uio.h-data: Likewise.
+       * conform/data/sys/wait.h-data: Likewise.
+       * conform/data/syslog.h-data: Likewise.
+       * conform/data/tar.h-data: Likewise.
+       * conform/data/termios.h-data: Likewise.
+       * conform/data/time.h-data: Likewise.
+       * conform/data/ulimit.h-data: Likewise.
+       * conform/data/unistd.h-data: Likewise.
+       * conform/data/utmpx.h-data: Likewise.
+       * conform/data/wchar.h-data: Likewise.
+       * conform/data/wctype.h-data: Likewise.
+       * conform/data/wordexp.h-data: Likewise.
+
+       * io/fcntl.h: Define mode_t macros instead of including sys/stat.h.
+       * sysdeps/unix/bsd/bits/stat.h: Enable using from fcntl.h.
+       * sysdeps/unix/sysv/linux/powerpc/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/linux/x86_64/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/linux/s390/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/linux/sparc/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/linux/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/linux/ia64/bits/stat.h: Likewise.
+       * sysdeps/unix/sysv/bits/stat.h: Likewise.
+       * sysdeps/mach/hurd/bits/stat.h: Likewise.
+
+       * stdlib/stdlib.h: Define wait-related bits for XPG7.
+       Don't declare valloc, mktemp, ecvt, fcvt, gcvt for XPG6 and  up.
+       Declare mkstemp and getsubopt for XPG7.
+       Declare posix_openpt for XPG6 XSI.
+
+       * include/features.h: Define __USE_XOPEN2KXSI for _XOPEN_SOURCE >= 600
+       and __USE_XOPEN2K8XSI for _XOPEN_SOURCE >= 700.
+
+       * string/string.h: Declare strdup for XPG7.
+
+2010-01-08  Ulrich Drepper  <drepper@redhat.com>
+
+       * bits/confname.h: Define _CS_V6_ENV and _CS_V7_ENV.
+       * posix/confstr.c: Implement _CS_V6_ENV and _CS_V7_ENV.
+
+       * dirent/dirent.h: Really fix feature selection.
+
+       * locale/localeinfo.h: Rename struct locale_data to __locale_data.
+       Fix all users.
+       * locale/C-address.c: Fix all users.
+       * locale/C-collate.c: Likewise.
+       * locale/C-ctype.c: Likewise.
+       * locale/C-identification.c: Likewise.
+       * locale/C-measurement.c: Likewise.
+       * locale/C-messages.c: Likewise.
+       * locale/C-monetary.c: Likewise.
+       * locale/C-name.c: Likewise.
+       * locale/C-numeric.c: Likewise.
+       * locale/C-paper.c: Likewise.
+       * locale/C-telephone.c: Likewise.
+       * locale/C-time.c: Likewise.
+       * locale/findlocale.c: Likewise.
+       * locale/global-locale.c: Likewise.
+       * locale/loadarchive.c: Likewise.
+       * locale/loadlocale.c: Likewise.
+       * locale/nl_langinfo_l.c: Likewise.
+       * locale/setlocale.c: Likewise.
+       * locale/xlocale.c: Likewise.
+       * locale/xlocale.h: Likewise.
+       * stdio-common/vfscanf.c: Likewise.
+       * stdlib/strfmon_l.c: Likewise.
+       * stdlib/strtod_l.c: Likewise.
+       * stdlib/strtol_l.c: Likewise.
+       * string/strcoll_l.c: Likewise.
+       * string/strxfrm_l.c: Likewise.
+       * time/alt_digit.c: Likewise.
+       * time/asctime.c: Likewise.
+       * time/era.c: Likewise.
+       * time/lc-time-cleanup.c: Likewise.
+       * time/strftime_l.c: Likewise.
+       * time/strptime_l.c: Likewise.
+       * wcsmbs/wcsmbsload.c: Likewise.
+       * wcsmbs/wcsmbsload.h: Likewise.
+
+       * sysdeps/unix/sysv/linux/sh/bits/fcntl.h: Define O_DIRECTORY,
+       O_NOFOLLOW, O_CLOEXEC, F_DUPFD_CLOEXEC, F_SETOWN, and F_GETOWN
+       for XPG7.
+       * sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h: Likewise.
+       * sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h: Likewise.
+       * sysdeps/unix/sysv/linux/sparc/bits/fcntl.h: Likewise.
+       * sysdeps/unix/sysv/linux/ia64/bits/fcntl.h: Likewise.
+       * sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Likewise.
+       * sysdeps/unix/sysv/linux/s390/bits/fcntl.h: Likewise.
+
 2010-01-06  Ulrich Drepper  <drepper@redhat.com>
 
        * dirent/dirent.h: Fix typo in feature selection macro use.
index 757ed4f3ca570b4b6f0c6e4c1d3bc2a75c03d47d..b3c33a9864405fad64e74a0d169ea6b1a2e9860f 100644 (file)
@@ -1,5 +1,5 @@
 /* `sysconf', `pathconf', and `confstr' NAME values.  Generic version.
-   Copyright (C) 1993,1995-1998,2000,2001,2003,2004,2007,2009
+   Copyright (C) 1993,1995-1998,2000,2001,2003,2004,2007,2009,2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -669,4 +669,9 @@ enum
 #define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS _CS_POSIX_V7_LPBIG_OFFBIG_LIBS
     _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS
 #define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS
+
+    _CS_V6_ENV,
+#define _CS_V6_ENV                     _CS_V6_ENV
+    _CS_V7_ENV,
+#define _CS_V7_ENV                     _CS_V7_ENV
   };
index b15656bd60f0d294cc1d826e0dddcdbf7ca01dd3..e594d87972056f82651b322ea4d86321ca353304 100644 (file)
@@ -1,6 +1,7 @@
 #! /usr/bin/perl
 
 use Getopt::Long;
+use POSIX;
 
 $CC = "gcc";
 
@@ -30,7 +31,8 @@ if (@headers == ()) {
 }
 
 if ($dialect ne "ISO" && $dialect ne "POSIX" && $dialect ne "XPG3"
-    && $dialect ne "XPG4" && $dialect ne "UNIX98" && $dialect ne "XOPEN2K") {
+    && $dialect ne "XPG4" && $dialect ne "UNIX98" && $dialect ne "XOPEN2K"
+    && $dialect ne "XOPEN2K8" && $dialect ne "POSIX2008") {
   die "unknown dialect \"$dialect\"";
 }
 
@@ -40,6 +42,8 @@ $CFLAGS{"XPG3"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_XOPEN_SOURCE";
 $CFLAGS{"XPG4"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_XOPEN_SOURCE_EXTENDED";
 $CFLAGS{"UNIX98"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_XOPEN_SOURCE=500";
 $CFLAGS{"XOPEN2K"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_XOPEN_SOURCE=600";
+$CFLAGS{"XOPEN2K8"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_XOPEN_SOURCE=700";
+$CFLAGS{"POSIX2008"} = "-I. -fno-builtin '-D__attribute__(x)=' -D_POSIX_C_SOURCE=200809L";
 
 
 # These are the ISO C99 keywords.
@@ -71,7 +75,10 @@ while ($#knownproblems >= 0) {
   $isknown{pop (@knownproblems)} = 1;
 }
 
-$tmpdir = "/tmp";
+$uid = getuid();
+($pwname,$pwpasswd,$pwuid,$pwgid,
+ $pwquota,$pwcomment,$pwgcos,$pwdir,$pwshell,$pwexpire) = getpwuid($uid);
+$tmpdir = "$pwdir";
 
 $verbose = 1;
 
@@ -660,9 +667,6 @@ while ($#headers >= 0) {
        $maybe_opaque = 1;
       }
 
-      # Remember that this name is allowed.
-      push @allow, $type;
-
       # Generate a program to test for the availability of this constant.
       open (TESTFILE, ">$fnamebase.c");
       print TESTFILE "$prepend";
@@ -690,9 +694,6 @@ while ($#headers >= 0) {
        $maybe_opaque = 1;
       }
 
-      # Remember that this name is allowed.
-      push @allow, $type;
-
       # Generate a program to test for the availability of this type.
       open (TESTFILE, ">$fnamebase.c");
       print TESTFILE "$prepend";
@@ -704,6 +705,27 @@ while ($#headers >= 0) {
       }
       close (TESTFILE);
 
+      compiletest ($fnamebase, "Testing for type $type",
+                  "Type \"$type\" not available.", $missing, 0);
+    } elsif (/^tag *({([^}]*)|([a-zA-Z0-9_]*))/) {
+      my($type) = "$2$3";
+
+      # Remember that this name is allowed.
+      if ($type =~ /^struct *(.*)/) {
+       push @allow, $1;
+      } elsif ($type =~ /^union *(.*)/) {
+       push @allow, $1;
+      } else {
+       push @allow, $type;
+      }
+
+      # Generate a program to test for the availability of this type.
+      open (TESTFILE, ">$fnamebase.c");
+      print TESTFILE "$prepend";
+      print TESTFILE "#include <$h>\n";
+      print TESTFILE "$type;\n";
+      close (TESTFILE);
+
       compiletest ($fnamebase, "Testing for type $type",
                   "Type \"$type\" not available.", $missing, 0);
     } elsif (/^optional-function *({([^}]*)}|([a-zA-Z0-9_]*)) [(][*]([a-zA-Z0-9_]*) ([(].*[)])/) {
index 7454bd328806fd89f5b8400001174817d122730a..d082230f946083814a7b096168ef9a16cee81bf4 100644 (file)
@@ -12,7 +12,7 @@ function int isxdigit (int)
 function int tolower (int)
 function int toupper (int)
 
-#ifndef ISO
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function int isascii (int)
 function int toascii (int)
 
@@ -26,4 +26,22 @@ allow is*
 allow to*
 
 allow *_t
+
+# if defined XOPEN2K8 || defined XOPEN2K8 || defined POSIX2008
+type locale_t
+
+function int isalnum_l (int, locale_t)
+function int isalpha_l (int, locale_t)
+function int iscntrl_l (int, locale_t)
+function int isdigit_l (int, locale_t)
+function int isgraph_l (int, locale_t)
+function int islower_l (int, locale_t)
+function int isprint_l (int, locale_t)
+function int ispunct_l (int, locale_t)
+function int isspace_l (int, locale_t)
+function int isupper_l (int, locale_t)
+function int isxdigit_l (int, locale_t)
+function int tolower_l (int, locale_t)
+function int toupper_l (int, locale_t)
+# endif
 #endif
index e496dab0dd583d87039bc415b41d06a6e56838a3..761d5786b5360f681bfb8550777327a3253f528c 100644 (file)
@@ -3,7 +3,9 @@ type DIR
 
 type {struct dirent}
 
+# if !defined POSIX && !defined POSIX2008
 element {struct dirent} ino_t d_ino
+# endif
 element {struct dirent} char d_name []
 
 type ino_t
@@ -13,9 +15,18 @@ function {DIR*} opendir (const char*)
 function {struct dirent*} readdir (DIR*)
 function int readdir_r (DIR*, struct dirent*, struct dirent**)
 function void rewinddir (DIR*)
+# if !defined POSIX && !defined POSIX2008
 function void seekdir (DIR*, long int)
 function {long int} telldir (DIR*)
+# endif
 
 allow d_*
 allow *_t
+
+# if defined XOPEN2K8 || defined POSIX2008
+function int alphasort (const struct dirent**, const struct dirent**)
+function int dirfd (DIR*)
+function int scandir (const char*, struct dirent***, int(*)(const struct dirent*), int(*)(const struct dirent**,const struct dirent **))
+function {DIR*} fdopendir (int)
+# endif
 #endif
index 67225248a28035630122552b2c126fda173e4e07..ffdf6b5c4d474fd62dd08263987cae7b2617cbf8 100644 (file)
@@ -79,6 +79,11 @@ constant ETXTBSY
 constant EWOULDBLOCK
 constant EXDEV
 
+# if defined XOPEN2K8 || defined POSIX2008
+constant ENOTRECOVERABLE
+constant EOWNERDEAD
+# endif
+
 // variable int errno
 allow errno
 
index c8caf0360f5ac5a7040997079ef698c63ea7560c..7769a446dd774105eaae9ac0d1775ef620868176 100644 (file)
@@ -60,9 +60,11 @@ constant S_IWOTH
 constant S_IXOTH
 constant S_ISUID
 constant S_ISGID
+#if !defined POSIX && !defined POSIX2008
 constant S_ISVTX
+#endif
 
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 constant POSIX_FADV_NORMAL
 constant POSIX_FADV_SEQUENTIAL
 constant POSIX_FADV_RANDOM
@@ -86,11 +88,32 @@ type pid_t
 function int creat (const char*, mode_t)
 function int fcntl (int, int, ...)
 function int open (const char*, int, ...)
-#ifdef XOPEN2K
+#if defined XOPEN2K8 || defined POSIX2008
+function int openat (int, const char*, int, ...)
+#endif
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function int posix_fadvise (int, off_t, off_t, int)
 function int posix_fallocate (int, off_t, off_t)
 #endif
 
+#if defined XOPEN2K8 || defined POSIX2008
+constant O_TTY_INIT
+constant O_CLOEXEC
+constant O_EXEC
+constant O_SEARCH
+constant O_DIRECTORY
+constant O_NOFOLLOW
+constant FD_CLOEXEC
+constant F_DUPFD_CLOEXEC
+constant AT_FDCWD
+constant AT_EACCESS
+constant AT_SYMLINK_NOFOLLOW
+constant AT_SYMLINK_FOLLOW
+constant AT_REMOVEDIR
+
+function int openat(int, const char*, int, ...)
+#endif
+
 allow-header sys/stat.h
 allow-header unistd.h
 
@@ -99,4 +122,8 @@ allow F_*
 allow O_*
 allow S_*
 allow *_t
+
+allow timespec
+allow tv_nsec
+allow tv_sec
 #endif
index da1ed65ac4483b6045657004176128b7f3832305..67c35c1c932f7efd5502590cc6d91f55e944f133 100644 (file)
@@ -1,4 +1,4 @@
-#if !defined ISO && !defined POSIX
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 macro MM_HARD
 constant MM_HARD
 
index ef34fc4e046b58f6ab15e7b238ac229ecbdbfd58..96591d6d438751164250c9c6f40ae806cb783c50 100644 (file)
@@ -3,7 +3,9 @@ constant FNM_NOMATCH
 constant FNM_PATHNAME
 constant FNM_PERIOD
 constant FNM_NOESCAPE
+#if !defined XOPEN2K8 && !defined POSIX2008
 constant FNM_NOSYS
+#endif
 
 function int fnmatch (const char*, const char*, int)
 
index 81c50070d16d9f0d3bc185813998328facb6efc1..eb499243a54d901e9ae84813536bc4f8bea5188c 100644 (file)
@@ -1,4 +1,4 @@
-#if !defined ISO && !defined POSIX
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct FTW}
 element {struct FTW} int base
 element {struct FTW} int level
index 221a3154cbec058ef0dbe8633f1c0e0717668972..9f90f8b84b5faf48a8fcfd29d9e2d02e352ea926 100644 (file)
@@ -15,7 +15,9 @@ constant GLOB_NOSORT
 constant GLOB_ABORTED
 constant GLOB_NOMATCH
 constant GLOB_NOSPACE
+# if !defined XOPEN2K8 && !defined POSIX2008
 constant GLOB_NOSYS
+# endif
 
 function int glob (const char*, int, int (*) (const char*, int), glob_t*)
 function void globfree (glob_t *)
index 91401b31d953cf8b75bd4b2b6a38dbda8bf14a45..16519506e5682010a68618acefd38124a4e1c191 100644 (file)
@@ -7,6 +7,9 @@ element {struct group} {char**} gr_mem
 # ifndef POSIX
 type gid_t
 # endif
+# if defined XOPEN2K8 || defined POSIX2008
+type size_t
+# endif
 
 function {struct group*} getgrgid (gid_t)
 function {struct group*} getgrnam (const char*)
@@ -15,7 +18,9 @@ function int getgrgid_r (gid_t, struct group*, char *, size_t, struct group**)
 function int getgrnam_r (const char *, struct group *, char *, size_t, struct group**)
 function {struct group*} getgrent (void)
 function void endgrent (void)
+#  ifndef POSIX2008
 function void setgrent (void)
+#  endif
 # endif
 
 allow gr_*
index f1e2ea05276f279339e9c5a64c249c6150a64ed8..7071d90f6075811a294dfdb3c12a76d1dcf2b81d 100644 (file)
@@ -1,5 +1,8 @@
 #if !defined ISO && !defined POSIX
 type iconv_t
+# if defined XOPEN2K8 || defined POSIX2008
+type size_t
+# endif
 
 function iconv_t iconv_open (const char*, const char*)
 function size_t iconv (iconv_t, char**, size_t*, char**, size_t*)
index 2fe38a266d8145978d40d86b517f07d2fc7f19a7..95bc3f934e4d644c7b6d09344228f1b008b22f99 100644 (file)
@@ -55,7 +55,15 @@ constant YESEXPR
 constant NOEXPR
 constant CRNCYSTR
 
+type nl_item
+# if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+# endif
+
 function {char*} nl_langinfo (nl_item)
+# if defined XOPEN2K8 || defined POSIX2008
+function {char*} nl_langinfo_l (nl_item, locale_t)
+# endif
 
 allow-header nl_types.h
 
index ca0126fbb11f1f1b755aaf892ea0590509e22bfd..b749b8dcde3a9ca3d28a074dadb5444cdfdc345a 100644 (file)
@@ -1,4 +1,4 @@
-#if !defined ISO && !defined POSIX
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function {char*} basename (char*)
 function {char*} dirname (char*)
 
index 9801ddeb86f1616865402ac741f44f9166fe09dd..2e720a9b78018bd06418604e47897a6e3f5ab498 100644 (file)
@@ -11,7 +11,9 @@ allow LOGIN_NAME_MAX
 allow MQ_OPEN_MAX
 allow OPEN_MAX
 allow PAGESIZE
+#if !defined POSIX && !defined POSIX2008
 allow PAGE_SIZE
+#endif
 allow PTHREAD_DESTRUCTOR_ITERATIONS
 allow PTHREAD_KEYS_MAX
 allow PTHREAD_STACK_MIN
@@ -131,12 +133,18 @@ constant SHRT_MIN <= -32767
 
 optional-constant CHARCLASS_NAME_MAX >= 14
 optional-constant NL_ARGMAX >= 9
+#if !defined POSIX && !defined POSIX2008
 optional-constant NL_LANGMAX >= 14
+#endif
 optional-constant NL_MSGMAX >= 32767
+#if !defined XOPEN2K8 && !defined POSIX2008
 optional-constant NL_NMAX
+#endif
 optional-constant NL_SETMAX >= 255
 optional-constant NL_TEXTMAX
+#if !defined POSIX && !defined POSIX2008
 optional-constant NZERO >= 20
+#endif
 optional-constant TMP_MAX >= 10000
 
 allow *_MAX
index 84bd6abc09788aa2df07eb8a88b4d26503a077ff..f6e6c22c80720f006f65a6e00366919ccd6a02fd 100644 (file)
@@ -17,7 +17,7 @@ element {struct lconv} char p_cs_precedes
 element {struct lconv} char p_sep_by_space
 element {struct lconv} char p_sign_posn
 element {struct lconv} {char*} thousands_sep
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 element {struct lconv} char int_n_cs_precedes
 element {struct lconv} char int_n_sep_by_space
 element {struct lconv} char int_n_sign_posn
@@ -36,8 +36,31 @@ macro LC_MONETARY
 macro LC_NUMERIC
 macro LC_TIME
 
+#if defined XOPEN2K8 || defined POSIX2008
+constant LC_GLOBAL_LOCALE
+
+macro LC_COLLATE_MASK
+macro LC_CTYPE_MASK
+macro LC_MESSAGES_MASK
+macro LC_MONETARY_MASK
+macro LC_NUMERIC_MASK
+macro LC_TIME_MASK
+macro LC_ALL_MASK
+
+type locale_t
+#endif
+
 function {struct lconv*} localeconv (void)
 function {char*} setlocale (int, const char*)
+#if defined XOPEN2K8 || defined POSIX2008
+function locale_t duplocale (locale_t)
+function void freelocale (locale_t)
+function locale_t newlocale (int, const char*, locale_t)
+function locale_t uselocale (locale_t)
+#endif
 
 allow LC_*
 allow *_t
+#if defined XOPEN2K8 || defined POSIX2008
+allow LC_*_MASK
+#endif
index 40312effdd1c9ec9700c71de20e0c67115e0ab79..da9ce68fc2571dff82ea1e5ddf25a76842bcaedc 100644 (file)
@@ -12,6 +12,7 @@ macro islessequal
 macro islessgreater
 macro isunordered
 
+# ifndef POSIX2008
 constant M_E
 constant M_LOG2E
 constant M_LOG10E
@@ -27,6 +28,7 @@ constant M_SQRT2
 constant M_SQRT1_2
 
 constant MAXFLOAT
+# endif
 constant HUGE_VAL
 constant HUGE_VALF
 constant HUGE_VALL
@@ -79,14 +81,18 @@ function double erf (double)
 function double erfc (double)
 function double gamma (double)
 function double hypot (double, double)
+#if !defined POSIX && !defined POSIX2008
 function double j0 (double)
 function double j1 (double)
 function double jn (int, double)
+#endif
 function double lgamma (double)
 function double tgamma (double)
+#if !defined POSIX && !defined POSIX2008
 function double y0 (double)
 function double y1 (double)
 function double yn (int, double)
+#endif
 function int isnan (double)
 function double acosh (double)
 function double asinh (double)
@@ -117,8 +123,10 @@ function double fmin (double, double)
 function double fma (double, double, double)
 function double nan (const char*)
 
+#if !defined POSIX && !defined POSIX2008
 // variable signgam
 allow signgam
+#endif
 
 #if !defined ISO && !defined POSIX
 function float acosf (float)
index eab8384d76ea55647a1649bc883d699e8b6c081f..7935f2ab85c79a5667c1007b9d167d83919fd1f4 100644 (file)
@@ -1,8 +1,14 @@
 #if !defined ISO && !defined POSIX
 type size_t
 type ssize_t
+# if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+# endif
 
 function ssize_t strfmon (char*, size_t, const char*, ...)
+# if defined XOPEN2K8 || defined POSIX2008
+function ssize_t strfmon_l (char*, size_t, locale_t, const char*, ...)
+# endif
 
 allow *_t
 #endif
index 6ec1e312d5edeb606651a0af566f2e0f67c13dc8..16335a556f1f58e0cf3c4d06934ca7ab8f1535e1 100644 (file)
@@ -18,11 +18,19 @@ function ssize_t mq_receive (mqd_t, char*, size_t, unsigned int*)
 function int mq_send (mqd_t, const char*, size_t, unsigned int)
 function int mq_setattr (mqd_t, const struct mq_attr*, struct mq_attr*)
 function int mq_unlink (const char*)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 optional-function ssize_t mq_timedreceive (mqd_t, char*, size_t, unsigned int*, const struct timespec*)
 optional-function int mq_timedsend (mqd_t, const char*, size_t, unsigned int, const struct timespec*)
 #endif
 
+#if defined XOPEN2K8 || defined POSIX2008
+type pthread_attr_t
+type size_t
+type ssize_t
+type {struct timespec}
+type {struct sigevent}
+#endif
+
 allow-header fcntl.h
 allow-header signal.h
 allow-header sys/types.h
index 6e606e589c59703763794e2d8e5434e9bb891c86..af091de0fd91224940e5104cfc287ed2dd1f0ab3 100644 (file)
@@ -1,4 +1,4 @@
-#if !defined ISO && !defined POSIX
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type datum
 element datum {void*} dptr
 element datum size_t dsize
index 483a3fcc964b21c45a1b1ed5175a439cd9989a5c..254ea65027e49100044a73fb5958bc8a5a20edbd 100644 (file)
@@ -34,6 +34,7 @@ element {struct servent} {char*} s_proto
 
 macro IPPORT_RESERVED
 
+#if !defined XOPEN2K8 && !defined POSIX2008
 // variable int h_errno
 allow h_errno
 
@@ -41,6 +42,7 @@ macro HOST_NOT_FOUND
 macro NO_DATA
 macro NO_RECOVERY
 macro TRY_AGAIN
+#endif
 
 type {struct addrinfo}
 element {struct addrinfo} int ai_flags
index aa5861f1d821fa8b49c36e9ede33bd9c845cb60b..5a536c7bf98e57378377f36fe6a539a63e2fff6c 100644 (file)
@@ -25,6 +25,10 @@ macro PTHREAD_MUTEX_INITIALIZER
 constant PTHREAD_MUTEX_RECURSIVE
 macro PTHREAD_RWLOCK_INITIALIZER
 # endif
+# if defined XOPEN2K8 || defined POSIX2008
+constant PTHREAD_MUTEX_ROBUST
+constant PTHREAD_MUTEX_STALLED
+# endif
 
 type pthread_attr_t
 type pthread_barrier_t
@@ -90,7 +94,7 @@ function int pthread_create (pthread_t*, const pthread_attr_t*, void *(*) (void*
 function int pthread_detach (pthread_t)
 function int pthread_equal (pthread_t, pthread_t)
 function void pthread_exit (void*)
-# ifndef POSIX
+# if !defined POSIX && !defined POSIX2008
 function int pthread_getconcurrency (void)
 # endif
 function int pthread_getcpuclockid (pthread_t, clockid_t*)
@@ -135,12 +139,12 @@ function int pthread_rwlockattr_setpshared (pthread_rwlockattr_t*, int)
 function pthread_t pthread_self (void)
 function int pthread_setcancelstate (int, int*)
 function int pthread_setcanceltype (int, int*)
-# ifndef POSIX
+# if !defined POSIX && !defined POSIX2008
 function int pthread_setconcurrency (int)
 # endif
 function int pthread_setschedparam (pthread_t, int, const struct sched_param*)
 function int pthread_setspecific (pthread_key_t, const void*)
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int pthread_sigmask (int, const sigset_t*, sigset_t*)
 #endif
 function int pthread_spin_destroy (pthread_spinlock_t*)
@@ -149,6 +153,11 @@ function int pthread_spin_lock (pthread_spinlock_t*)
 function int pthread_spin_trylock (pthread_spinlock_t*)
 function int pthread_spin_unlock (pthread_spinlock_t*)
 function void pthread_testcancel (void)
+# if defined XOPEN2K8 || defined POSIX2008
+function int pthread_mutex_consistent (pthread_mutex_t *)
+function int pthread_mutexattr_getrobust (__const pthread_mutexattr_t*, int*)
+function int pthread_mutexattr_setrobust (pthread_mutexattr_t*, int)
+# endif
 
 allow-header sched.h
 allow-header time.h
index 1267708b98ce30ffca3aff37d285c7d223a64a87..a8edf27730bd375c829b208ab75a38d2cb6461cb 100644 (file)
@@ -9,15 +9,20 @@ element {struct passwd} {char*} pw_shell
 # ifndef POSIX
 type uid_t
 type gid_t
+#  if defined XOPEN2K8 || defined POSIX2008
+type size_t
+#  endif
 # endif
 
 function {struct passwd*} getpwnam (const char*)
 function {struct passwd*} getpwuid (uid_t)
 function int getpwnam_r (const char*, struct passwd*, char*, size_t, struct passwd**)
 function int getpwuid_r (uid_t, struct passwd*, char*, size_t, struct passwd**)
+# ifndef POSIX2008
 function void endpwent (void)
 function {struct passwd*} getpwent (void)
 function void setpwent (void)
+# endif
 
 allow pw_*
 allow *_t
index 38495d5b833c12ba9445c25eef6cb6fc0bff2fa9..73e06a826612f5d5c68467a127ae14e68b0de907 100644 (file)
@@ -28,7 +28,9 @@ constant REG_EBRACE
 constant REG_BADBR
 constant REG_ESPACE
 constant REG_BADRPT
+# if !defined XOPEN2K8 && !defined POSIX2008
 constant REG_ENOSYS
+# endif
 
 function int regcomp (regex_t*, const char*, int)
 function int regexec (const regex_t*, const char*, size_t, regmatch_t[], int)
index d4c5ae72cd5e9818315872d85585434c3345c652..585145011a024dee97d88e60abb5f4dd6b77d248 100644 (file)
@@ -6,6 +6,12 @@ optional-element {struct sched_param} {struct timespec} sched_ss_repl_period
 optional-element {struct sched_param} {struct timespec} sched_ss_init_budget
 optional-element {struct sched_param} int sched_ss_max_repl
 
+# if defined XOPEN2K8 || defined POSIX2008
+type pid_t
+type time_t
+type {struct timespec}
+# endif
+
 constant SCHED_FIFO
 constant SCHED_RR
 optional-constant SCHED_SPORADIC
index da7f2a13329af58e7721ed1af69059d9e06c5d0b..dadb1ff71cf0fa04f8e36b5d2e3cb102747f2c1d 100644 (file)
@@ -1,4 +1,4 @@
-#if !defined ISO && !defined POSIX
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type ENTRY
 type {struct entry}
 element {struct entry} {char*} key
index 20fe0706b7cd1099927730dfca8977ecf2f4d34e..5484884fff930ce7e02e858a2703da1a9a126395 100644 (file)
@@ -14,7 +14,7 @@ function int sem_trywait (sem_t*)
 function int sem_unlink (const char*)
 function int sem_wait (sem_t*)
 
-# if !defined POSIX
+# ifndef POSIX
 allow-header fcntl.h
 allow-header sys/types.h
 # endif
index ef29c9cbe801dbf0f08c26664daa8136587a2216..a89a33fa73b2b3406e2e7c84f04988398c6fdeb6 100644 (file)
@@ -6,7 +6,7 @@ type sigjmp_buf
 function void longjmp (jmp_buf, int)
 #ifndef ISO
 function void siglongjmp (sigjmp_buf, int)
-# ifndef POSIX
+# if !defined POSIX && !defined POSIX2008
 function void _longjmp (jmp_buf, int)
 # endif
 #endif
@@ -14,7 +14,7 @@ function void _longjmp (jmp_buf, int)
 macro-function int setjmp (jmp_buf)
 #ifndef ISO
 macro-function int sigsetjmp (sigjmp_buf, int)
-# ifndef POSIX
+# if !defined POSIX && !defined POSIX2008
 macro-function int _setjmp (jmp_buf)
 # endif
 #endif
index 95bd37299b977478eedb4eaf7e9eb5a29fd04d11..b48a1ff7da208e7664b370a8ead47f65639f0c1b 100644 (file)
@@ -6,6 +6,20 @@ typed-constant SIG_IGN {void(*)(int)}
 type sig_atomic_t
 type sigset_t
 type pid_t
+#if defined XOPEN2K8 || defined POSIX2008
+type size_t
+type pthread_t
+type uid_t
+
+type mcontext_t
+
+type ucontext_t
+
+element ucontext_t {ucontext_t*} uc_link
+element ucontext_t sigset_t uc_sigmask
+element ucontext_t stack_t uc_stack
+element ucontext_t mcontext_t uc_mcontext
+#endif
 
 element {union sigval} int sival_int
 element {union sigval} {void*} sival_ptr
@@ -52,7 +66,9 @@ constant SIGBUS
 constant SIGPOLL
 constant SIGPROF
 constant SIGSYS
+#if !defined POSIX && !defined POSIX2008
 constant SIGTRAP
+#endif
 constant SIGURG
 constant SIGVTALRM
 constant SIGXCPU
@@ -69,16 +85,20 @@ constant SA_NOCLDSTOP
 constant SIG_BLOCK
 constant SIG_UNBLOCK
 constant SIG_SETMASK
+#if !defined POSIX && !defined POSIX2008
 constant SA_ONSTACK
+#endif
 constant SA_RESETHAND
 constant SA_RESTART
 constant SA_SIGINFO
 constant SA_NOCLDWAIT
 constant SA_NODEFER
+#if !defined POSIX && !defined POSIX2008
 constant SS_ONSTACK
 constant SS_DISABLE
 constant MINSIGSTKSZ
 constant SIGSTKSZ
+#endif
 
 type ucontext_t
 
@@ -101,7 +121,9 @@ element {struct sigstack} {void*} ss_sp
 type siginfo_t
 
 element siginfo_t int si_signo
+#if !defined POSIX && !defined POSIX2008
 element siginfo_t int si_errno
+#endif
 element siginfo_t int si_code
 element siginfo_t pid_t si_pid
 element siginfo_t uid_t si_uid
@@ -153,32 +175,46 @@ constant SI_MESGQ
 
 function void (*bsd_signal (int, void(*)(int)))(int)
 function int kill (pid_t, int)
+#if !defined POSIX && !defined POSIX2008
 function int killpg (pid_t, int)
+#endif
 function int pthread_kill (pthread_t, int)
 function int pthread_sigmask (int, const sigset_t*, sigset_t*)
 function int raise (int)
 function int sigaction (int, const struct sigaction*, struct sigaction*)
 function int sigaddset (sigset_t*, int)
+#if !defined POSIX && !defined POSIX2008
 function int sigaltstack (const stack_t*, stack_t*)
+#endif
 function int sigdelset (sigset_t*, int)
 function int sigemptyset (sigset_t*)
 function int sigfillset (sigset_t*)
+#if !defined POSIX && !defined POSIX2008
 function int sighold (int)
 function int sigignore (int)
 function int siginterrupt (int, int)
+#endif
 function int sigismember (const sigset_t*, int)
 function void (*signal (int, void(*)(int)))(int)
+#if !defined POSIX && !defined POSIX2008
 function int sigpause (int)
+#endif
 function int sigpending (sigset_t*)
 function int sigprocmask (int, const sigset_t*, sigset_t*)
 function int sigqueue (pid_t, int, const union sigval)
+#if !defined POSIX && !defined POSIX2008
 function int sigrelse (int)
 function void (*sigset (int, void(*)(int)))(int)
+#endif
 function int sigstack (struct sigstack*, struct sigstack*)
 function int sigsuspend (const sigset_t*)
 function int sigtimedwait (const sigset_t*, siginfo_t*, const struct timespec*)
 function int sigwait (const sigset_t*, int*)
 function int sigwaitinfo (const sigset_t*, siginfo_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function void psiginfo (const siginfo_t*, const char*)
+function void psignal (int, const char*)
+#endif
 
 // The following expressions are not entirely correct but the current
 // poorfnmatch implementation doesn't grok the right form.
index 8afca02216fe6024b7deddbbd9eeb2bc724656ac..81f32d030887ed1dd7486216af79325edb122a81 100644 (file)
@@ -1,6 +1,12 @@
 #ifndef ISO
 type posix_spawnattr_t
 type posix_spawn_file_actions_t
+# if defined XOPEN2K8 || defined POSIX2008
+type mode_t
+type pid_t
+type sigset_t
+type {struct sched_param}
+# endif
 
 constant POSIX_SPAWN_RESETIDS
 constant POSIX_SPAWN_SETPGROUP
index c3f071e8f9c9a16027b405b881ab52aeef5e191d..fcc61c9df47ae4750c0701d9f717c0eac176a3c2 100644 (file)
@@ -7,7 +7,9 @@ constant _IOLBF
 constant _IONBF
 
 constant L_ctermid
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 constant L_cuserid
+#endif
 constant L_tmpnam
 
 constant SEEK_CUR
@@ -20,7 +22,9 @@ constant EOF
 
 constant NULL
 
+#if !defined POSIX && !defined POSIX2008
 constant P_tmpdir
+#endif
 
 macro stdin
 macro stdout
@@ -30,10 +34,16 @@ type FILE
 type fpos_t
 type va_list
 type size_t
+#if defined XOPEN2K8 || defined POSIX2008
+type off_t
+#endif
 
 function void clearerr (FILE*)
 function {char*} ctermid (char*)
 function {char*} cuserid (char*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int dprintf (int, const char*, ...)
+#endif
 function int fclose (FILE*)
 function {FILE*} fdopen (int, const char*)
 function int feof (FILE*)
@@ -44,6 +54,9 @@ function int fgetpos (FILE*, fpos_t*)
 function {char*} fgets (char*, int, FILE*)
 function int fileno (FILE*)
 function void flockfile (FILE*)
+#if defined XOPEN2K8 || defined POSIX2008
+function {FILE*} fmemopen (void*, size_t, const char*)
+#endif
 function {FILE*} fopen (const char*, const char*)
 function int fprintf (FILE*, const char*, ...)
 function int fputc (int, FILE*)
@@ -63,13 +76,20 @@ function int getc (FILE*)
 function int getchar (void)
 function int getc_unlocked (FILE*)
 function int getchar_unlocked ()
-#ifndef XOPEN2K
+#if defined XOPEN2K8 || defined POSIX2008
+function ssize_t getdelim (char**, size_t*, int, FILE*)
+function ssize_t getline (char**, size_t*, FILE*)
+#endif
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int getopt (int, char *const[], const char *)
 #endif
 function {char*} gets (char*)
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int getw (FILE*)
 #endif
+#if defined XOPEN2K8 || defined POSIX2008
+function {FILE*} open_memstream (char**, size_t*)
+#endif
 function int pclose (FILE*)
 function void perror (const char*)
 function {FILE*} popen (const char*, const char*)
@@ -79,11 +99,14 @@ function int putchar (int)
 function int putc_unlocked (int, FILE*)
 function int putchar_unlocked (int)
 function int puts (const char*)
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int putw (int, FILE*)
 #endif
 function int remove (const char*)
 function int rename (const char*, const char*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int renameat (int, const char*, int, const char*)
+#endif
 function void rewind (FILE*)
 function int scanf (const char*, ...)
 function void setbuf (FILE*, char*)
@@ -91,26 +114,31 @@ function int setvbuf (FILE*, char*, int, size_t)
 function int snprintf (char*, size_t, const char*, ...)
 function int sprintf (char *, const char *, ...)
 function int sscanf (const char*, const char*, ...)
+#if !defined POSIX && !defined POSIX2008
 function {char*} tempnam (const char*, const char*)
+#endif
 function {FILE*} tmpfile (void)
 function {char*} tmpnam (char*)
 function int ungetc (int, FILE*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int vdprintf (int, const char*, va_list)
+#endif
 function int vfprintf (FILE*, const char*, va_list)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function int vfscanf (FILE*, const char*, va_list)
 #endif
 function int vprintf (const char*, va_list)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function int vscanf (const char*, va_list)
 #endif
 function int vsnprintf (char*, size_t, const char*, va_list)
 function int vsprintf (char*, const char*, va_list)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function int vsscanf (const char*, const char*, va_list)
 #endif
 
 #if !defined ISO && !defined POSIX
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 variable {char*} optarg
 variable int opterr
 variable int optind
index c639bb52d0d293496671f18153bc5b08223797b3..760b5b3b4c0a7534b5b8102ced0c1e9541eeea06 100644 (file)
@@ -10,7 +10,7 @@ element div_t int rem
 type ldiv_t
 element ldiv_t long quot
 element ldiv_t long rem
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 type lldiv_t
 element lldiv_t {long long} quot
 element lldiv_t {long long} rem
@@ -29,77 +29,116 @@ macro WSTOPSIG
 macro WTERMSIG
 
 function void _Exit (int)
+#if !defined POSIX && !defined POSIX2008
 function long a64l (const char*)
+#endif
 function void abort (void)
 function int abs (int)
 function int atexit (void(*)(void))
 function double atof (const char*)
 function int atoi (const char*)
 function {long int} atol (const char*)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function {long long} atoll (const char*)
 #endif
 function {void*} bsearch (const void*, const void*, size_t, size_t, int(*)(const void*, const void*))
 function {void*} calloc (size_t, size_t)
 function div_t div (int, int)
+#if !defined POSIX && !defined POSIX2008
 function double drand48 (void)
+#endif
+#if !defined POSIX && !defined XOPEN2K8 && !defined POSIX2008
 function {char*} ecvt (double, int, int*, int*)
+#endif
+#if !defined POSIX && !defined POSIX2008
 function double erand48 (unsigned short int[3])
+#endif
 function void exit (int)
+#if !defined POSIX && !defined XOPEN2K8 && !defined POSIX2008
 function {char*} fcvt (double, int, int*, int*)
+#endif
 function void free (void*)
+#if !defined POSIX && !defined XOPEN2K8 && !defined POSIX2008
 function {char*} gcvt (double, int, char*)
+#endif
 function {char*} getenv (const char*)
 function int getsubopt (char**, char *const*, char**)
+#if !defined POSIX && !defined POSIX2008
 function int grantpt (int)
 function {char*} initstate (unsigned int, char*, size_t)
 function {long int} jrand48 (unsigned short int[3])
 function {char*} l64a (long)
+#endif
 function {long int} labs (long int)
+#if !defined POSIX && !defined POSIX2008
 function void lcong48 (unsigned short int[7])
+#endif
 function ldiv_t ldiv (long int, long int)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function {long long} llabs (long long)
 function lldiv_t lldiv (long long, long long)
 #endif
+#if !defined POSIX && !defined POSIX2008
 function {long int} lrand48 (void)
+#endif
 function {void*} malloc (size_t)
 function int mblen (const char*, size_t)
 function size_t mbstowcs (wchar_t*, const char*, size_t)
 function int mbtowc (wchar_t*, const char*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function {char*} mkdtemp (char*)
+#endif
+#if !defined XOPEN2K8 && !defined POSIX2008
 function {char*} mktemp (char*)
+#endif
 function int mkstemp (char*)
+#if !defined POSIX && !defined POSIX2008
 function {long int} mrand48 (void)
 function {long int} nrand48 (unsigned short int[3])
+#endif
 function int posix_memalign (void**, size_t, size_t)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8
 function int posix_openpt (int)
 #endif
+#if !defined POSIX && !defined POSIX2008
 function {char*} ptsname (int)
 function int putenv (char*)
+#endif
 function void qsort (void*, size_t, size_t, int(*)(const void*, const void*))
 function int rand (void)
 function int rand_r (unsigned int*)
+#if !defined POSIX && !defined POSIX2008
 function long random (void)
+#endif
 function {void*} realloc (void*, size_t)
+#if !defined POSIX && !defined POSIX2008
 function {char*} realpath (const char*, char*)
 function {unsigned short int*} seed48 (unsigned short int[3])
+#endif
 function int setenv (const char*, const char*, int)
+#if !defined POSIX && !defined POSIX2008
 function void setkey (const char*)
 function {char*} setstate (char*)
+#endif
 function void srand (unsigned int)
+#if !defined POSIX && !defined POSIX2008
 function void srand48 (long int)
 function void srandom (unsigned)
+#endif
 function double strtod (const char*, char**)
 function {long int} strtol (const char*, char**, int)
 function {unsigned long int} strtoul (const char*, char**, int)
 function int system (const char*)
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int ttyslot (void)
 #endif
+#if !defined POSIX && !defined POSIX2008
 function int unlockpt (int)
+#endif
 function int unsetenv (const char*)
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008
 function {void*} valloc (size_t)
+#endif
 function size_t wcstombs (char*, const wchar_t*, size_t)
 function int wctomb (char*, wchar_t)
 
index 19c06d292cfe1cc8e5e7a7966f71a1f8f1cd72a5..1c4ae0814e7740fcdb5f897014f9fa1d2796c1cc 100644 (file)
@@ -1,35 +1,61 @@
 constant NULL
 
 type size_t
+#if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+#endif
 
+#if !defined POSIX && !defined POSIX2008
 function {void*} memccpy (void*, const void*, int, size_t)
+#endif
 function {void*} memchr (const void*, int, size_t)
 function int memcmp (const void*, const void*, size_t)
 function {void*} memcpy (void*, const void*, size_t)
 function {void*} memmove (void*, const void*, size_t)
 function {void*} memset (void*, int, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function {char*} stpcpy (char*, const char*)
+function {char*} stpncpy (char*, const char*, size_t)
+
+#endif
 function {char*} strcat (char*, const char*)
 function {char*} strchr (const char*, int)
 function int strcmp (const char*, const char*)
 function int strcoll (const char*, const char*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int strcoll_l (const char*, const char*, locale_t)
+#endif
 function {char*} strcpy (char*, const char*)
 function size_t strcspn (const char*, const char*)
 function {char*} strdup (const char*)
 function {char*} strerror (int)
-#ifdef XOPEN2K
+#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008
 function int strerror_r (int, char*, size_t)
 #endif
+#if defined XOPEN2K8 || defined POSIX2008
+function {char*} strerror_l (int, locale_t)
+#endif
 function size_t strlen (const char*)
 function {char*} strncat (char*, const char*, size_t)
 function int strncmp (const char*, const char*, size_t)
 function {char*} strncpy (char*, const char*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function {char*} strndup (const char*, size_t)
+function size_t strnlen (const char*, size_t)
+#endif
 function {char*} strpbrk (const char*, const char*)
 function {char*} strrchr (const char*, int)
+#if defined XOPEN2K8 || defined POSIX2008
+function {char*} strsignal (int)
+#endif
 function size_t strspn (const char*, const char*)
 function {char*} strstr (const char*, const char*)
 function {char*} strtok (char*, const char*)
 function {char*} strtok_r (char*, const char*, char**)
 function size_t strxfrm (char*, const char*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function size_t strxfrm_l (char*, const char*, size_t, locale_t)
+#endif
 
 allow-header stddef.h
 
index 201780c8d3fe5a5cd2c1900b1b4e43d3060082a2..fb4f02c75ddac7f87c38509a0c0640d1a9848238 100644 (file)
@@ -1,12 +1,21 @@
 function int bcmp (const void*, const void*, size_t)
 function void bcopy (const void*, void*, size_t)
 function void bzero (void*, size_t)
+#if !defined POSIX && !defined POSIX2008
 function int ffs (int)
+#endif
 function {char*} index (const char*, int)
 function {char*} rindex (const char*, int)
 function int strcasecmp (const char*, const char*)
 function int strncasecmp (const char*, const char*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function int strcasecmp_l (const char*, const char*, locale_t)
+function int strncasecmp_l (const char*, const char*, size_t, locale_t)
+#endif
 
 type size_t
+#if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+#endif
 
 allow *_t
index 1b2ec99d373f1b0944b4baedc8873a8190b10f24..28918c196dad36fd5026ba186320a425c5448266 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct ipc_perm}
 
 element {struct ipc_perm} uid_t uid
@@ -26,3 +27,4 @@ function key_t ftok (const char*, int)
 allow ipc_*
 allow IPC_*
 allow *_t
+#endif
index 7a1df4cbed3f3535c6e33612038c751801302b34..ae83356b5445ebf9162cc0917d54a68719349362 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct msqid_ds}
 
 type msgqnum_t
@@ -30,3 +31,4 @@ allow-header sys/ipc.h
 allow msg*
 allow MSG*
 allow *_h
+#endif
index d9f9b9ab8c5e8c3b9df08ac7dc7166caa72a92dd..52f83f523bcfc4481a473a36373fbbe0785d7350 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 constant PRIO_PROCESS
 constant PRIO_PGRP
 constant PRIO_USER
@@ -48,3 +49,4 @@ allow RLIM_*
 allow RLIMIT_*
 allow RUSAGE_*
 allow *_t
+#endif
index 8b4598b7b2dc0732479e43e9a4f5e0839eea00aa..665b397c584ff84f7c7d48d6becb0621ce14b9f7 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 constant SEM_UNDO
 
 constant GETNCNT
@@ -35,3 +36,4 @@ allow-header sys/ipc.h
 allow sem*
 allow SEM_*
 allow *_t
+#endif
index cac01634061fa9964c17433413ee2e18fe10cfa4..39df8944ab2bfa82c7a332d27e082a27fd9ef4e3 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 constant SHM_RDONLY
 symbol SHMLBA
 constant SHM_RND
@@ -30,3 +31,4 @@ allow-header sys/ipc.h
 allow shm*
 allow SHM*
 allow *_t
+#endif
index dd1f265b2bd5639083cdea9cb4fae1ea5f13bc07..5fdd6cf6bf4494f380ca93c00c53514b5d04f433 100644 (file)
@@ -3,6 +3,11 @@ type socklen_t
 
 type sa_family_t
 
+# if defined XOPEN2K8 || defined POSIX2008
+type size_t
+type ssize_t
+# endif
+
 type {struct sockaddr}
 
 element {struct sockaddr} sa_family_t sa_family
@@ -76,6 +81,9 @@ macro MSG_OOB
 macro MSG_PEEK
 macro MSG_TRUNC
 macro MSG_WAITALL
+# if defined XOPEN2K8 || defined POSIX2008
+constant MSG_NOSIGNAL
+# endif
 
 macro AF_UNIX
 macro AF_UNSPEC
index c0f8d45a388193d64d08cbfe7bd31afd218b4df9..72c656f19e29534c6d83576ef1e680507b9d3b23 100644 (file)
@@ -8,13 +8,17 @@ element {struct stat} mode_t st_mode
 element {struct stat} nlink_t st_nlink
 element {struct stat} uid_t st_uid
 element {struct stat} gid_t st_gid
+#if !defined POSIX && !defined POSIX2008
 element {struct stat} dev_t st_rdev
+#endif
 element {struct stat} off_t st_size
 element {struct stat} time_t st_atime
 element {struct stat} time_t st_mtime
 element {struct stat} time_t st_ctime
+#if !defined POSIX && !defined POSIX2008
 element {struct stat} blksize_t st_blksize
 element {struct stat} blkcnt_t st_blocks
+#endif
 
 type blkcnt_t
 type blksize_t
@@ -26,7 +30,13 @@ type uid_t
 type gid_t
 type off_t
 type time_t
+# ifdef XOPEN2K8
+type {struct timespec}
+element {struct timespec} time_t tv_sec
+element {struct timespec} long tv_nsec
+# endif
 
+#if !defined POSIX && !defined POSIX2008
 constant S_IFMT
 constant S_IFBLK
 constant S_IFCHR
@@ -34,6 +44,8 @@ constant S_IFIFO
 constant S_IFREG
 constant S_IFDIR
 constant S_IFLNK
+constant S_IFSOCK
+#endif
 
 constant S_IRWXU
 constant S_IRUSR
@@ -48,14 +60,20 @@ constant S_IWOTH
 constant S_IXOTH
 constant S_ISUID
 constant S_ISGID
+#if !defined POSIX && !defined POSIX2008
 constant S_ISVTX
+#endif
 
+#if !defined POSIX && !defined POSIX2008
+macro S_IFMT
 macro S_ISBLK
 macro S_ISCHR
 macro S_ISDIR
 macro S_ISFIFO
 macro S_ISREG
 macro S_ISLNK
+macro S_IFSOCK
+#endif
 
 // How to represent optional tests?
 optional-macro S_TYPEISMQ
@@ -63,15 +81,41 @@ optional-macro S_TYPEISSEM
 optional-macro S_TYPEISSHM
 optional-macro S_TYPEISTMO
 
+# if defined XOPEN2K8 || defined POSIX2008
+constant UTIME_NOW
+constant UTIME_OMIT
+# endif
+
 function int chmod (const char*, mode_t)
 function int fchmod (int, mode_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function int fchmodat (int, const char*, mode_t, int)
+# endif
 function int fstat (int, struct stat*)
+# if defined XOPEN2K8 || defined POSIX2008
+function int fstatat (int, const char*, struct stat*, int)
+function int futimens (int, const struct timespec[2])
+# endif
 function int lstat (const char*, struct stat*)
 function int mkdir (const char*, mode_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function int mkdirat (int, const char*, mode_t)
+# endif
 function int mkfifo (const char*, mode_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function int mkfifoat (int, const char*, mode_t)
+# endif
+# if !defined POSIX && !defined POSIX2008
 function int mknod (const char*, mode_t, dev_t)
+# endif
+# if defined XOPEN2K8 || defined POSIX2008
+function int mknodat (int, const char*, mode_t, dev_t)
+# endif
 function int stat (const char*, struct stat*)
 function mode_t umask (mode_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function int utimensat (int, const char*, const struct timespec[2], int)
+# endif
 
 allow st_*
 allow S_*
index 174708b53dc5aa9f60bd3d08b31bd883a44b4326..7e3407ab07634ff6a371f5ccbd212e5e092bb8be 100644 (file)
@@ -1,4 +1,4 @@
-#ifndef ISO
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct timeval}
 
 element {struct timeval} time_t tv_sec
index ed7236b8b61d8d3cf4914228805e73cb3aee6095..be61d087515a609895f6bc9b682bdca4907cd999 100644 (file)
@@ -1,14 +1,19 @@
+#ifndef ISO
 type blkcnt_t
 type blksize_t
 type clock_t
 type clockid_t
 type dev_t
+# if !defined POSIX && !defined POSIX2008
 type fsblkcnt_t
 type fsfilcnt_t
+# endif
 type gid_t
 type id_t
 type ino_t
+# if !defined POSIX && !defined POSIX2008
 type key_t
+# endif
 type mode_t
 type nlink_t
 type off_t
@@ -28,10 +33,13 @@ type pthread_spinlock_t
 type pthread_t
 type size_t
 type ssize_t
+# if !defined POSIX && !defined POSIX2008
 type suseconds_t
+# endif
 type time_t
 type timer_t
 type uid_t
 type useconds_t
 
 allow *_t
+#endif
index 258032b871545ae4ffbccff1732e9b0d5bba8dfd..7833e722687ed3410925859f9934d3cdd902458d 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct iovec}
 
 element {struct iovec} {void*} iov_base
@@ -10,3 +11,4 @@ allow iov_*
 allow IOV_*
 allow *_t
 allow UIO_MAXIOV
+#endif
index 731c9551f7d99b39b6401258bf3734ad2c52aa6e..81c0dc44f8ca28c0ed869dfcb61dbbfa67844498 100644 (file)
@@ -1,8 +1,11 @@
+#ifndef ISO
 constant WNOHANG
 constant WUNTRACED
 
 macro WEXITSTATUS
+# if !defined POSIX && !defined POSIX2008
 macro WIFCONTINUED
+# endif
 macro WIFEXITED
 macro WIFSIGNALED
 macro WIFSTOPPED
@@ -11,7 +14,9 @@ macro WTERMSIG
 
 constant WEXITED
 constant WSTOPPED
+# if !defined POSIX && !defined POSIX2008
 constant WCONTINUED
+# endif
 constant WNOHANG
 constant WNOWAIT
 
@@ -62,3 +67,4 @@ allow SEGV_
 allow SI_
 allow TRAP_
 allow *_t
+#endif
index 87414e8a7ea8d7b3a9aee11ffd829e50e7c2712a..f0aa65c69378e2a3846ce930e5386476d3e36b63 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 constant LOG_PID
 constant LOG_CONS
 constant LOG_NDELAY
@@ -40,3 +41,4 @@ function void syslog (int, const char*, ...)
 
 allow LOG_*
 allow *_t
+#endif
index 919167d92b952cec026fc597834c2fffaa37b074..fcbfb127b4605b878f2b092a8892416b11a8c2a0 100644 (file)
@@ -1,3 +1,4 @@
+#ifndef ISO
 macro-str TMAGIC "ustar"
 constant TMAGLEN 6
 macro-str TVERSION "00"
@@ -15,7 +16,9 @@ constant CONTTYPE
 
 constant TSUID 04000
 constant TSGID 02000
+# if !defined POSIX && !defined POSIX2008
 constant TSVTX 01000
+# endif
 constant TUREAD 00400
 constant TUWRITE 00200
 constant TUEXEC 00100
@@ -27,3 +30,4 @@ constant TOWRITE 00002
 constant TOEXEC 00001
 
 allow *_t
+#endif
index d867d4cd6ba101710cfca1804fd2e05e000d717e..d32bd6bf3c9ccb60325a1fb214819e4eff209e68 100644 (file)
@@ -1,9 +1,14 @@
+#ifndef ISO
 type cc_t
 type speed_t
 type tcflag_t
 
 type {struct termios}
 
+#if defined XOPEN2K8 || defined POSIX2008
+type pid_t
+#endif
+
 element {struct termios} tcflag_t c_iflag
 element {struct termios} tcflag_t c_oflag
 element {struct termios} tcflag_t c_cflag
@@ -32,18 +37,24 @@ constant IGNPAR
 constant INLCR
 constant INPCK
 constant ISTRIP
+# if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 constant IUCLC
+# <endif
 constant IXANY
 constant IXOFF
 constant IXON
 constant PARMRK
 
 constant OPOST
+# if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 constant OLCUC
+# endif
+# if !defined POSIX && !defined POSIX2008
 constant ONLCR
 constant OCRNL
 constant ONOCR
 constant ONLRET
+constant OFDEL
 constant OFILL
 constant NLDLY
 constant NL0
@@ -67,6 +78,7 @@ constant VT1
 constant FFDLY
 constant FF0
 constant FF1
+# endif
 
 constant B0
 constant B50
@@ -106,7 +118,9 @@ constant IEXTEN
 constant ISIG
 constant NOFLSH
 constant TOSTOP
+# if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 constant XCASE
+# endif
 
 constant TCSANOW
 constant TCSADRAIN
@@ -157,3 +171,4 @@ allow O*
 allow TC*
 allow B*
 allow *_t
+#endif
index 805c48dd6fa376d88076e96c308f2c268b4393b0..631cb76a1e104625ca12a36875021000f3a66bff 100644 (file)
@@ -11,7 +11,7 @@ element {struct tm} int tm_yday
 element {struct tm} int tm_isdst
 
 constant NULL
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 constant CLK_TCK
 #endif
 constant CLOCKS_PER_SEC
@@ -38,6 +38,12 @@ type size_t
 type time_t
 type timer_t
 
+#if defined XOPEN2K8 || defined POSIX2008
+type pid_t
+type locale_t
+tag {struct sigevent}
+#endif
+
 variable int getdate_err
 
 function {char*} asctime (const struct tm*)
@@ -51,7 +57,9 @@ function int clock_settime (clockid_t, const struct timespec*)
 function {char*} ctime (const time_t*)
 function {char*} ctime_r (const time_t*, char*)
 function double difftime (time_t, time_t)
+#if !defined POSIX && !defined POSIX2008
 function {struct tm*} getdate (const char*)
+#endif
 function {struct tm*} gmtime (const time_t*)
 function {struct tm*} gmtime_r (const time_t*, struct tm*)
 function {struct tm*} localtime (const time_t*)
@@ -59,7 +67,12 @@ function {struct tm*} localtime_r (const time_t*, struct tm*)
 function time_t mktime (struct tm*)
 function int nanosleep (const struct timespec*, struct timespec*)
 function size_t strftime (char*, size_t, const char*, const struct tm*)
+#if defined XOPEN2K8 || defined POSIX2008
+function size_t strftime_l (char*, size_t, const char*, const struct tm*, locale_t)
+#endif
+#if !defined POSIX && !defined POSIX2008
 function {char*} strptime (const char*, const char*, struct tm*)
+#endif
 function time_t time (time_t*)
 function int timer_create (clockid_t, struct sigevent*, timer_t*)
 function int timer_delete (timer_t)
@@ -68,8 +81,10 @@ function int timer_getoverrun (timer_t)
 function int timer_settime (timer_t, int, const struct itimerspec*, struct itimerspec*)
 function void tzset (void)
 
+#if !defined POSIX && !defined POSIX2008
 variable int daylight
 variable {long int} timezone
+#endif
 variable {char*} tzname [2]
 
 allow tm_*
index 84ab56c1d174402eacad6426b2a729c8870f9b3f..9e7e6f4e9a2688e7c3b69381f3d75e794874cadc 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 constant UL_GETFSIZE
 constant UL_SETFSIZE
 
@@ -5,3 +6,4 @@ function {long int} ulimit (int, ...)
 
 allow UL_*
 allow *_t
+#endif
index b6effa064e37625ee2fed01806d5dfc2078a0184..96cdf6a3aa8bc0c836fa01c4e7d9520ef981b3bc 100644 (file)
@@ -41,10 +41,24 @@ optional-constant _POSIX_THREAD_PROCESS_SHARED
 optional-constant _POSIX_THREAD_SAFE_FUNCTIONS
 optional-constant _POSIX_THREAD_SPORADIC_SERVER
 
+# ifdef XOPEN2K
+optional-constant _POSIX_V6_ILP32_OFF32
+optional-constant _POSIX_V6_ILP32_OFFBIG
+optional-constant _POSIX_V6_LP64_OFF64
+optional-constant _POSIX_V6_LPBIG_OFFBIG
+# endif
+# if defined XOPEN2K8 || defined POSIX2008
+optional-constant _POSIX_V7_ILP32_OFF32
+optional-constant _POSIX_V7_ILP32_OFFBIG
+optional-constant _POSIX_V7_LP64_OFF64
+optional-constant _POSIX_V7_LPBIG_OFFBIG
+# endif
+
 optional-constant _POSIX2_C_DEV
 optional-constant _POSIX2_FORT_DEV
 optional-constant _POSIX2_FORT_RUN
 optional-constant _POSIX2_SW_DEV
+# if !defined POSIX && !defined POSIX2008
 optional-constant _XOPEN_CRYPT
 optional-constant _XOPEN_ENH_I18N
 optional-constant _XOPEN_LEGACY
@@ -52,6 +66,7 @@ optional-constant _XOPEN_REALTIME
 optional-constant _XOPEN_REALTIME_THREADS
 optional-constant _XOPEN_SHM
 optional-constant _XOPEN_STREAMS
+# endif
 allow _XBS5_ILP32_OFF32
 allow _XBS5_ILP32_OFBIG
 allow _XBS5_LP64_OFF64
@@ -89,6 +104,8 @@ optional-constant _POSIX2_PBS_LOCATE
 optional-constant _POSIX2_PBS_MESSAGE
 optional-constant _POSIX2_PBS_TRACK
 
+optional-constant _POSIX_TIMESTAMP_RESOLUTION
+
 constant NULL
 
 constant R_OK
@@ -219,7 +236,20 @@ constant _SC_TYPED_MEMORY_OBJECTS
 constant _SC_TZNAME_MAX
 constant _SC_USER_GROUPS
 constant _SC_USER_GROUPS_R
+# ifdef XOPEN2K
+constant _SC_V6_ILP32_OFF32
+constant _SC_V6_ILP32_OFFBIG
+constant _SC_V6_LP64_OFF64
+constant _SC_V6_LPBIG_OFFBIG
+# endif
+# if defined XOPEN2K8 || defined POSIX2008
+constant _SC_V7_ILP32_OFF32
+constant _SC_V7_ILP32_OFFBIG
+constant _SC_V7_LP64_OFF64
+constant _SC_V7_LPBIG_OFFBIG
+# endif
 constant _SC_VERSION
+# if !defined POSIX && !defined POSIX2008
 constant _SC_XOPEN_VERSION
 constant _SC_XOPEN_CRYPT
 constant _SC_XOPEN_ENH_I18N
@@ -229,11 +259,46 @@ constant _SC_XOPEN_XCU_VERSION
 constant _SC_XOPEN_LEGACY
 constant _SC_XOPEN_REALTIME
 constant _SC_XOPEN_REALTIME_THREADS
+# endif
 constant _SC_STREAMS
 constant _SC_XBS5_ILP32_OFF32
 constant _SC_XBS5_ILP32_OFFBIG
 constant _SC_XBS5_LP64_OFF64
 constant _SC_XBS5_LPBIG_OFFBIG
+# ifdef XOPEN2K
+constant _CS_POSIX_V6_ILP32_OFF32_CFLAGS
+constant _CS_POSIX_V6_ILP32_OFF32_LDFLAGS
+constant _CS_POSIX_V6_ILP32_OFF32_LIBS
+constant _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS
+constant _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS
+constant _CS_POSIX_V6_ILP32_OFFBIG_LIBS
+constant _CS_POSIX_V6_LP64_OFF64_CFLAGS
+constant _CS_POSIX_V6_LP64_OFF64_LDFLAGS
+constant _CS_POSIX_V6_LP64_OFF64_LIBS
+constant _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS
+constant _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS
+constant _CS_POSIX_V6_LPBIG_OFFBIG_LIBS
+constant _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS
+constant _CS_V6_ENV
+# endif
+# if defined XOPEN2K8 || defined POSIX2008
+constant _CS_POSIX_V7_ILP32_OFF32_CFLAGS
+constant _CS_POSIX_V7_ILP32_OFF32_LDFLAGS
+constant _CS_POSIX_V7_ILP32_OFF32_LIBS
+constant _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS
+constant _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS
+constant _CS_POSIX_V7_ILP32_OFFBIG_LIBS
+constant _CS_POSIX_V7_LP64_OFF64_CFLAGS
+constant _CS_POSIX_V7_LP64_OFF64_LDFLAGS
+constant _CS_POSIX_V7_LP64_OFF64_LIBS
+constant _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS
+constant _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS
+constant _CS_POSIX_V7_LPBIG_OFFBIG_LIBS
+constant _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS
+constant _CS_V7_ENV
+# endif
+constant _SC_THREAD_ROBUST_PRIO_INHERIT
+constant _SC_THREAD_ROBUST_PRIO_PROTECT
 
 constant F_LOCK
 constant F_ULOCK
@@ -283,14 +348,18 @@ function int chroot (const char*)
 function int chown (const char*, uid_t, gid_t)
 function int close (int)
 function size_t confstr (int, char*, size_t)
+#if !defined POSIX && !defined POSIX2008
 function {char*} crypt (const char*, const char*)
+#endif
 function {char*} ctermid (char*)
 #if defined XPG3 || defined XPG4 || defined UNIX98
 function {char*} cuserid (char*)
 #endif
 function int dup (int)
 function int dup2 (int, int)
+#if !defined POSIX && !defined POSIX2008
 function void encrypt (char[64], int)
+#endif
 function int execl (const char*, const char*, ...)
 function int execle (const char*, const char*, ...)
 function int execlp (const char*, const char*, ...)
@@ -298,9 +367,18 @@ function int execv (const char*, char *const[])
 function int execve (const char*, char *const[], char *const[])
 function int execvp (const char*, char *const[])
 function void _exit (int)
+# if defined XOPEN2K8 || defined POSIX2008
+function int faccessat (int, const char*, int, int)
+# endif
 function int fchown (int, uid_t, gid_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function int fchownat (int, const char*, uid_t, gid_t, int)
+# endif
 function int fchdir (int)
 function int fdatasync (int)
+# if defined XOPEN2K8 || defined POSIX2008
+function int fexecve (int, char *const[], char *const[])
+# endif
 function pid_t fork (void)
 function {long int} fpathconf (int, int)
 function int fsync (int)
@@ -311,7 +389,9 @@ function gid_t getegid (void)
 function uid_t geteuid (void)
 function gid_t getgid (void)
 function int getgroups (int, gid_t[])
+#if !defined POSIX && !defined POSIX2008
 function long gethostid (void)
+#endif
 function int gethostname (char*, size_t)
 function {char*} getlogin (void)
 function int getlogin_r (char*, size_t)
@@ -330,34 +410,53 @@ function {char*} getwd (char*)
 function int isatty (int)
 function int lchown (const char*, uid_t, gid_t)
 function int link (const char*, const char*)
+# if defined XOPEN2K8 || defined POSIX2008
+function int linkat (int, const char*, int, const char*, int)
+# endif
+# if !defined POSIX && !defined POSIX2008
 function int lockf (int, int, off_t)
+# endif
 function off_t lseek (int, off_t, int)
+# if !defined POSIX && !defined POSIX2008
 function int nice (int)
+# endif
 function {long int} pathconf (const char*, int)
 function int pause (void)
 function int pipe (int[2])
 function ssize_t pread (int, void*, size_t, off_t)
-#ifndef XOPEN2K
+#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
 function int pthread_atfork (void(*)(void), void(*)(void), void(*)(void))
 #endif
 function ssize_t pwrite (int, const void*, size_t, off_t)
 function ssize_t read (int, void*, size_t)
 function ssize_t readlink (const char*, char*, size_t)
+# if defined XOPEN2K8 || defined POSIX2008
+function ssize_t readlinkat (int, const char*, char*, size_t)
+# endif
 function int rmdir (const char*)
 function {void*} sbrk (intptr_t)
 function int setegid (gid_t)
 function int seteuid (uid_t)
 function int setgid (gid_t)
 function int setpgid (pid_t, pid_t)
+# if !defined POSIX && !defined POSIX2008
 function pid_t setpgrp (void)
 function int setregid (gid_t, gid_t)
 function int setreuid (uid_t, uid_t)
+# endif
 function pid_t setsid (void)
 function int setuid (uid_t)
 function {unsigned int} sleep (unsigned int)
+# if !defined POSIX && !defined POSIX2008
 function void swab (const void*, void*, ssize_t)
+# endif
 function int symlink (const char*, const char*)
+# if defined XOPEN2K8 || defined POSIX2008
+function int symlinkat (const char*, int, const char*)
+# endif
+# if !defined POSIX && !defined POSIX2008
 function void sync (void)
+# endif
 function {long int} sysconf (int)
 function pid_t tcgetpgrp (int)
 function int tcsetpgrp (int, pid_t)
@@ -366,6 +465,9 @@ function {char*} ttyname (int)
 function int ttyname_r (int, char*, size_t)
 function useconds_t ualarm (useconds_t, useconds_t)
 function int unlink (const char*)
+# if defined XOPEN2K8 || defined POSIX2008
+function int unlinkat (int, const char*, int)
+# endif
 function int usleep (useconds_t)
 function pid_t vfork (void)
 function ssize_t write (int, const void*, size_t)
index ba034f0debc3d85bf88de4e1efa70c76bd4db58b..af3c229fc0786c4991abaddf5da6dc5a4e5fdfc1 100644 (file)
@@ -1,3 +1,4 @@
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 type {struct utmpx}
 
 element {struct utmpx} char ut_user []
@@ -34,3 +35,4 @@ allow-header sys/time.h
 
 allow ut_*
 allow *_t
+#endif
index 7c1589506a14c5b5ad382007fc513077dafde0ec..0911f12e48f3589a5173e767cc8fe5c62c3deaf0 100644 (file)
@@ -1,14 +1,19 @@
 type wchar_t
 type wint_t
+# if !defined ISO && !defined POSIX && !defined POSIX2008
 type wctype_t
+#endif
 type mbstate_t
 type FILE
 type size_t
+#if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+#endif
 
 function wint_t btowc (int)
 function int fwprintf (FILE*, const wchar_t*, ...)
 function int fwscanf (FILE*, const wchar_t*, ...)
-#if !ISO
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function int iswalnum (wint_t)
 function int iswalpha (wint_t)
 function int iswcntrl (wint_t)
@@ -32,13 +37,21 @@ function wint_t getwchar (void)
 function int mbsinit (const mbstate_t*)
 function size_t mbrlen (const char*, size_t, mbstate_t*)
 function size_t mbrtowc (wchar_t*, const char*, size_t, mbstate_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function size_t mbsnrtowcs (wchar_t*, const char**, size_t, size_t, mbstate_t*)
+#endif
 function size_t mbsrtowcs (wchar_t*, const char**, size_t, mbstate_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function {FILE*} open_wmemstream (wchar_t**, size_t*)
+#endif
 function wint_t putwc (wchar_t, FILE*)
 function wint_t putwchar (wchar_t)
 function int swprintf (wchar_t*, size_t, const wchar_t*, ...)
 function int swscanf (const wchar_t*, const wchar_t*, ...)
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function wint_t towlower (wint_t)
 function wint_t towupper (wint_t)
+#endif
 function wint_t ungetwc (wint_t, FILE*)
 function int vfwprintf (FILE*, const wchar_t*, va_list)
 function int vfwscanf (FILE*, const wchar_t*, va_list)
@@ -46,18 +59,40 @@ function int vwprintf (const wchar_t*, va_list)
 function int vwscanf (const wchar_t*, va_list)
 function int vswprintf (wchar_t*, size_t, const wchar_t*, va_list)
 function int vswscanf (const wchar_t*, const wchar_t*, va_list)
+#if defined XOPEN2K8 || defined POSIX2008
+function {wchar_t*} wcpcpy (wchar_t*, const wchar_t*)
+function {wchar_t*} wcpncpy (wchar_t*, const wchar_t*, size_t)
+#endif
 function size_t wcrtomb (char*, wchar_t, mbstate_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int wcscasecmp(const wchar_t*, const wchar_t*)
+function int wcscasecmp_l(const wchar_t*, const wchar_t*, locale_t)
+#endif
 function {wchar_t*} wcscat (wchar_t*, const wchar_t*)
 function {wchar_t*} wcschr (const wchar_t*, wchar_t)
 function int wcscmp (const wchar_t*, const wchar_t*)
 function int wcscoll (const wchar_t*, const wchar_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int wcscoll_l (const wchar_t*, const wchar_t*, locale_t)
+#endif
 function {wchar_t*} wcscpy (wchar_t*, const wchar_t*)
 function size_t wcscspn (const wchar_t*, const wchar_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function {wchar_t*} wcsdup (const wchar_t*)
+#endif
 function size_t wcsftime (wchar_t*, size_t, const wchar_t*, const struct tm*)
 function size_t wcslen (const wchar_t*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int wcsncasecmp (const wchar_t*, const wchar_t*, size_t)
+function int wcsncasecmp_l (const wchar_t*, const wchar_t*, size_t, locale_t)
+#endif
 function {wchar_t*} wcsncat (wchar_t*, const wchar_t*, size_t)
 function int wcsncmp (const wchar_t*, const wchar_t*, size_t)
 function {wchar_t*} wcsncpy (wchar_t*, const wchar_t*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function size_t wcsnlen (const wchar_t*, size_t)
+function size_t wcsnrtombs (char*, const wchar_t**, size_t, size_t, mbstate_t*)
+#endif
 function {wchar_t*} wcspbrk (const wchar_t*, const wchar_t*)
 function {wchar_t*} wcsrchr (const wchar_t*, wchar_t)
 function size_t wcsrtombs (char*, const wchar_t**, size_t, mbstate_t*)
@@ -68,11 +103,18 @@ function {wchar_t*} wcstok (wchar_t*, const wchar_t*, wchar_t**)
 function {long int} wcstol (const wchar_t*, wchar_t**, int)
 function {unsigned long int} wcstoul (const wchar_t*, wchar_t**, int)
 function {wchar_t*} wcswcs (const wchar_t*, const wchar_t*)
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function int wcswidth (const wchar_t*, size_t)
+#endif
 function size_t wcsxfrm (wchar_t*, const wchar_t*, size_t)
+#if defined XOPEN2K8 || defined POSIX2008
+function size_t wcsxfrm_l (wchar_t*, const wchar_t*, size_t, locale_t)
+#endif
 function int wctob (wint_t)
+#if !defined ISO && !defined POSIX && !defined POSIX2008
 function wctype_t wctype (const char*)
 function int wcwidth (wchar_t)
+#endif
 function {wchar_t*} wmemchr (const wchar_t*, wchar_t, size_t)
 function int wmemcmp (const wchar_t*, const wchar_t*, size_t)
 function {wchar_t*} wmemcpy (wchar_t*, const wchar_t*, size_t)
index 230d7482a66ddc61e80472fab01ddf93f22d5a07..a3f8c54a85760d64521358eedfc55ab57dd076b1 100644 (file)
@@ -1,6 +1,9 @@
 type wint_t
 type wctrans_t
 type wctype_t
+#if defined XOPEN2K8 || defined POSIX2008
+type locale_t
+#endif
 
 function int iswalnum (wint_t)
 function int iswalpha (wint_t)
@@ -19,6 +22,25 @@ function wint_t towlower (wint_t)
 function wint_t towupper (wint_t)
 function wctrans_t wctrans (const char*)
 function wctype_t wctype (const char*)
+#if defined XOPEN2K8 || defined POSIX2008
+function int iswalnum_l (wint_t, locale_t)
+function int iswalpha_l (wint_t, locale_t)
+function int iswcntrl_l (wint_t, locale_t)
+function int iswdigit_l (wint_t, locale_t)
+function int iswgraph_l (wint_t, locale_t)
+function int iswlower_l (wint_t, locale_t)
+function int iswprint_l (wint_t, locale_t)
+function int iswpunct_l (wint_t, locale_t)
+function int iswspace_l (wint_t, locale_t)
+function int iswupper_l (wint_t, locale_t)
+function int iswxdigit_l (wint_t, locale_t)
+function int iswctype_l (wint_t, wctype_t, locale_t)
+function wint_t towctrans_l (wint_t, wctrans_t, locale_t)
+function wint_t towlower_l (wint_t, locale_t)
+function wint_t towupper_l (wint_t, locale_t)
+function wctrans_t wctrans_l (const char*, locale_t)
+function wctype_t wctype_l (const char*, locale_t)
+#endif
 
 macro WEOF
 
index bfa66e8f158d57b00236b2456b9bf8c5c950b962..12eecbeee200878f046ef2d6a8a3db45c84abf13 100644 (file)
@@ -14,7 +14,9 @@ constant WRDE_UNDEF
 constant WRDE_BADCHAR
 constant WRDE_CMDSUB
 constant WRDE_NOSPACE
+#if defined XOPEN2K8 || defined POSIX2008
 constant WRDE_NOSYS
+#endif
 constant WRDE_SYNTAX
 
 function int wordexp (const char*, wordexp_t*, int)
index 675deae16abe0bf59b58f65594e920263b3757f9..bb4ede15802df85b4ad05c311dabf7875f64e53a 100644 (file)
@@ -218,7 +218,7 @@ extern void seekdir (DIR *__dirp, long int __pos) __THROW __nonnull ((1));
 extern long int telldir (DIR *__dirp) __THROW __nonnull ((1));
 #endif
 
-#if defined __USE_BSD || defined __USE_MISC || defined __XOPEN2K8
+#if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN2K8
 
 /* Return the file descriptor used by DIRP.  */
 extern int dirfd (DIR *__dirp) __THROW __nonnull ((1));
index e46bb2b373dffc7723977ee2d58ddf1f7c8821d0..21822b6a434d794d9fa0216a6d36eb53614f5329 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-1993,1995-2006,2007,2009 Free Software Foundation, Inc.
+/* Copyright (C) 1991-1993,1995-2007,2009,2010 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
@@ -66,7 +66,8 @@
    __USE_XOPEN_EXTENDED        Define X/Open Unix things.
    __USE_UNIX98                Define Single Unix V2 things.
    __USE_XOPEN2K        Define XPG6 things.
-   __USE_XOPEN2K8       Define XPG7 things.
+   __USE_XOPEN2KXSI     Define XPG6 XSI things.
+   __USE_XOPEN2K8XSI    Define XPG7 XSI things.
    __USE_LARGEFILE     Define correct standard I/O things.
    __USE_LARGEFILE64   Define LFS things with separate names.
    __USE_FILE_OFFSET64 Define 64bit interface as default.
 #undef __USE_XOPEN_EXTENDED
 #undef __USE_UNIX98
 #undef __USE_XOPEN2K
+#undef __USE_XOPEN2KXSI
 #undef __USE_XOPEN2K8
+#undef __USE_XOPEN2K8XSI
 #undef __USE_LARGEFILE
 #undef __USE_LARGEFILE64
 #undef __USE_FILE_OFFSET64
 #  if (_XOPEN_SOURCE - 0) >= 600
 #   if (_XOPEN_SOURCE - 0) >= 700
 #    define __USE_XOPEN2K8     1
+#    define __USE_XOPEN2K8XSI  1
 #   endif
 #   define __USE_XOPEN2K       1
+#   define __USE_XOPEN2KXSI    1
 #   undef __USE_ISOC99
 #   define __USE_ISOC99                1
 #  endif
index 2a2a29dc70b433368a011f9de093a3dee9342aa9..4eb003be4604e48bce0c9bd19d42ffc5e45842cb 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991,1992,1994-2001,2003,2004,2005,2006,2007, 2009
+/* Copyright (C) 1991,1992,1994-2001,2003,2004,2005,2006,2007,2009,2010
        Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -34,8 +34,54 @@ __BEGIN_DECLS
 #include <bits/fcntl.h>
 
 /* For XPG all symbols from <sys/stat.h> should also be available.  */
-#ifdef __USE_XOPEN
-# include <sys/stat.h>
+#if defined __USE_XOPEN || defined __USE_XOPEN2K8
+# include <bits/types.h>         /* For __mode_t and __dev_t.  */
+# define __need_timespec
+# include <time.h>
+# include <bits/stat.h>
+
+# define S_IFMT                __S_IFMT
+# define S_IFDIR       __S_IFDIR
+# define S_IFCHR       __S_IFCHR
+# define S_IFBLK       __S_IFBLK
+# define S_IFREG       __S_IFREG
+# ifdef __S_IFIFO
+#  define S_IFIFO      __S_IFIFO
+# endif
+# ifdef __S_IFLNK
+#  define S_IFLNK      __S_IFLNK
+# endif
+# if (defined __USE_UNIX98 || defined __USE_XOPEN2K8) && defined __S_IFSOCK
+#  define S_IFSOCK     __S_IFSOCK
+# endif
+
+/* Protection bits.  */
+
+# define S_ISUID       __S_ISUID       /* Set user ID on execution.  */
+# define S_ISGID       __S_ISGID       /* Set group ID on execution.  */
+
+# if defined __USE_BSD || defined __USE_MISC || defined __USE_XOPEN
+/* Save swapped text after use (sticky bit).  This is pretty well obsolete.  */
+#  define S_ISVTX      __S_ISVTX
+# endif
+
+# define S_IRUSR       __S_IREAD       /* Read by owner.  */
+# define S_IWUSR       __S_IWRITE      /* Write by owner.  */
+# define S_IXUSR       __S_IEXEC       /* Execute by owner.  */
+/* Read, write, and execute by owner.  */
+# define S_IRWXU       (__S_IREAD|__S_IWRITE|__S_IEXEC)
+
+# define S_IRGRP       (S_IRUSR >> 3)  /* Read by group.  */
+# define S_IWGRP       (S_IWUSR >> 3)  /* Write by group.  */
+# define S_IXGRP       (S_IXUSR >> 3)  /* Execute by group.  */
+/* Read, write, and execute by group.  */
+# define S_IRWXG       (S_IRWXU >> 3)
+
+# define S_IROTH       (S_IRGRP >> 3)  /* Read by others.  */
+# define S_IWOTH       (S_IWGRP >> 3)  /* Write by others.  */
+# define S_IXOTH       (S_IXGRP >> 3)  /* Execute by others.  */
+/* Read, write, and execute by others.  */
+# define S_IRWXO       (S_IRWXG >> 3)
 #endif
 
 #ifdef __USE_MISC
@@ -49,8 +95,8 @@ __BEGIN_DECLS
 # endif
 #endif /* Use misc.  */
 
-/* XPG wants the following symbols.  */
-#ifdef __USE_XOPEN             /* <stdio.h> has the same definitions.  */
+/* XPG wants the following symbols.   <stdio.h> has the same definitions.  */
+#if defined __USE_XOPEN || defined __USE_XOPEN2K8
 # define SEEK_SET      0       /* Seek from beginning of file.  */
 # define SEEK_CUR      1       /* Seek from current position.  */
 # define SEEK_END      2       /* Seek from end of file.  */
@@ -116,9 +162,10 @@ extern int __REDIRECT (openat, (int __fd, __const char *__file, int __oflag,
 #   define openat openat64
 #  endif
 # endif
-
+# ifdef __USE_LARGEFILE64
 extern int openat64 (int __fd, __const char *__file, int __oflag, ...)
      __nonnull ((2));
+# endif
 #endif
 
 /* Create and open FILE, with mode MODE.  This takes an `int' MODE
index e9e6b1aa81f30389e5bb131a38821c9abb917647..0d30052613163d38cefc7ccf64e7858fed763ceb 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.10 "LC_ADDRESS".  */
 
-const struct locale_data _nl_C_LC_ADDRESS attribute_hidden =
+const struct __locale_data _nl_C_LC_ADDRESS attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index cc8c8ee81f6432410693f86f6c8eef0005d1dd27..a7e440fda71ba31e66605b70163bae2c57aa03ca 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-1997,1999,2000,2001,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1995-1997,1999,2000,2001,2002,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1995.
 
@@ -98,7 +98,7 @@ static const uint32_t collseqwc[] =
   L'\xf8', L'\xf9', L'\xfa', L'\xfb', L'\xfc', L'\xfd', L'\xfe', L'\xff'
 };
 
-const struct locale_data _nl_C_LC_COLLATE attribute_hidden =
+const struct __locale_data _nl_C_LC_COLLATE attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 420b08a13f5ec4a15c32d3f817eff79c0159f9b3..0eb60d4da7c97542983e0e7f8cfe61514e919dba 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-2002, 2003, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2002, 2003, 2009, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1995.
 
@@ -538,7 +538,7 @@ _nl_C_LC_CTYPE_width attribute_hidden =
    NR_FIXED == _NL_ITEM_INDEX (_NL_CTYPE_EXTRA_MAP_1). */
 typedef int assertion1[1 - 2 * (NR_FIXED != _NL_ITEM_INDEX (_NL_CTYPE_EXTRA_MAP_1))];
 
-const struct locale_data _nl_C_LC_CTYPE attribute_hidden =
+const struct __locale_data _nl_C_LC_CTYPE attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 628e8f145d279ce6e6f4628f677c7660d4db04da..da465d2c8222fcf3c340707e5af5637570c97fed 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.12 "LC_IDENTIFICATION".  */
 
-const struct locale_data _nl_C_LC_IDENTIFICATION attribute_hidden =
+const struct __locale_data _nl_C_LC_IDENTIFICATION attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 796fe29ce5dccccdda4bd380b401023afd06b231..16e45f6502fb7662295e140af491c953ededb486 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.12 "LC_MEASUREMENT".  */
 
-const struct locale_data _nl_C_LC_MEASUREMENT attribute_hidden =
+const struct __locale_data _nl_C_LC_MEASUREMENT attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 499d4bf5a661b943cfbed6d12ef42bf454b8234c..0d2a05f80d1772a5861edf97b6f1600760d3b9b6 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995,1996,1997,2000,2001,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1995,1996,1997,2000,2001,2002,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
@@ -24,7 +24,7 @@
 
    The last two fields are a GNU extension.  */
 
-const struct locale_data _nl_C_LC_MESSAGES attribute_hidden =
+const struct __locale_data _nl_C_LC_MESSAGES attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 8cccf9637a9e6b4fcd700b5e049bcb4e575fddc6..e18c059e07f126cc6ac8f9a9fe39a0e3cb02ff6e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1995-1999, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1995.
 
@@ -28,7 +28,7 @@ static const char not_available[] = "\377";
 static const char not_available[] = "\177";
 #endif
 
-const struct locale_data _nl_C_LC_MONETARY attribute_hidden =
+const struct __locale_data _nl_C_LC_MONETARY attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 65033d6751d2cfc1c0a753dd2bc56d91868e374d..e59b42fa09918ef17e36b538e1e89e11f9856e2c 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.9 "LC_NAME".  */
 
-const struct locale_data _nl_C_LC_NAME attribute_hidden =
+const struct __locale_data _nl_C_LC_NAME attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 377c51cdfb83b760402fcd293b05a9da1b5183dd..a16a841c78145089812d8501f83a179d72cf21eb 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995,1996,1997,2000,2001,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1995,1996,1997,2000,2001,2002,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1995.
 
@@ -21,7 +21,7 @@
 
 /* This table's entries are taken from POSIX.2 Table 2-10
    ``LC_NUMERIC Category Definition in the POSIX Locale''.  */
-const struct locale_data _nl_C_LC_NUMERIC attribute_hidden =
+const struct __locale_data _nl_C_LC_NUMERIC attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 74e6401de7e7dae985185a1bb4f11ac65d314671..2d060ca8ba9cc8d4e88d8a75e16783fc9aa4fbcb 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.8 "LC_PAPER".  */
 
-const struct locale_data _nl_C_LC_PAPER attribute_hidden =
+const struct __locale_data _nl_C_LC_PAPER attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 561a1ef28a6d8931e31fdc8b93786d8e26059d47..522388866ee34a1954cea899013fc67d4b8b9072 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2000, 2001, 2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -24,7 +24,7 @@
 /* This table's entries are taken from ISO 14652, the table in section
    4.11 "LC_TELEPHONE".  */
 
-const struct locale_data _nl_C_LC_TELEPHONE attribute_hidden =
+const struct __locale_data _nl_C_LC_TELEPHONE attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index 368ffce7ad5096c9381090ca6603431a61807e28..16d387b93827f78f63b143cfb42dde702cb005ec 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995-2002, 2004, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2002, 2004, 2007, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@gnu.org>, 1995.
 
@@ -23,7 +23,7 @@
    ``LC_TIME Category Definition in the POSIX Locale'',
    with additions from ISO 14652, section 4.6.  */
 
-const struct locale_data _nl_C_LC_TIME attribute_hidden =
+const struct __locale_data _nl_C_LC_TIME attribute_hidden =
 {
   _nl_C_name,
   NULL, 0, 0,                  /* no file mapped */
index ea24170df516c69c747845ce5d34795e82da590e..6b88c96341748aeeac4d55912652ff6bad35f30b 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996-2001, 2002, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1996-2001, 2002, 2003, 2006, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
 
 #ifdef NL_CURRENT_INDIRECT
 # define DEFINE_CATEGORY(category, category_name, items, a) \
-extern struct locale_data _nl_C_##category; \
+extern struct __locale_data _nl_C_##category; \
 weak_extern (_nl_C_##category)
 # include "categories.def"
 # undef        DEFINE_CATEGORY
 
 /* Array indexed by category of pointers to _nl_C_CATEGORY slots.
    Elements are zero for categories whose data is never used.  */
-struct locale_data *const _nl_C[] attribute_hidden =
+struct __locale_data *const _nl_C[] attribute_hidden =
   {
 # define DEFINE_CATEGORY(category, category_name, items, a) \
     [category] = &_nl_C_##category,
@@ -59,7 +59,7 @@ struct loaded_l10nfile *_nl_locale_file_list[__LC_LAST];
 const char _nl_default_locale_path[] attribute_hidden = LOCALEDIR;
 
 
-struct locale_data *
+struct __locale_data *
 internal_function
 _nl_find_locale (const char *locale_path, size_t locale_path_len,
                 int category, const char **name)
@@ -104,7 +104,8 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
      but only if there was no LOCPATH environment variable specified.  */
   if (__builtin_expect (locale_path == NULL, 1))
     {
-      struct locale_data *data = _nl_load_locale_from_archive (category, name);
+      struct __locale_data *data
+       = _nl_load_locale_from_archive (category, name);
       if (__builtin_expect (data != NULL, 1))
        return data;
 
@@ -214,12 +215,12 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
          [__LC_MEASUREMENT] = _NL_ITEM_INDEX (_NL_MEASUREMENT_CODESET),
          [__LC_IDENTIFICATION] = _NL_ITEM_INDEX (_NL_IDENTIFICATION_CODESET)
        };
-      const struct locale_data *data;
+      const struct __locale_data *data;
       const char *locale_codeset;
       char *clocale_codeset;
       char *ccodeset;
 
-      data = (const struct locale_data *) locale_file->data;
+      data = (const struct __locale_data *) locale_file->data;
       locale_codeset =
        (const char *) data->values[codeset_idx[category]].string;
       assert (locale_codeset != NULL);
@@ -241,7 +242,7 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
   /* Determine the locale name for which loading succeeded.  This
      information comes from the file name.  The form is
      <path>/<locale>/LC_foo.  We must extract the <locale> part.  */
-  if (((const struct locale_data *) locale_file->data)->name == NULL)
+  if (((const struct __locale_data *) locale_file->data)->name == NULL)
     {
       char *cp, *endp;
 
@@ -249,20 +250,20 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
       cp = endp - 1;
       while (cp[-1] != '/')
        --cp;
-      ((struct locale_data *) locale_file->data)->name = __strndup (cp,
-                                                                   endp - cp);
+      ((struct __locale_data *) locale_file->data)->name
+       = __strndup (cp, endp - cp);
     }
 
   /* Determine whether the user wants transliteration or not.  */
   if (modifier != NULL && __strcasecmp (modifier, "TRANSLIT") == 0)
-    ((struct locale_data *) locale_file->data)->use_translit = 1;
+    ((struct __locale_data *) locale_file->data)->use_translit = 1;
 
   /* Increment the usage count.  */
-  if (((const struct locale_data *) locale_file->data)->usage_count
+  if (((const struct __locale_data *) locale_file->data)->usage_count
       < MAX_USAGE_COUNT)
-    ++((struct locale_data *) locale_file->data)->usage_count;
+    ++((struct __locale_data *) locale_file->data)->usage_count;
 
-  return (struct locale_data *) locale_file->data;
+  return (struct __locale_data *) locale_file->data;
 }
 
 
@@ -270,7 +271,7 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
    is acquired.  */
 void
 internal_function
-_nl_remove_locale (int locale, struct locale_data *data)
+_nl_remove_locale (int locale, struct __locale_data *data)
 {
   if (--data->usage_count == 0)
     {
@@ -281,7 +282,7 @@ _nl_remove_locale (int locale, struct locale_data *data)
 
          /* Search for the entry.  It must be in the list.  Otherwise it
             is a bug and we crash badly.  */
-         while ((struct locale_data *) ptr->data != data)
+         while ((struct __locale_data *) ptr->data != data)
            ptr = ptr->next;
 
          /* Mark the data as not available anymore.  So when the data has
index 771742e1be2e49dfec6f8d32fadc3e55b5fffee0..63d1238fb0d05f88ef18669a1d022cc92e55b335 100644 (file)
@@ -1,5 +1,5 @@
 /* Locale object representing the global locale controlled by setlocale.
-   Copyright (C) 2002, 2006, 2008 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2006, 2008, 2010 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
@@ -21,7 +21,7 @@
 #include "localeinfo.h"
 
 #define DEFINE_CATEGORY(category, category_name, items, a) \
-extern struct locale_data _nl_C_##category; weak_extern (_nl_C_##category)
+extern struct __locale_data _nl_C_##category; weak_extern (_nl_C_##category)
 #include "categories.def"
 #undef DEFINE_CATEGORY
 
index d545f17fb53f230340127ccb3024d76439aca90b..663202e54ebeb0c1d2d1ef6a51c3e10dd0f4819f 100644 (file)
@@ -1,5 +1,5 @@
 /* Code to load locale data from the locale archive file.
-   Copyright (C) 2002, 2003, 2005 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2003, 2005, 2010 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
@@ -85,7 +85,7 @@ struct locale_in_archive
 {
   struct locale_in_archive *next;
   char *name;
-  struct locale_data *data[__LC_LAST];
+  struct __locale_data *data[__LC_LAST];
 };
 static struct locale_in_archive *archloaded;
 
@@ -129,7 +129,7 @@ calculate_head_size (const struct locarhead *h)
    already been loaded from the archive, just returns the existing data
    structure.  If successful, sets *NAMEP to point directly into the mapped
    archive string table; that way, the next call can short-circuit strcmp.  */
-struct locale_data *
+struct __locale_data *
 internal_function
 _nl_load_locale_from_archive (int category, const char **namep)
 {
index 467dff157a4ec6f0e97bceefda0274553539a891..6ef25b023477228b1009e9a45334e9b65d8c1ebd 100644 (file)
@@ -1,5 +1,5 @@
 /* Functions to read locale data files.
-   Copyright (C) 1996-2004, 2005, 2006 Free Software Foundation, Inc.
+   Copyright (C) 1996-2004, 2005, 2006, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
@@ -61,7 +61,7 @@ static const enum value_type *const _nl_value_types[] =
 };
 
 
-struct locale_data *
+struct __locale_data *
 internal_function
 _nl_intern_locale_data (int category, const void *data, size_t datasize)
 {
@@ -71,7 +71,7 @@ _nl_intern_locale_data (int category, const void *data, size_t datasize)
       unsigned int nstrings;
       unsigned int strindex[0];
     } *const filedata = data;
-  struct locale_data *newdata;
+  struct __locale_data *newdata;
   size_t cnt;
 
   if (__builtin_expect (datasize < sizeof *filedata, 0)
@@ -166,7 +166,7 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
   int fd;
   void *filedata;
   struct stat64 st;
-  struct locale_data *newdata;
+  struct __locale_data *newdata;
   int save_err;
   int alloc = ld_mapped;
 
@@ -187,7 +187,7 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
   if (__builtin_expect (S_ISDIR (st.st_mode), 0))
     {
       /* LOCALE/LC_foo is a directory; open LOCALE/LC_foo/SYS_LC_foo
-           instead.  */
+          instead.  */
       char *newp;
       size_t filenamelen;
 
@@ -282,7 +282,7 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
 
 void
 internal_function
-_nl_unload_locale (struct locale_data *locale)
+_nl_unload_locale (struct __locale_data *locale)
 {
   if (locale->private.cleanup)
     (*locale->private.cleanup) (locale);
index 19ea41ae6dd719e58273e83531e974f3d7b2562d..72e9d3a6ea31dc01ae018451d3a7c0bb19988ad0 100644 (file)
@@ -1,5 +1,5 @@
 /* Declarations for internal libc locale interfaces
-   Copyright (C) 1995-2003, 2005, 2006, 2007, 2008, 2009
+   Copyright (C) 1995-2003, 2005, 2006, 2007, 2008, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 /* Two special weight constants for the collation data.  */
 #define IGNORE_CHAR    2
 
-/* We use a special value for the usage counter in `locale_data' to
+/* We use a special value for the usage counter in `__locale_data' to
    signal that this data must never be removed anymore.  */
 #define MAX_USAGE_COUNT (UINT_MAX - 1)
 #define UNDELETABLE    UINT_MAX
 
 /* Structure describing locale data in core for a category.  */
-struct locale_data
+struct __locale_data
 {
   const char *name;
   const char *filedata;                /* Region mapping the file data.  */
@@ -65,7 +65,7 @@ struct locale_data
      the data.  */
   struct
   {
-    void (*cleanup) (struct locale_data *) internal_function;
+    void (*cleanup) (struct __locale_data *) internal_function;
     union
     {
       void *data;
@@ -145,7 +145,7 @@ struct era_entry
 };
 
 /* Structure caching computed data about information from LC_TIME.
-   The `private.time' member of `struct locale_data' points to this.  */
+   The `private.time' member of `struct __locale_data' points to this.  */
 struct lc_time_data
 {
   struct era_entry *eras;
@@ -232,12 +232,12 @@ __libc_tsd_define (extern, __locale_t, LOCALE)
    and we arrange that linking that module is what brings in all the code
    associated with this category.  */
 #define DEFINE_CATEGORY(category, category_name, items, a) \
-extern __thread struct locale_data *const *_nl_current_##category \
+extern __thread struct __locale_data *const *_nl_current_##category \
   attribute_hidden attribute_tls_model_ie;
 #include "categories.def"
 #undef DEFINE_CATEGORY
 
-/* Return a pointer to the current `struct locale_data' for CATEGORY.  */
+/* Return a pointer to the current `struct __locale_data' for CATEGORY.  */
 #define _NL_CURRENT_DATA(category)     (*_nl_current_##category)
 
 /* Extract the current CATEGORY locale's string for ITEM.  */
@@ -254,7 +254,7 @@ extern __thread struct locale_data *const *_nl_current_##category \
 
 /* This is used in lc-CATEGORY.c to define _nl_current_CATEGORY.  */
 #define _NL_CURRENT_DEFINE(category) \
-  __thread struct locale_data *const *_nl_current_##category \
+  __thread struct __locale_data *const *_nl_current_##category \
     attribute_hidden = &_nl_global_locale.__locales[category]; \
   asm (_NL_CURRENT_DEFINE_STRINGIFY (ASM_GLOBAL_DIRECTIVE) \
        " " __SYMBOL_PREFIX "_nl_current_" #category "_used\n" \
@@ -272,7 +272,7 @@ extern __thread struct locale_data *const *_nl_current_##category \
 /* All categories are always loaded in the shared library, so there is no
    point in having lots of separate symbols for linking.  */
 
-/* Return a pointer to the current `struct locale_data' for CATEGORY.  */
+/* Return a pointer to the current `struct __locale_data' for CATEGORY.  */
 # define _NL_CURRENT_DATA(category) \
   (_NL_CURRENT_LOCALE->__locales[category])
 
@@ -304,9 +304,9 @@ extern const char _nl_default_locale_path[] attribute_hidden;
    those directories are searched for the locale files.  If it's null,
    the locale archive is checked first and then _nl_default_locale_path
    is searched for locale files.  */
-extern struct locale_data *_nl_find_locale (const char *locale_path,
-                                           size_t locale_path_len,
-                                           int category, const char **name)
+extern struct __locale_data *_nl_find_locale (const char *locale_path,
+                                             size_t locale_path_len,
+                                             int category, const char **name)
      internal_function attribute_hidden;
 
 /* Try to load the file described by FILE.  */
@@ -314,11 +314,11 @@ extern void _nl_load_locale (struct loaded_l10nfile *file, int category)
      internal_function attribute_hidden;
 
 /* Free all resource.  */
-extern void _nl_unload_locale (struct locale_data *locale)
+extern void _nl_unload_locale (struct __locale_data *locale)
      internal_function attribute_hidden;
 
 /* Free the locale and give back all memory if the usage count is one.  */
-extern void _nl_remove_locale (int locale, struct locale_data *data)
+extern void _nl_remove_locale (int locale, struct __locale_data *data)
      internal_function attribute_hidden;
 
 /* Find the locale *NAMEP in the locale archive, and return the
@@ -326,8 +326,8 @@ extern void _nl_remove_locale (int locale, struct locale_data *data)
    already been loaded from the archive, just returns the existing data
    structure.  If successful, sets *NAMEP to point directly into the mapped
    archive string table; that way, the next call can short-circuit strcmp.  */
-extern struct locale_data *_nl_load_locale_from_archive (int category,
-                                                        const char **namep)
+extern struct __locale_data *_nl_load_locale_from_archive (int category,
+                                                          const char **namep)
      internal_function attribute_hidden;
 
 /* Subroutine of setlocale's __libc_subfreeres hook.  */
@@ -341,42 +341,42 @@ extern void _nl_locale_subfreeres (void) attribute_hidden;
    and `name' fields uninitialized, for the caller to fill in.
    If any bogons are detected in the data, this will refuse to
    intern it, and return a null pointer instead.  */
-extern struct locale_data *_nl_intern_locale_data (int category,
-                                                  const void *data,
-                                                  size_t datasize)
+extern struct __locale_data *_nl_intern_locale_data (int category,
+                                                    const void *data,
+                                                    size_t datasize)
      internal_function attribute_hidden;
 
 
 /* Return `era' entry which corresponds to TP.  Used in strftime.  */
 extern struct era_entry *_nl_get_era_entry (const struct tm *tp,
-                                           struct locale_data *lc_time)
+                                           struct __locale_data *lc_time)
      internal_function attribute_hidden;
 
 /* Return `era' cnt'th entry .  Used in strptime.  */
 extern struct era_entry *_nl_select_era_entry (int cnt,
-                                              struct locale_data *lc_time)
-          internal_function attribute_hidden;
+                                              struct __locale_data *lc_time)
+         internal_function attribute_hidden;
 
 /* Return `alt_digit' which corresponds to NUMBER.  Used in strftime.  */
 extern const char *_nl_get_alt_digit (unsigned int number,
-                                     struct locale_data *lc_time)
-          internal_function attribute_hidden;
+                                     struct __locale_data *lc_time)
+         internal_function attribute_hidden;
 
 /* Similar, but now for wide characters.  */
 extern const wchar_t *_nl_get_walt_digit (unsigned int number,
-                                         struct locale_data *lc_time)
+                                         struct __locale_data *lc_time)
      internal_function attribute_hidden;
 
 /* Parse string as alternative digit and return numeric value.  */
 extern int _nl_parse_alt_digit (const char **strp,
-                               struct locale_data *lc_time)
+                               struct __locale_data *lc_time)
      internal_function attribute_hidden;
 
 /* Postload processing.  */
 extern void _nl_postload_ctype (void);
 
 /* Functions used for the `private.cleanup' hook.  */
-extern void _nl_cleanup_time (struct locale_data *)
+extern void _nl_cleanup_time (struct __locale_data *)
      internal_function attribute_hidden;
 
 
index 08e1534a8b35ff2e29b817ce7afdf55be916c421..573fed0c4efbaf9e3da3766f3fa5e71c371ca920 100644 (file)
@@ -1,5 +1,5 @@
 /* User interface for extracting locale-dependent parameters.
-   Copyright (C) 1995-1997,1999-2002,2005,2007 Free Software Foundation, Inc.
+   Copyright (C) 1995-1997,1999-2002,2005,2007,2010 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
@@ -33,7 +33,7 @@ __nl_langinfo_l (item, l)
 {
   int category = _NL_ITEM_CATEGORY (item);
   unsigned int index = _NL_ITEM_INDEX (item);
-  const struct locale_data *data;
+  const struct __locale_data *data;
 
   if (category < 0 || category == LC_ALL || category >= __LC_LAST)
     /* Bogus category: bogus item.  */
index 05a55a96ed65f58a79344c6dc3e639f6c1b337f0..4ebce78244128592b376ca4d05ea46e8f108e553 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 1992, 1995-2000, 2002, 2003, 2004, 2006, 2008
+/* Copyright (C) 1991, 1992, 1995-2000, 2002, 2003, 2004, 2006, 2008, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -207,7 +207,7 @@ setname (int category, const char *name)
 
 /* Put DATA in *_nl_current[CATEGORY].  */
 static inline void
-setdata (int category, struct locale_data *data)
+setdata (int category, struct __locale_data *data)
 {
   if (CATEGORY_USED (category))
     {
@@ -273,7 +273,7 @@ setlocale (int category, const char *locale)
         composite locale name.  This is a semi-colon separated list
         of entries of the form `CATEGORY=VALUE'.  */
       const char *newnames[__LC_LAST];
-      struct locale_data *newdata[__LC_LAST];
+      struct __locale_data *newdata[__LC_LAST];
 
       /* Set all name pointers to the argument name.  */
       for (category = 0; category < __LC_LAST; ++category)
@@ -400,7 +400,7 @@ setlocale (int category, const char *locale)
     }
   else
     {
-      struct locale_data *newdata = NULL;
+      struct __locale_data *newdata = NULL;
       const char *newname[1] = { locale };
 
       if (CATEGORY_USED (category))
@@ -465,7 +465,7 @@ libc_hidden_def (setlocale)
 
 static void __libc_freeres_fn_section
 free_category (int category,
-              struct locale_data *here, struct locale_data *c_data)
+              struct __locale_data *here, struct locale_data *c_data)
 {
   struct loaded_l10nfile *runp = _nl_locale_file_list[category];
 
@@ -481,7 +481,7 @@ free_category (int category,
   while (runp != NULL)
     {
       struct loaded_l10nfile *curr = runp;
-      struct locale_data *data = (struct locale_data *) runp->data;
+      struct __locale_data *data = (struct locale_data *) runp->data;
 
       if (data != NULL && data != c_data)
        _nl_unload_locale (data);
@@ -502,7 +502,7 @@ _nl_locale_subfreeres (void)
 # define DEFINE_CATEGORY(category, category_name, items, a)                  \
   if (CATEGORY_USED (category))                                                      \
     {                                                                        \
-      extern struct locale_data _nl_C_##category;                            \
+      extern struct __locale_data _nl_C_##category;                          \
       weak_extern (_nl_C_##category)                                         \
       free_category (category, *_nl_current_##category, &_nl_C_##category);   \
     }
index 4573e6f390e80780694cff7a0f52cb9a92b162a9..f84e73ef0f81c32cae4a806d746b7d10fe842fdb 100644 (file)
@@ -1,5 +1,5 @@
 /* C locale object.
-   Copyright (C) 2001, 2002, 2005 Free Software Foundation, Inc.
+   Copyright (C) 2001, 2002, 2005, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 2001.
 
@@ -22,7 +22,7 @@
 #include "localeinfo.h"
 
 #define DEFINE_CATEGORY(category, category_name, items, a) \
-extern struct locale_data _nl_C_##category;
+extern struct __locale_data _nl_C_##category;
 #include "categories.def"
 #undef DEFINE_CATEGORY
 
index e879212b790c3928637352c167901fbc61b0a21a..ce541528ce12c71d85c15bb87a99f6d4defd6689 100644 (file)
@@ -1,5 +1,5 @@
 /* Definition of locale datatype.
-   Copyright (C) 1997,2000,2002,2009 Free Software Foundation, Inc.
+   Copyright (C) 1997,2000,2002,2009,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
 
@@ -28,7 +28,7 @@
 typedef struct __locale_struct
 {
   /* Note: LC_ALL is not a valid index into this array.  */
-  struct locale_data *__locales[13]; /* 13 = __LC_LAST. */
+  struct __locale_data *__locales[13]; /* 13 = __LC_LAST. */
 
   /* To increase the speed of this solution we add some special members.  */
   const unsigned short int *__ctype_b;
index 389bed4a68b8483de2ab652728147f03b6956e74..afa7790ddef2c51dd1b4775c213e6cd1e2edafd5 100644 (file)
@@ -1,3 +1,7 @@
+2010-01-08  Ulrich Drepper  <drepper@redhat.com>
+
+       * sysdeps/pthread/pthread.h: Fix pthread_mutex_consistent declaration.
+
 2009-12-18  Thomas Schwinge  <thomas@codesourcery.com>
 
        * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c (_init): Don't
index d71b4cc47d120e4519762be645e37b9f70f543dc..8a946ffc3abc693ac90936f89c3a8f03a3021291 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -739,8 +739,8 @@ extern int pthread_mutex_lock (pthread_mutex_t *__mutex)
 #ifdef __USE_XOPEN2K
 /* Wait until lock becomes available, or specified time passes. */
 extern int pthread_mutex_timedlock (pthread_mutex_t *__restrict __mutex,
-                                    __const struct timespec *__restrict
-                                    __abstime) __THROW __nonnull ((1, 2));
+                                   __const struct timespec *__restrict
+                                   __abstime) __THROW __nonnull ((1, 2));
 #endif
 
 /* Unlock a mutex.  */
@@ -766,7 +766,7 @@ extern int pthread_mutex_setprioceiling (pthread_mutex_t *__restrict __mutex,
 
 #ifdef __USE_XOPEN2K8
 /* Declare the state protected by MUTEX as consistent.  */
-extern int pthread_mutex_consistent_np (pthread_mutex_t *__mutex)
+extern int pthread_mutex_consistent (pthread_mutex_t *__mutex)
      __THROW __nonnull ((1));
 # ifdef __USE_GNU
 extern int pthread_mutex_consistent_np (pthread_mutex_t *__mutex)
@@ -990,13 +990,13 @@ extern int pthread_condattr_destroy (pthread_condattr_t *__attr)
 
 /* Get the process-shared flag of the condition variable attribute ATTR.  */
 extern int pthread_condattr_getpshared (__const pthread_condattr_t *
-                                        __restrict __attr,
-                                        int *__restrict __pshared)
+                                       __restrict __attr,
+                                       int *__restrict __pshared)
      __THROW __nonnull ((1, 2));
 
 /* Set the process-shared flag of the condition variable attribute ATTR.  */
 extern int pthread_condattr_setpshared (pthread_condattr_t *__attr,
-                                        int __pshared) __THROW __nonnull ((1));
+                                       int __pshared) __THROW __nonnull ((1));
 
 #ifdef __USE_XOPEN2K
 /* Get the clock selected for the conditon variable attribute ATTR.  */
@@ -1071,7 +1071,7 @@ extern int pthread_barrierattr_getpshared (__const pthread_barrierattr_t *
 
 /* Set the process-shared flag of the barrier attribute ATTR.  */
 extern int pthread_barrierattr_setpshared (pthread_barrierattr_t *__attr,
-                                           int __pshared)
+                                          int __pshared)
      __THROW __nonnull ((1));
 #endif
 
index 9aa4b5aebb8790ac591d826bfbce8ce691e4081c..5553f4b28a9f6819daddfd7576e8a66304f13546 100644 (file)
@@ -1,4 +1,5 @@
-/* Copyright (C) 1991,1996,1997,2000-2004,2009 Free Software Foundation, Inc.
+/* Copyright (C) 1991,1996,1997,2000-2004,2009,2010 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
@@ -58,52 +59,52 @@ confstr (name, buf, len)
 
        string_len = 0;
 #ifndef _POSIX_V7_ILP32_OFF32
-        if (__sysconf (_SC_V7_ILP32_OFF32) > 0)
+       if (__sysconf (_SC_V7_ILP32_OFF32) > 0)
 #endif
 #if !defined _POSIX_V7_ILP32_OFF32 || _POSIX_V7_ILP32_OFF32 > 0
-          {
-            memcpy (restenvs + string_len, "POSIX_V7_ILP32_OFF32",
-                    sizeof "POSIX_V7_ILP32_OFF32" - 1);
-            string_len += sizeof "POSIX_V7_ILP32_OFF32" - 1;
-          }
+         {
+           memcpy (restenvs + string_len, "POSIX_V7_ILP32_OFF32",
+                   sizeof "POSIX_V7_ILP32_OFF32" - 1);
+           string_len += sizeof "POSIX_V7_ILP32_OFF32" - 1;
+         }
 #endif
 #ifndef _POSIX_V7_ILP32_OFFBIG
-        if (__sysconf (_SC_V7_ILP32_OFFBIG) > 0)
+       if (__sysconf (_SC_V7_ILP32_OFFBIG) > 0)
 #endif
 #if !defined _POSIX_V7_ILP32_OFFBIG || _POSIX_V7_ILP32_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V7_ILP32_OFFBIG",
-                    sizeof "POSIX_V7_ILP32_OFFBIG" - 1);
-            string_len += sizeof "POSIX_V7_ILP32_OFFBIG" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V7_ILP32_OFFBIG",
+                   sizeof "POSIX_V7_ILP32_OFFBIG" - 1);
+           string_len += sizeof "POSIX_V7_ILP32_OFFBIG" - 1;
+         }
 #endif
 #ifndef _POSIX_V7_LP64_OFF64
-        if (__sysconf (_SC_V7_LP64_OFF64) > 0)
+       if (__sysconf (_SC_V7_LP64_OFF64) > 0)
 #endif
 #if !defined _POSIX_V7_LP64_OFF64 || _POSIX_V7_LP64_OFF64 > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V7_LP64_OFF64",
-                    sizeof "POSIX_V7_LP64_OFF64" - 1);
-            string_len += sizeof "POSIX_V7_LP64_OFF64" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V7_LP64_OFF64",
+                   sizeof "POSIX_V7_LP64_OFF64" - 1);
+           string_len += sizeof "POSIX_V7_LP64_OFF64" - 1;
+         }
 #endif
 #ifndef _POSIX_V7_LPBIG_OFFBIG
-        if (__sysconf (_SC_V7_LPBIG_OFFBIG) > 0)
+       if (__sysconf (_SC_V7_LPBIG_OFFBIG) > 0)
 #endif
 #if !defined _POSIX_V7_LPBIG_OFFBIG || _POSIX_V7_LPBIG_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V7_LPBIG_OFFBIG",
-                    sizeof "POSIX_V7_LPBIG_OFFBIG" - 1);
-            string_len += sizeof "POSIX_V7_LPBIG_OFFBIG" - 1;
-          }
-#endif
-        restenvs[string_len++] = '\0';
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V7_LPBIG_OFFBIG",
+                   sizeof "POSIX_V7_LPBIG_OFFBIG" - 1);
+           string_len += sizeof "POSIX_V7_LPBIG_OFFBIG" - 1;
+         }
+#endif
+       restenvs[string_len++] = '\0';
        string = restenvs;
       }
       break;
@@ -121,52 +122,52 @@ confstr (name, buf, len)
 
        string_len = 0;
 #ifndef _POSIX_V6_ILP32_OFF32
-        if (__sysconf (_SC_V6_ILP32_OFF32) > 0)
+       if (__sysconf (_SC_V6_ILP32_OFF32) > 0)
 #endif
 #if !defined _POSIX_V6_ILP32_OFF32 || _POSIX_V6_ILP32_OFF32 > 0
-          {
-            memcpy (restenvs + string_len, "POSIX_V6_ILP32_OFF32",
-                    sizeof "POSIX_V6_ILP32_OFF32" - 1);
-            string_len += sizeof "POSIX_V6_ILP32_OFF32" - 1;
-          }
+         {
+           memcpy (restenvs + string_len, "POSIX_V6_ILP32_OFF32",
+                   sizeof "POSIX_V6_ILP32_OFF32" - 1);
+           string_len += sizeof "POSIX_V6_ILP32_OFF32" - 1;
+         }
 #endif
 #ifndef _POSIX_V6_ILP32_OFFBIG
-        if (__sysconf (_SC_V6_ILP32_OFFBIG) > 0)
+       if (__sysconf (_SC_V6_ILP32_OFFBIG) > 0)
 #endif
 #if !defined _POSIX_V6_ILP32_OFFBIG || _POSIX_V6_ILP32_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V6_ILP32_OFFBIG",
-                    sizeof "POSIX_V6_ILP32_OFFBIG" - 1);
-            string_len += sizeof "POSIX_V6_ILP32_OFFBIG" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V6_ILP32_OFFBIG",
+                   sizeof "POSIX_V6_ILP32_OFFBIG" - 1);
+           string_len += sizeof "POSIX_V6_ILP32_OFFBIG" - 1;
+         }
 #endif
 #ifndef _POSIX_V6_LP64_OFF64
-        if (__sysconf (_SC_V6_LP64_OFF64) > 0)
+       if (__sysconf (_SC_V6_LP64_OFF64) > 0)
 #endif
 #if !defined _POSIX_V6_LP64_OFF64 || _POSIX_V6_LP64_OFF64 > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V6_LP64_OFF64",
-                    sizeof "POSIX_V6_LP64_OFF64" - 1);
-            string_len += sizeof "POSIX_V6_LP64_OFF64" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V6_LP64_OFF64",
+                   sizeof "POSIX_V6_LP64_OFF64" - 1);
+           string_len += sizeof "POSIX_V6_LP64_OFF64" - 1;
+         }
 #endif
 #ifndef _POSIX_V6_LPBIG_OFFBIG
-        if (__sysconf (_SC_V6_LPBIG_OFFBIG) > 0)
+       if (__sysconf (_SC_V6_LPBIG_OFFBIG) > 0)
 #endif
 #if !defined _POSIX_V6_LPBIG_OFFBIG || _POSIX_V6_LPBIG_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "POSIX_V6_LPBIG_OFFBIG",
-                    sizeof "POSIX_V6_LPBIG_OFFBIG" - 1);
-            string_len += sizeof "POSIX_V6_LPBIG_OFFBIG" - 1;
-          }
-#endif
-        restenvs[string_len++] = '\0';
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "POSIX_V6_LPBIG_OFFBIG",
+                   sizeof "POSIX_V6_LPBIG_OFFBIG" - 1);
+           string_len += sizeof "POSIX_V6_LPBIG_OFFBIG" - 1;
+         }
+#endif
+       restenvs[string_len++] = '\0';
        string = restenvs;
       }
       break;
@@ -184,52 +185,52 @@ confstr (name, buf, len)
 
        string_len = 0;
 #ifndef _XBS5_ILP32_OFF32
-        if (__sysconf (_SC_XBS5_ILP32_OFF32) > 0)
+       if (__sysconf (_SC_XBS5_ILP32_OFF32) > 0)
 #endif
 #if !defined _XBS5_ILP32_OFF32 || _XBS5_ILP32_OFF32 > 0
-          {
-            memcpy (restenvs + string_len, "XBS5_ILP32_OFF32",
-                    sizeof "XBS5_ILP32_OFF32" - 1);
-            string_len += sizeof "XBS5_ILP32_OFF32" - 1;
-          }
+         {
+           memcpy (restenvs + string_len, "XBS5_ILP32_OFF32",
+                   sizeof "XBS5_ILP32_OFF32" - 1);
+           string_len += sizeof "XBS5_ILP32_OFF32" - 1;
+         }
 #endif
 #ifndef _XBS5_ILP32_OFFBIG
-        if (__sysconf (_SC_XBS5_ILP32_OFFBIG) > 0)
+       if (__sysconf (_SC_XBS5_ILP32_OFFBIG) > 0)
 #endif
 #if !defined _XBS5_ILP32_OFFBIG || _XBS5_ILP32_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "XBS5_ILP32_OFFBIG",
-                    sizeof "XBS5_ILP32_OFFBIG" - 1);
-            string_len += sizeof "XBS5_ILP32_OFFBIG" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "XBS5_ILP32_OFFBIG",
+                   sizeof "XBS5_ILP32_OFFBIG" - 1);
+           string_len += sizeof "XBS5_ILP32_OFFBIG" - 1;
+         }
 #endif
 #ifndef _XBS5_LP64_OFF64
-        if (__sysconf (_SC_XBS5_LP64_OFF64) > 0)
+       if (__sysconf (_SC_XBS5_LP64_OFF64) > 0)
 #endif
 #if !defined _XBS5_LP64_OFF64 || _XBS5_LP64_OFF64 > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "XBS5_LP64_OFF64",
-                    sizeof "XBS5_LP64_OFF64" - 1);
-            string_len += sizeof "XBS5_LP64_OFF64" - 1;
-          }
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "XBS5_LP64_OFF64",
+                   sizeof "XBS5_LP64_OFF64" - 1);
+           string_len += sizeof "XBS5_LP64_OFF64" - 1;
+         }
 #endif
 #ifndef _XBS5_LPBIG_OFFBIG
-        if (__sysconf (_SC_XBS5_LPBIG_OFFBIG) > 0)
+       if (__sysconf (_SC_XBS5_LPBIG_OFFBIG) > 0)
 #endif
 #if !defined _XBS5_LPBIG_OFFBIG || _XBS5_LPBIG_OFFBIG > 0
-          {
-            if (string_len)
-              restenvs[string_len++] = '\n';
-            memcpy (restenvs + string_len, "XBS5_LPBIG_OFFBIG",
-                    sizeof "XBS5_LPBIG_OFFBIG" - 1);
-            string_len += sizeof "XBS5_LPBIG_OFFBIG" - 1;
-          }
-#endif
-        restenvs[string_len++] = '\0';
+         {
+           if (string_len)
+             restenvs[string_len++] = '\n';
+           memcpy (restenvs + string_len, "XBS5_LPBIG_OFFBIG",
+                   sizeof "XBS5_LPBIG_OFFBIG" - 1);
+           string_len += sizeof "XBS5_LPBIG_OFFBIG" - 1;
+         }
+#endif
+       restenvs[string_len++] = '\0';
        string = restenvs;
       }
       break;
@@ -242,7 +243,7 @@ confstr (name, buf, len)
 #  error "__ILP32_OFF32_CFLAGS should not be defined"
 # elif !defined _POSIX_V7_ILP32_OFF32
       if (__sysconf (_SC_V7_ILP32_OFF32) < 0)
-        break;
+       break;
 # endif
       string = __ILP32_OFF32_CFLAGS;
       string_len = sizeof (__ILP32_OFF32_CFLAGS);
@@ -257,7 +258,7 @@ confstr (name, buf, len)
 #  error "__ILP32_OFFBIG_CFLAGS should not be defined"
 # elif !defined _POSIX_V7_ILP32_OFFBIG
       if (__sysconf (_SC_V7_ILP32_OFFBIG) < 0)
-        break;
+       break;
 # endif
       string = __ILP32_OFFBIG_CFLAGS;
       string_len = sizeof (__ILP32_OFFBIG_CFLAGS);
@@ -272,7 +273,7 @@ confstr (name, buf, len)
 #  error "__LP64_OFF64_CFLAGS should not be defined"
 # elif !defined _POSIX_V7_LP64_OFF64
       if (__sysconf (_SC_V7_LP64_OFF64) < 0)
-        break;
+       break;
 # endif
       string = __LP64_OFF64_CFLAGS;
       string_len = sizeof (__LP64_OFF64_CFLAGS);
@@ -287,7 +288,7 @@ confstr (name, buf, len)
 #  error "__ILP32_OFF32_LDFLAGS should not be defined"
 # elif !defined _POSIX_V7_ILP32_OFF32
       if (__sysconf (_SC_V7_ILP32_OFF32) < 0)
-        break;
+       break;
 # endif
       string = __ILP32_OFF32_LDFLAGS;
       string_len = sizeof (__ILP32_OFF32_LDFLAGS);
@@ -302,7 +303,7 @@ confstr (name, buf, len)
 #  error "__ILP32_OFFBIG_LDFLAGS should not be defined"
 # elif !defined _POSIX_V7_ILP32_OFFBIG
       if (__sysconf (_SC_V7_ILP32_OFFBIG) < 0)
-        break;
+       break;
 # endif
       string = __ILP32_OFFBIG_LDFLAGS;
       string_len = sizeof (__ILP32_OFFBIG_LDFLAGS);
@@ -317,7 +318,7 @@ confstr (name, buf, len)
 #  error "__LP64_OFF64_LDFLAGS should not be defined"
 # elif !defined _POSIX_V7_LP64_OFF64
       if (__sysconf (_SC_V7_LP64_OFF64) < 0)
-        break;
+       break;
 # endif
       string = __LP64_OFF64_LDFLAGS;
       string_len = sizeof (__LP64_OFF64_LDFLAGS);
@@ -402,6 +403,13 @@ confstr (name, buf, len)
       return 0;
 #endif
 
+    case _CS_V6_ENV:
+    case _CS_V7_ENV:
+      /* Maybe something else is needed in future.  */
+      string = "POSIXLY_CORRECT=1";
+      string_len = sizeof ("POSIXLY_CORRECT=1");
+      break;
+
     default:
       __set_errno (EINVAL);
       return 0;
index a03e19c4e3a8a4737fca8891952c36ce6a72af53..7356eeb3626665a0524bbf1be37398ea22e05d7e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2006, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1991-2006, 2007, 2010 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
@@ -216,7 +216,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
   int errval = 0;
 #ifndef COMPILE_WSCANF
   __locale_t loc = _NL_CURRENT_LOCALE;
-  struct locale_data *const curctype = loc->__locales[LC_CTYPE];
+  struct __locale_data *const curctype = loc->__locales[LC_CTYPE];
 #endif
 
   /* Errno of last failed inchar call.  */
@@ -294,7 +294,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
 
  {
 #ifndef COMPILE_WSCANF
-   struct locale_data *const curnumeric = loc->__locales[LC_NUMERIC];
+   struct __locale_data *const curnumeric = loc->__locales[LC_NUMERIC];
 #endif
 
    /* Figure out the decimal point character.  */
@@ -1389,7 +1389,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
                    {
 #ifdef COMPILE_WSCANF
                      wcdigits[n] = (const wchar_t *)
-                        _NL_CURRENT (LC_CTYPE, _NL_CTYPE_INDIGITS0_WC + n);
+                       _NL_CURRENT (LC_CTYPE, _NL_CTYPE_INDIGITS0_WC + n);
 
                      wchar_t *wc_extended = (wchar_t *)
                        alloca ((to_level + 2) * sizeof (wchar_t));
@@ -1399,7 +1399,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
                      wcdigits_extended[n] = wc_extended;
 #else
                      mbdigits[n]
-                        = curctype->values[_NL_CTYPE_INDIGITS0_MB + n].string;
+                       = curctype->values[_NL_CTYPE_INDIGITS0_MB + n].string;
 
                      /*  Get the equivalent wide char in map.  */
                      wint_t extra_wcdigit = __towctrans (L'0' + n, map);
@@ -2047,9 +2047,9 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
              wcdigits[11] = __towctrans (L'.', map);
 
              /* If we have not read any character or have just read
-                locale decimal point which matches the decimal point
-                for localized FP numbers, then we may have localized
-                digits.  Note, we test GOT_DOT above.  */
+                locale decimal point which matches the decimal point
+                for localized FP numbers, then we may have localized
+                digits.  Note, we test GOT_DOT above.  */
 #ifdef COMPILE_WSCANF
              if (wpsize == 0 || (wpsize == 1 && wcdigits[11] == decimal))
 #else
@@ -2086,7 +2086,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
                  bool have_locthousands = (flags & GROUP) != 0;
 
                  /* Now get the digits and the thousands-sep equivalents.  */
-                 for (int n = 0; n < 11; ++n)
+                 for (int n = 0; n < 11; ++n)
                    {
                      if (n < 10)
                        wcdigits[n] = __towctrans (L'0' + n, map);
@@ -2385,7 +2385,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
                          if (wc <= runp[1] && not_in)
                            {
                              /* The current character is not in the
-                                 scanset.  */
+                                scanset.  */
                              ungetc (c, s);
                              goto out;
                            }
@@ -2611,7 +2611,7 @@ _IO_vfscanf_internal (_IO_FILE *s, const char *format, _IO_va_list argptr,
                          if (wc <= runp[1] && not_in)
                            {
                              /* The current character is not in the
-                                 scanset.  */
+                                scanset.  */
                              ungetc (c, s);
                              goto out2;
                            }
index dc51d67170a4fdd587730fe843395009e3f8bff1..8669f35d764aa09be2fd46ed1bfc01e8dd220f18 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2007, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1991-2007, 2009, 2010 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
@@ -37,7 +37,7 @@ __BEGIN_DECLS
 #ifndef __need_malloc_and_calloc
 #define        _STDLIB_H       1
 
-#if defined __USE_XOPEN && !defined _SYS_WAIT_H
+#if (defined __USE_XOPEN || defined __USE_XOPEN2K8) && !defined _SYS_WAIT_H
 /* XPG requires a few symbols from <sys/wait.h> being defined.  */
 # include <bits/waitflags.h>
 # include <bits/waitstatus.h>
@@ -91,7 +91,7 @@ typedef union
 # ifdef __WIFCONTINUED
 #  define WIFCONTINUED(status) __WIFCONTINUED (__WAIT_INT (status))
 # endif
-#endif /* X/Open and <sys/wait.h> not included.  */
+#endif /* X/Open or XPG7 and <sys/wait.h> not included.  */
 
 __BEGIN_NAMESPACE_STD
 /* Returned by `div'.  */
@@ -497,7 +497,8 @@ extern void cfree (void *__ptr) __THROW;
 # include <alloca.h>
 #endif /* Use GNU, BSD, or misc.  */
 
-#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if (defined __USE_BSD || defined __USE_XOPEN_EXTENDED) \
+    && !defined __USE_XOPEN2K
 /* Allocate SIZE bytes on a page boundary.  The storage cannot be freed.  */
 extern void *valloc (size_t __size) __THROW __attribute_malloc__ __wur;
 #endif
@@ -596,13 +597,17 @@ extern int clearenv (void) __THROW;
 #endif
 
 
-#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED
+#if (defined __USE_MISC || defined __USE_XOPEN_EXTENDED) \
+    && !defined __USE_XOPEN2K
 /* Generate a unique temporary file name from TEMPLATE.
    The last six characters of TEMPLATE must be "XXXXXX";
    they are replaced with a string that makes the file name unique.
    Returns TEMPLATE, or a null pointer if it cannot get a unique file name.  */
 extern char *mktemp (char *__template) __THROW __nonnull ((1)) __wur;
+#endif
 
+#if defined __USE_MISC || defined __USE_XOPEN_EXTENDED \
+    || defined __USE_XOPEN2K8
 /* Generate a unique temporary file name from TEMPLATE.
    The last six characters of TEMPLATE must be "XXXXXX";
    they are replaced with a string that makes the filename unique.
@@ -792,7 +797,8 @@ __END_NAMESPACE_C99
 #endif
 
 
-#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED
+#if (defined __USE_SVID || defined __USE_XOPEN_EXTENDED) \
+    && !defined __USE_XOPEN2K
 /* Convert floating point numbers to strings.  The returned values are
    valid only until another call to the same function.  */
 
@@ -880,7 +886,7 @@ extern int rpmatch (__const char *__response) __THROW __nonnull ((1)) __wur;
 #endif
 
 
-#ifdef __USE_XOPEN_EXTENDED
+#if defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
 /* Parse comma separated suboption from *OPTIONP and match against
    strings in TOKENS.  If found return index and set *VALUEP to
    optional value introduced by an equal sign.  If the suboption is
@@ -902,7 +908,7 @@ extern void setkey (__const char *__key) __THROW __nonnull ((1));
 
 /* X/Open pseudo terminal handling.  */
 
-#ifdef __USE_XOPEN2K
+#ifdef __USE_XOPEN2KXSI
 /* Return a master pseudo-terminal handle.  */
 extern int posix_openpt (int __oflag) __wur;
 #endif
index eb7a17801ad8f525d594a28a4a746288ca2cd4c3..7642753cb1415e154c5e7c9ac34583211b68c950 100644 (file)
@@ -1,5 +1,5 @@
 /* Formatting a monetary value according to the given locale.
-   Copyright (C) 1996,1997,2002,2004,2006,2009 Free Software Foundation, Inc.
+   Copyright (C) 1996,1997,2002,2004,2006,2009,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
@@ -88,7 +88,7 @@ ssize_t
 __vstrfmon_l (char *s, size_t maxsize, __locale_t loc, const char *format,
              va_list ap)
 {
-  struct locale_data *current = loc->__locales[LC_MONETARY];
+  struct __locale_data *current = loc->__locales[LC_MONETARY];
   _IO_strfile f;
   struct printf_info info;
   char *dest;                  /* Pointer so copy the output.  */
index 9ddfa3fa6635af51c59f4cd55f248e910a602a05..cde1280e552c712484b7a9c2c47e2fa43528ae61 100644 (file)
@@ -1,5 +1,5 @@
 /* Convert string representing a number to float value, using given locale.
-   Copyright (C) 1997,1998,2002,2004,2005,2006,2007,2008,2009
+   Copyright (C) 1997,1998,2002,2004,2005,2006,2007,2008,2009,2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
@@ -214,15 +214,15 @@ round_and_return (mp_limb_t *retval, int exponent, int negative,
                        != 0);
 
          (void) __mpn_rshift (retval, &retval[shift / BITS_PER_MP_LIMB],
-                               RETURN_LIMB_SIZE - (shift / BITS_PER_MP_LIMB),
-                               shift % BITS_PER_MP_LIMB);
-          MPN_ZERO (&retval[RETURN_LIMB_SIZE - (shift / BITS_PER_MP_LIMB)],
-                    shift / BITS_PER_MP_LIMB);
+                              RETURN_LIMB_SIZE - (shift / BITS_PER_MP_LIMB),
+                              shift % BITS_PER_MP_LIMB);
+         MPN_ZERO (&retval[RETURN_LIMB_SIZE - (shift / BITS_PER_MP_LIMB)],
+                   shift / BITS_PER_MP_LIMB);
        }
       else if (shift > 0)
        {
-          round_limb = retval[0];
-          round_bit = shift - 1;
+         round_limb = retval[0];
+         round_bit = shift - 1;
          (void) __mpn_rshift (retval, retval, RETURN_LIMB_SIZE, shift);
        }
       /* This is a hook for the m68k long double format, where the
@@ -237,14 +237,14 @@ round_and_return (mp_limb_t *retval, int exponent, int negative,
 
   if ((round_limb & (((mp_limb_t) 1) << round_bit)) != 0
       && (more_bits || (retval[0] & 1) != 0
-          || (round_limb & ((((mp_limb_t) 1) << round_bit) - 1)) != 0))
+         || (round_limb & ((((mp_limb_t) 1) << round_bit) - 1)) != 0))
     {
       mp_limb_t cy = __mpn_add_1 (retval, retval, RETURN_LIMB_SIZE, 1);
 
       if (((MANT_DIG % BITS_PER_MP_LIMB) == 0 && cy) ||
-          ((MANT_DIG % BITS_PER_MP_LIMB) != 0 &&
-           (retval[RETURN_LIMB_SIZE - 1]
-            & (((mp_limb_t) 1) << (MANT_DIG % BITS_PER_MP_LIMB))) != 0))
+         ((MANT_DIG % BITS_PER_MP_LIMB) != 0 &&
+          (retval[RETURN_LIMB_SIZE - 1]
+           & (((mp_limb_t) 1) << (MANT_DIG % BITS_PER_MP_LIMB))) != 0))
        {
          ++exponent;
          (void) __mpn_rshift (retval, retval, RETURN_LIMB_SIZE, 1);
@@ -465,7 +465,7 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
   /* Used in several places.  */
   int cnt;
 
-  struct locale_data *current = loc->__locales[LC_NUMERIC];
+  struct __locale_data *current = loc->__locales[LC_NUMERIC];
 
   if (__builtin_expect (group, 0))
     {
@@ -738,7 +738,7 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
                                         grouping);
 #endif
       if (cp != tp)
-        {
+       {
          /* Less than the entire string was correctly grouped.  */
 
          if (tp == start_of_digits)
@@ -1113,14 +1113,14 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
            memcpy (retval, &num[least_idx],
                    RETURN_LIMB_SIZE * sizeof (mp_limb_t));
          else
-            {
-              for (i = least_idx; i < numsize - 1; ++i)
-                retval[i - least_idx] = (num[i] >> least_bit)
-                                        | (num[i + 1]
-                                           << (BITS_PER_MP_LIMB - least_bit));
-              if (i - least_idx < RETURN_LIMB_SIZE)
-                retval[RETURN_LIMB_SIZE - 1] = num[i] >> least_bit;
-            }
+           {
+             for (i = least_idx; i < numsize - 1; ++i)
+               retval[i - least_idx] = (num[i] >> least_bit)
+                                       | (num[i + 1]
+                                          << (BITS_PER_MP_LIMB - least_bit));
+             if (i - least_idx < RETURN_LIMB_SIZE)
+               retval[RETURN_LIMB_SIZE - 1] = num[i] >> least_bit;
+           }
 
          /* Check whether any limb beside the ones in RETVAL are non-zero.  */
          for (i = 0; num[i] == 0; ++i)
@@ -1174,7 +1174,7 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
 #if RETURN_LIMB_SIZE > 1
       if (numsize < RETURN_LIMB_SIZE)
 # if RETURN_LIMB_SIZE == 2
-        retval[numsize] = 0;
+       retval[numsize] = 0;
 # else
        MPN_ZERO (retval + numsize, RETURN_LIMB_SIZE - numsize);
 # endif
@@ -1201,14 +1201,14 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
 
     /* For the fractional part we need not process too many digits.  One
        decimal digits gives us log_2(10) ~ 3.32 bits.  If we now compute
-                        ceil(BITS / 3) =: N
+                       ceil(BITS / 3) =: N
        digits we should have enough bits for the result.  The remaining
        decimal digits give us the information that more bits are following.
        This can be used while rounding.  (Two added as a safety margin.)  */
     if (dig_no - int_no > (MANT_DIG - bits + 2) / 3 + 2)
       {
-        dig_no = int_no + (MANT_DIG - bits + 2) / 3 + 2;
-        more_bits = 1;
+       dig_no = int_no + (MANT_DIG - bits + 2) / 3 + 2;
+       more_bits = 1;
       }
     else
       more_bits = 0;
@@ -1264,9 +1264,9 @@ ____STRTOF_INTERNAL (nptr, endptr, group, loc)
        digits.  This is done by a "quasi fix point" number representation.
 
        num:   ddddddddddd . 0000000000000000000000
-              |--- m ---|
+             |--- m ---|
        den:                            ddddddddddd      n >= m
-                                       |--- n ---|
+                                      |--- n ---|
      */
 
     count_leading_zeros (cnt, den[densize - 1]);
index ba0aba7919d8ee5b6623866d658424945432e529..9181bf10ee6681d57a013bb000c3ff380e17f141 100644 (file)
@@ -1,5 +1,5 @@
 /* Convert string representing a number to integer value, using given locale.
-   Copyright (C) 1997, 2002, 2004, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 1997, 2002, 2004, 2006, 2007, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
 
@@ -243,7 +243,7 @@ INTERNAL (__strtol_l) (nptr, endptr, base, group, loc)
 #endif
 
 #ifdef USE_NUMBER_GROUPING
-  struct locale_data *current = loc->__locales[LC_NUMERIC];
+  struct __locale_data *current = loc->__locales[LC_NUMERIC];
   /* The thousands character of the current locale.  */
 # ifdef USE_WIDE_CHAR
   wchar_t thousands = L'\0';
index 8bd84b10aa27484c038a71e55cd4a9aae2cb8139..d8d11392e3feffe828f4a760f8031bdeb285325e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995,96,97,2002, 2004, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 1995-1997,2002,2004,2007,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Written by Ulrich Drepper <drepper@gnu.org>, 1995.
 
@@ -48,7 +48,7 @@ STRCOLL (s1, s2, l)
      const STRING_TYPE *s2;
      __locale_t l;
 {
-  struct locale_data *current = l->__locales[LC_COLLATE];
+  struct __locale_data *current = l->__locales[LC_COLLATE];
   uint_fast32_t nrules = current->values[_NL_ITEM_INDEX (_NL_COLLATE_NRULES)].word;
   /* We don't assign the following values right away since it might be
      unnecessary in case there are no rules.  */
index 3c760092f067b1facc1493c4b70ee24cd97ddcc2..388402189f149a52c6de2c93225052b887e96999 100644 (file)
@@ -1,4 +1,5 @@
-/* Copyright (C) 1991-1993,1995-2004,2007,2009 Free Software Foundation, Inc.
+/* Copyright (C) 1991-1993,1995-2004,2007,2009,2010
+   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
@@ -168,7 +169,8 @@ extern size_t strxfrm_l (char *__dest, __const char *__src, size_t __n,
                         __locale_t __l) __THROW __nonnull ((2, 4));
 #endif
 
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
+#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED \
+    || defined __USE_XOPEN2K8
 /* Duplicate S, returning an identical malloc'd string.  */
 extern char *strdup (__const char *__s)
      __THROW __attribute_malloc__ __nonnull ((1));
index 20f2f149bdea97134b6db5360aa4c74564847247..351b4265412c5510f17412a0d148ee9942d2f6ad 100644 (file)
@@ -1,5 +1,4 @@
-/* Copyright (C) 1995, 1996, 1997, 2002, 2004, 2005, 2006
-   Free Software Foundation, Inc.
+/* Copyright (C) 1995-1997,2002,2004-2006,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Written by Ulrich Drepper <drepper@gnu.org>, 1995.
 
@@ -86,7 +85,7 @@ utf8_encode (char *buf, int val)
 size_t
 STRXFRM (STRING_TYPE *dest, const STRING_TYPE *src, size_t n, __locale_t l)
 {
-  struct locale_data *current = l->__locales[LC_COLLATE];
+  struct __locale_data *current = l->__locales[LC_COLLATE];
   uint_fast32_t nrules = current->values[_NL_ITEM_INDEX (_NL_COLLATE_NRULES)].word;
   /* We don't assign the following values right away since it might be
      unnecessary in case there are no rules.  */
@@ -137,7 +136,7 @@ STRXFRM (STRING_TYPE *dest, const STRING_TYPE *src, size_t n, __locale_t l)
   if (srclen == 0)
     {
       if (n != 0)
-        *dest = L('\0');
+       *dest = L('\0');
       return 0;
     }
 
index c3f96660cc626cccd84a03d127da63b22545d585..3770f071de61271b7ec0b1f48904effd3002e081 100644 (file)
@@ -1,4 +1,5 @@
-/* Copyright (C) 1992,93,94,96,97,99,2000,2005 Free Software Foundation, Inc.
+/* Copyright (C) 1992-1994,1996,1997,1999,2000,2005,2010
+   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
@@ -16,7 +17,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 84a58ffbc9bdd95f4a6c7f4933396c6d3f6c5960..16e5c520fe7448f2385537c5c602fa90a41f1a1f 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 92, 96, 97, 99, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1991,1992,1996-2000,2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index f9a9e614d59cf086e85e00dc1010463bba6132ea..a860b9fe8aaded4870c123d20341eadb55d4a441 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1996, 1997, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1996, 1997, 2000, 2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index be5272333bd7e28c533e68476b9f9590234318f5..e3f1970086f70317e877324f02d6bed4c3dd489d 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1995-2001, 2002, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1995-2002, 2009, 2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 8eaf7c368b84c89471a4a78e616cae92c1346862..66938895428d2e3aa2fe66742434453b969a9b71 100644 (file)
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux.
-   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007, 2009
+   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #define O_FSYNC                 O_SYNC
 #define O_ASYNC                 020000
 
-#ifdef __USE_GNU
-# define O_DIRECT       040000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0200000 /* Must be a directory.  */
 # define O_NOFOLLOW    0400000 /* Do not follow links.  */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT       040000 /* Direct disk access.  */
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
 
 /* For now Linux has synchronisity options for data and read operations.
    We define the symbols here but let them do the same as O_SYNC since
@@ -84,7 +86,7 @@
 #define F_SETLK64      13      /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     14      /* Set record locking info (blocking).  */
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index c65a11e1ca9c59991d2f4e6a3701e89336c11682..33635fd9e055fc318fa63f293d1c3e8506fd3c37 100644 (file)
@@ -1,5 +1,6 @@
 /* O_*, F_*, FD_* bit values for Linux/IA64.
-   Copyright (C) 1999,2000,2004,2006,2007,2009 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2000, 2004, 2006, 2007, 2009, 2010
+   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
 #define O_FSYNC                O_SYNC
 #define O_ASYNC                020000
 
-#ifdef __USE_GNU
-# define O_DIRECT      040000
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0200000 /* must be a directory */
 # define O_NOFOLLOW    0400000 /* don't follow links */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT      040000
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
 
 #ifdef __USE_LARGEFILE64
 /* Not necessary, files are always with 64bit off_t.  */
@@ -80,7 +83,7 @@
 #define F_SETLK64      6       /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     7       /* Set record locking info (blocking).  */
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
@@ -96,6 +99,8 @@
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 75a331828617c6e68b98d5eba020db359373dacc..98dadf9984cce94e57ababc1ee4148b286e237a2 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2000, 2001, 2002, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1999-2002, 2009, 2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 40fe1e50d777044c8c4c2ec84b432f362f29a1e3..fea347bfc21308a192c42425f1fb4972eddfc1e6 100644 (file)
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux/PowerPC.
-   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2003, 2004, 2006, 2007, 2009
+   Copyright (C) 1995-1998, 2000, 2003, 2004, 2006, 2007, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #define O_FSYNC                O_SYNC
 #define O_ASYNC                020000
 
-#ifdef __USE_GNU
-# define O_DIRECT      0400000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY    040000 /* Must be a directory.  */
 # define O_NOFOLLOW    0100000 /* Do not follow links.  */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT      0400000 /* Direct disk access.  */
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
 
 #ifdef __USE_LARGEFILE64
 # define O_LARGEFILE   0200000
@@ -84,7 +86,7 @@
 #define F_SETLK64      13      /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     14      /* Set record locking info (blocking).  */
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 81879ca1fe5a258ac60f29bb399dabe5c2e25505..90273769796741949269be9c578c642dc2e5e452 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2009
+/* Copyright (C) 1992, 1995-2002, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -17,7 +17,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index c9e6a4504b2911cbf5f9ad7bab7f8d19035f5a86..aeb1e0fe9b57d8cb7c82d23f52e57965f0c2a004 100644 (file)
@@ -1,5 +1,6 @@
 /* O_*, F_*, FD_* bit values for Linux.
-   Copyright (C) 2000,2001,2002,2004,2006,2007,2009 Free Software Foundation, Inc.
+   Copyright (C) 2000-2002,2004,2006,2007,2009,2010
+   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
 #define O_FSYNC                 O_SYNC
 #define O_ASYNC                 020000
 
-#ifdef __USE_GNU
-# define O_DIRECT       040000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0200000 /* Must be a directory.  */
 # define O_NOFOLLOW    0400000 /* Do not follow links.  */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT       040000 /* Direct disk access.  */
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
 
 #ifdef __USE_LARGEFILE64
 # if __WORDSIZE == 64
 # define F_SETLKW64    14      /* Set record locking info (blocking).  */
 #endif
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 64be9a10fdf62f7ef4ab0850df6478c99d132c70..2cd5396eaa967e2ccc7bd60ff1d67ed4e6ed0601 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000, 2001, 2002, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2001, 2002, 2009, 2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 8eaf7c368b84c89471a4a78e616cae92c1346862..2a4123c61090ccd7c012a3826215325f659fa6f7 100644 (file)
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux.
-   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007, 2009
+   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #define O_FSYNC                 O_SYNC
 #define O_ASYNC                 020000
 
-#ifdef __USE_GNU
-# define O_DIRECT       040000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0200000 /* Must be a directory.  */
 # define O_NOFOLLOW    0400000 /* Do not follow links.  */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
 
+#ifdef __USE_GNU
+# define O_DIRECT       040000 /* Direct disk access.  */
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
+
 /* For now Linux has synchronisity options for data and read operations.
    We define the symbols here but let them do the same as O_SYNC since
    this is a superset. */
@@ -84,7 +87,7 @@
 #define F_SETLK64      13      /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     14      /* Set record locking info (blocking).  */
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 03c5ba59bd13269d7ff7b40d7cd08d0fb20a8c68..c491a415b4cd3b2f3e1cccab0370bf7bcd60fe73 100644 (file)
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux/SPARC.
-   Copyright (C) 1995, 1996, 1997, 1998, 2000, 2003, 2004, 2006, 2007, 2009
+   Copyright (C) 1995-1998, 2000, 2003, 2004, 2006, 2007, 2009, 2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #define O_NDELAY       (0x0004 | O_NONBLOCK)
 #define O_NOCTTY       0x8000  /* not fcntl */
 
-#ifdef __USE_GNU
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0x10000 /* must be a directory */
 # define O_NOFOLLOW    0x20000 /* don't follow links */
+# define O_CLOEXEC     0x400000 /* Set close_on_exit.  */
+#endif
+#ifdef __USE_GNU
 # define O_DIRECT      0x100000 /* direct disk access hint */
 # define O_NOATIME     0x200000 /* Do not set atime.  */
-# define O_CLOEXEC     0x400000 /* Set close_on_exit.  */
 #endif
 
 #ifdef __USE_LARGEFILE64
@@ -82,7 +84,7 @@
 #define F_SETFD                2       /* Set file descriptor flags.  */
 #define F_GETFL                3       /* Get file status flags.  */
 #define F_SETFL                4       /* Set file status flags.  */
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_GETOWN      5       /* Get owner (process receiving SIGIO).  */
 # define F_SETOWN      6       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE     1024   /* Set a lease.  */
 # define F_GETLEASE     1025   /* Enquire what lease is active.  */
 # define F_NOTIFY       1026   /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 175fdb8570c96a2a4cb24f1df0f2de46327481d2..407ca2d7b5e86fc3aba70749237b8782c70fbf94 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1995-2002, 2006, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1992,1995-2002,2006,2009,2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 43835081c0b736653f2589f3807d355b82409d86..aa04e0e490dfd962af63de9465171ee4750f6fc4 100644 (file)
@@ -1,5 +1,6 @@
 /* O_*, F_*, FD_* bit values for Linux/x86-64.
-   Copyright (C) 2001,2002,2004,2006,2007,2009 Free Software Foundation, Inc.
+   Copyright (C) 2001,2002,2004,2006,2007,2009,2010
+   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
 #define O_FSYNC                 O_SYNC
 #define O_ASYNC                 020000
 
-#ifdef __USE_GNU
-# define O_DIRECT       040000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   0200000 /* Must be a directory.  */
 # define O_NOFOLLOW    0400000 /* Do not follow links.  */
-# define O_NOATIME     01000000 /* Do not set atime.  */
 # define O_CLOEXEC     02000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT       040000 /* Direct disk access.  */
+# define O_NOATIME     01000000 /* Do not set atime.  */
+#endif
 
 /* For now Linux has synchronisity options for data and read operations.
    We define the symbols here but let them do the same as O_SYNC since
 # define F_SETLKW64    14      /* Set record locking info (blocking).  */
 #endif
 
-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_SETOWN      8       /* Get owner (process receiving SIGIO).  */
 # define F_GETOWN      9       /* Set owner (process receiving SIGIO).  */
 #endif
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                   close-on-exit set.  */
 #endif
index 9d12315e1abfc5409664dbfa8f5657a21ae6a9f6..cfc3f665dc93b662df51e13d21c01bb310a61c45 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999,2000,2001,2002,2003,2009 Free Software Foundation, Inc.
+/* Copyright (C) 1999-2003,2009,2010 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
@@ -16,7 +16,7 @@
    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
    02111-1307 USA.  */
 
-#ifndef _SYS_STAT_H
+#if !defined _SYS_STAT_H && !defined _FCNTL_H
 # error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
 #endif
 
index 95e4f07c736b4e20d6ce36aec413bd46b8836414..9238911147e67e2df3de9410e1100fe1dbab3c6b 100644 (file)
@@ -1,5 +1,5 @@
 /* Helper functions used by strftime/strptime to handle alternate digits.
-   Copyright (C) 1995-2002, 2008 Free Software Foundation, Inc.
+   Copyright (C) 1995-2002, 2008, 2010 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
@@ -31,7 +31,7 @@ __libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
   ((wchar_t *) current->values[_NL_ITEM_INDEX (item)].wstr)
 
 static void
-_nl_init_alt_digit (struct locale_data *current)
+_nl_init_alt_digit (struct __locale_data *current)
 {
   struct lc_time_data *data;
 
@@ -70,7 +70,7 @@ _nl_init_alt_digit (struct locale_data *current)
 
 const char *
 internal_function
-_nl_get_alt_digit (unsigned int number, struct locale_data *current)
+_nl_get_alt_digit (unsigned int number, struct __locale_data *current)
 {
   const char *result;
 
@@ -96,7 +96,7 @@ _nl_get_alt_digit (unsigned int number, struct locale_data *current)
 
 const wchar_t *
 internal_function
-_nl_get_walt_digit (unsigned int number, struct locale_data *current)
+_nl_get_walt_digit (unsigned int number, struct __locale_data *current)
 {
   const wchar_t *result = NULL;
   struct lc_time_data *data;
@@ -149,7 +149,7 @@ _nl_get_walt_digit (unsigned int number, struct locale_data *current)
 
 int
 internal_function
-_nl_parse_alt_digit (const char **strp, struct locale_data *current)
+_nl_parse_alt_digit (const char **strp, struct __locale_data *current)
 {
   const char *str = *strp;
   int result = -1;
index dc4fd54f4ec2ec1c902c190cdf83221dda4657cb..8cf266a3ff7c7a7aa4c89e38805396f0baa60f22 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991,1993,1995-1997,2000,2002,2005
+/* Copyright (C) 1991,1993,1995-1997,2000,2002,2005,2010
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #include <time.h>
 
 /* This is defined in locale/C-time.c in the GNU libc.  */
-extern const struct locale_data _nl_C_LC_TIME attribute_hidden;
+extern const struct __locale_data _nl_C_LC_TIME attribute_hidden;
 #define ab_day_name(DAY) (_nl_C_LC_TIME.values[_NL_ITEM_INDEX (ABDAY_1)+(DAY)].string)
 #define ab_month_name(MON) (_nl_C_LC_TIME.values[_NL_ITEM_INDEX (ABMON_1)+(MON)].string)
 
 static const char format[] = "%.3s %.3s%3d %.2d:%.2d:%.2d %d\n";
-static char result[             3+1+ 3+1+20+1+20+1+20+1+20+1+20+1 + 1];
+static char result[             3+1+ 3+1+20+1+20+1+20+1+20+1+20+1 + 1];
 
 
 static char *
index a6f4a4cb073ff0c1b0ff0877cedf54d17386eecb..6630747cc39a24efe70c722b1fee58fedeb64bfc 100644 (file)
@@ -1,5 +1,5 @@
 /* Helper functions used by strftime/strptime to handle locale-specific "eras".
-   Copyright (C) 1995-2002, 2008 Free Software Foundation, Inc.
+   Copyright (C) 1995-2002, 2008, 2010 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
@@ -36,7 +36,7 @@ __libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
 /* Look up the era information in CURRENT's locale strings and
    cache it in CURRENT->private.  */
 static void internal_function
-_nl_init_era_entries (struct locale_data *current)
+_nl_init_era_entries (struct __locale_data *current)
 {
   size_t cnt;
   struct lc_time_data *data;
@@ -83,7 +83,7 @@ _nl_init_era_entries (struct locale_data *current)
              data->num_eras = 0;
              data->eras = NULL;
            }
-          else
+         else
            {
              const char *ptr = CURRENT (_NL_TIME_ERA_ENTRIES);
              data->num_eras = new_num_eras;
@@ -140,7 +140,7 @@ _nl_init_era_entries (struct locale_data *current)
 
 struct era_entry *
 internal_function
-_nl_get_era_entry (const struct tm *tp, struct locale_data *current)
+_nl_get_era_entry (const struct tm *tp, struct __locale_data *current)
 {
   if (current->private.time == NULL || !current->private.time->era_initialized)
     _nl_init_era_entries (current);
@@ -167,7 +167,7 @@ _nl_get_era_entry (const struct tm *tp, struct locale_data *current)
 
 struct era_entry *
 internal_function
-_nl_select_era_entry (int cnt, struct locale_data *current)
+_nl_select_era_entry (int cnt, struct __locale_data *current)
 {
   if (current->private.time == NULL || !current->private.time->era_initialized)
     _nl_init_era_entries (current);
index 6777f487a2a3365a89747d7ad2c6af117f40d404..aa91e3eb2b007134d7f660233644ec040bd1ed1a 100644 (file)
@@ -1,5 +1,5 @@
 /* Cleanup code for data structures kept by strftime/strptime helper functions.
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2010 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
@@ -21,7 +21,7 @@
 #include <stdlib.h>
 
 void internal_function
-_nl_cleanup_time (struct locale_data *locale)
+_nl_cleanup_time (struct __locale_data *locale)
 {
   struct lc_time_data *const data = locale->private.time;
   if (data != NULL)
index deb75c8e9449d623eb5a288aff753410274cf9af..08c2aeb32be6421cb8075dfae3579da4ee02644a 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2004, 2007, 2008, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2004, 2007-2009, 2010 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
@@ -502,7 +502,7 @@ __strftime_internal (s, maxsize, format, tp, tzset_called ut_argument
       LOCALE_PARAM_DECL
 {
 #if defined _LIBC && defined USE_IN_EXTENDED_LOCALE_MODEL
-  struct locale_data *const current = loc->__locales[LC_TIME];
+  struct __locale_data *const current = loc->__locales[LC_TIME];
 #endif
 
   int hour12 = tp->tm_hour;
index c4a0638fff8b1cf67351ac82974bab444ec607de..ccd2a90705f34e094e4d2c3871795d9a6550e154 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
+/* Copyright (C) 2002,2004,2005,2007,2008,2010 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
@@ -119,7 +119,7 @@ localtime_r (t, tp)
 
 #ifdef _LIBC
 /* This is defined in locale/C-time.c in the GNU libc.  */
-extern const struct locale_data _nl_C_LC_TIME attribute_hidden;
+extern const struct __locale_data _nl_C_LC_TIME attribute_hidden;
 
 # define weekday_name (&_nl_C_LC_TIME.values[_NL_ITEM_INDEX (DAY_1)].string)
 # define ab_weekday_name \
@@ -249,7 +249,7 @@ __strptime_internal (rp, fmt, tmp, statep LOCALE_PARAM)
      LOCALE_PARAM_DECL
 {
 #ifdef _LIBC
-  struct locale_data *const current = locale->__locales[LC_TIME];
+  struct __locale_data *const current = locale->__locales[LC_TIME];
 #endif
 
   const char *rp_backup;
index 2b46131b14751f5fd8f174f122c8e497461084c1..328f16497ccaaf447d301ffdc639bc39af09b973 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998-2002,2004,2005,2008 Free Software Foundation, Inc.
+/* Copyright (C) 1998-2002,2004,2005,2008,2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -150,7 +150,7 @@ __libc_rwlock_define (extern, __libc_setlocale_lock attribute_hidden)
 /* Load conversion functions for the currently selected locale.  */
 void
 internal_function
-__wcsmbs_load_conv (struct locale_data *new_category)
+__wcsmbs_load_conv (struct __locale_data *new_category)
 {
   /* Acquire the lock.  */
   __libc_rwlock_wrlock (__libc_setlocale_lock);
@@ -253,7 +253,7 @@ __wcsmbs_named_conv (struct gconv_fcts *copy, const char *name)
 }
 
 void internal_function
-_nl_cleanup_ctype (struct locale_data *locale)
+_nl_cleanup_ctype (struct __locale_data *locale)
 {
   const struct gconv_fcts *const data = locale->private.ctype;
   if (data != NULL)
index 0cf5da4f8813fb514f362fd25fd5f484fc01a1d6..e2b1bfa9c8df4644e3e6b92f6e13caa2c528260b 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1998-2002, 2010 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -38,7 +38,7 @@ struct gconv_fcts
 extern const struct gconv_fcts __wcsmbs_gconv_fcts_c attribute_hidden;
 
 /* Load conversion functions for the currently selected locale.  */
-extern void __wcsmbs_load_conv (struct locale_data *new_category)
+extern void __wcsmbs_load_conv (struct __locale_data *new_category)
      internal_function;
 
 /* Clone the current `__wcsmbs_load_conv' value.  */
@@ -50,7 +50,7 @@ extern int __wcsmbs_named_conv (struct gconv_fcts *copy, const char *name)
      internal_function;
 
 /* Function used for the `private.cleanup' hook.  */
-extern void _nl_cleanup_ctype (struct locale_data *)
+extern void _nl_cleanup_ctype (struct __locale_data *)
      internal_function attribute_hidden;
 
 
@@ -62,12 +62,12 @@ extern struct __gconv_step *__wcsmbs_getfct (const char *to, const char *from,
                                             size_t *nstepsp)
      attribute_hidden;
 
-extern const struct locale_data _nl_C_LC_CTYPE attribute_hidden;
+extern const struct __locale_data _nl_C_LC_CTYPE attribute_hidden;
 
 /* Check whether the LC_CTYPE locale changed since the last call.
    Update the pointers appropriately.  */
 static inline const struct gconv_fcts *
-get_gconv_fcts (struct locale_data *data)
+get_gconv_fcts (struct __locale_data *data)
 {
   if (__builtin_expect (data->private.ctype == NULL, 0))
     {