summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common/bits
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2009-11-25 15:56:28 +0100
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2009-11-26 18:49:48 +0100
commit0aee3966d647af55231db535b61553531f64d02e (patch)
tree26349c00766d783b251b3e35e6654979fcbfad3b /libc/sysdeps/linux/common/bits
parent3a8d2129f4db2fcdb673f2438cb39963550f73d0 (diff)
sync confname, environments with glibc
Plus related synch. Add a testcase for the sysconf variables based on the one from glibc Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Diffstat (limited to 'libc/sysdeps/linux/common/bits')
-rw-r--r--libc/sysdeps/linux/common/bits/confname.h91
-rw-r--r--libc/sysdeps/linux/common/bits/environments.h28
2 files changed, 102 insertions, 17 deletions
diff --git a/libc/sysdeps/linux/common/bits/confname.h b/libc/sysdeps/linux/common/bits/confname.h
index ab7fdee9d..ec4b72a22 100644
--- a/libc/sysdeps/linux/common/bits/confname.h
+++ b/libc/sysdeps/linux/common/bits/confname.h
@@ -1,5 +1,5 @@
/* `sysconf', `pathconf', and `confstr' NAME values. Generic version.
- Copyright (C) 1993,1995-1998,2000,2001,2003,2004
+ Copyright (C) 1993,1995-1998,2000,2001,2003,2004,2007,2009
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -498,13 +498,39 @@ enum
_SC_IPV6 = _SC_LEVEL1_ICACHE_SIZE + 50,
#define _SC_IPV6 _SC_IPV6
- _SC_RAW_SOCKETS
+ _SC_RAW_SOCKETS,
#define _SC_RAW_SOCKETS _SC_RAW_SOCKETS
+
+ _SC_V7_ILP32_OFF32,
+#define _SC_V7_ILP32_OFF32 _SC_V7_ILP32_OFF32
+ _SC_V7_ILP32_OFFBIG,
+#define _SC_V7_ILP32_OFFBIG _SC_V7_ILP32_OFFBIG
+ _SC_V7_LP64_OFF64,
+#define _SC_V7_LP64_OFF64 _SC_V7_LP64_OFF64
+ _SC_V7_LPBIG_OFFBIG,
+#define _SC_V7_LPBIG_OFFBIG _SC_V7_LPBIG_OFFBIG
+
+ _SC_SS_REPL_MAX,
+#define _SC_SS_REPL_MAX _SC_SS_REPL_MAX
+
+ _SC_TRACE_EVENT_NAME_MAX,
+#define _SC_TRACE_EVENT_NAME_MAX _SC_TRACE_EVENT_NAME_MAX
+ _SC_TRACE_NAME_MAX,
+#define _SC_TRACE_NAME_MAX _SC_TRACE_NAME_MAX
+ _SC_TRACE_SYS_MAX,
+#define _SC_TRACE_SYS_MAX _SC_TRACE_SYS_MAX
+ _SC_TRACE_USER_EVENT_MAX,
+#define _SC_TRACE_USER_EVENT_MAX _SC_TRACE_USER_EVENT_MAX
+
+ _SC_XOPEN_STREAMS,
+#define _SC_XOPEN_STREAMS _SC_XOPEN_STREAMS
+
+ _SC_THREAD_ROBUST_PRIO_INHERIT,
+#define _SC_THREAD_ROBUST_PRIO_INHERIT _SC_THREAD_ROBUST_PRIO_INHERIT
+ _SC_THREAD_ROBUST_PRIO_PROTECT,
+#define _SC_THREAD_ROBUST_PRIO_PROTECT _SC_THREAD_ROBUST_PRIO_PROTECT
};
-#if (defined __USE_POSIX2 || defined __USE_UNIX98 \
- || defined __USE_FILE_OFFSET64 || defined __USE_LARGEFILE64 \
- || defined __USE_LARGEFILE)
/* Values for the NAME argument to `confstr'. */
enum
{
@@ -512,7 +538,21 @@ enum
#define _CS_PATH _CS_PATH
_CS_V6_WIDTH_RESTRICTED_ENVS,
-# define _CS_V6_WIDTH_RESTRICTED_ENVS _CS_V6_WIDTH_RESTRICTED_ENVS
+#define _CS_V6_WIDTH_RESTRICTED_ENVS _CS_V6_WIDTH_RESTRICTED_ENVS
+#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS _CS_V6_WIDTH_RESTRICTED_ENVS
+
+ _CS_GNU_LIBC_VERSION,
+#define _CS_GNU_LIBC_VERSION _CS_GNU_LIBC_VERSION
+ _CS_GNU_LIBPTHREAD_VERSION,
+#define _CS_GNU_LIBPTHREAD_VERSION _CS_GNU_LIBPTHREAD_VERSION
+
+ _CS_V5_WIDTH_RESTRICTED_ENVS,
+#define _CS_V5_WIDTH_RESTRICTED_ENVS _CS_V5_WIDTH_RESTRICTED_ENVS
+#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS _CS_V5_WIDTH_RESTRICTED_ENVS
+
+ _CS_V7_WIDTH_RESTRICTED_ENVS,
+#define _CS_V7_WIDTH_RESTRICTED_ENVS _CS_V7_WIDTH_RESTRICTED_ENVS
+#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS _CS_V7_WIDTH_RESTRICTED_ENVS
# if (defined __USE_FILE_OFFSET64 || defined __USE_LARGEFILE64 \
|| defined __USE_LARGEFILE)
@@ -568,6 +608,7 @@ enum
_CS_XBS5_LPBIG_OFFBIG_LINTFLAGS,
#define _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS
# endif
+
# ifdef __USE_XOPEN2K
_CS_POSIX_V6_ILP32_OFF32_CFLAGS,
#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS _CS_POSIX_V6_ILP32_OFF32_CFLAGS
@@ -599,8 +640,42 @@ enum
#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS
_CS_POSIX_V6_LPBIG_OFFBIG_LIBS,
#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS _CS_POSIX_V6_LPBIG_OFFBIG_LIBS
- _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS
+ _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS,
#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS
# endif
+
+# ifdef __USE_XOPEN2K8
+ _CS_POSIX_V7_ILP32_OFF32_CFLAGS,
+#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS _CS_POSIX_V7_ILP32_OFF32_CFLAGS
+ _CS_POSIX_V7_ILP32_OFF32_LDFLAGS,
+#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS _CS_POSIX_V7_ILP32_OFF32_LDFLAGS
+ _CS_POSIX_V7_ILP32_OFF32_LIBS,
+#define _CS_POSIX_V7_ILP32_OFF32_LIBS _CS_POSIX_V7_ILP32_OFF32_LIBS
+ _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS,
+#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS
+ _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS,
+#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS
+ _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS,
+#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS
+ _CS_POSIX_V7_ILP32_OFFBIG_LIBS,
+#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS _CS_POSIX_V7_ILP32_OFFBIG_LIBS
+ _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS,
+#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS
+ _CS_POSIX_V7_LP64_OFF64_CFLAGS,
+#define _CS_POSIX_V7_LP64_OFF64_CFLAGS _CS_POSIX_V7_LP64_OFF64_CFLAGS
+ _CS_POSIX_V7_LP64_OFF64_LDFLAGS,
+#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS _CS_POSIX_V7_LP64_OFF64_LDFLAGS
+ _CS_POSIX_V7_LP64_OFF64_LIBS,
+#define _CS_POSIX_V7_LP64_OFF64_LIBS _CS_POSIX_V7_LP64_OFF64_LIBS
+ _CS_POSIX_V7_LP64_OFF64_LINTFLAGS,
+#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS _CS_POSIX_V7_LP64_OFF64_LINTFLAGS
+ _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS,
+#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS
+ _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS,
+#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS
+ _CS_POSIX_V7_LPBIG_OFFBIG_LIBS,
+#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
+# endif
};
-#endif
diff --git a/libc/sysdeps/linux/common/bits/environments.h b/libc/sysdeps/linux/common/bits/environments.h
index 4617dc45f..548ea7f84 100644
--- a/libc/sysdeps/linux/common/bits/environments.h
+++ b/libc/sysdeps/linux/common/bits/environments.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2001, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2001, 2004, 2009 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
@@ -27,30 +27,36 @@
`-1' means it is never supported. Undefined means it cannot be
statically decided.
- _POSIX_V6_ILP32_OFF32 32bit int, long, pointers, and off_t type
- _POSIX_V6_ILP32_OFFBIG 32bit int, long, and pointers and larger off_t type
+ _POSIX_V7_ILP32_OFF32 32bit int, long, pointers, and off_t type
+ _POSIX_V7_ILP32_OFFBIG 32bit int, long, and pointers and larger off_t type
- _POSIX_V6_LP64_OFF32 64bit long and pointers and 32bit off_t type
- _POSIX_V6_LPBIG_OFFBIG 64bit long and pointers and large off_t type
+ _POSIX_V7_LP64_OFF32 64bit long and pointers and 32bit off_t type
+ _POSIX_V7_LPBIG_OFFBIG 64bit long and pointers and large off_t type
- The macros _XBS5_ILP32_OFF32, _XBS5_ILP32_OFFBIG, _XBS5_LP64_OFF32, and
- _XBS5_LPBIG_OFFBIG were used in previous versions of the Unix standard
- and are available only for compatibility.
+ The macros _POSIX_V6_ILP32_OFF32, _POSIX_V6_ILP32_OFFBIG,
+ _POSIX_V6_LP64_OFF32, _POSIX_V6_LPBIG_OFFBIG, _XBS5_ILP32_OFF32,
+ _XBS5_ILP32_OFFBIG, _XBS5_LP64_OFF32, and _XBS5_LPBIG_OFFBIG were
+ used in previous versions of the Unix standard and are available
+ only for compatibility.
*/
#if __WORDSIZE == 64
/* We can never provide environments with 32-bit wide pointers. */
+# define _POSIX_V7_ILP32_OFF32 -1
+# define _POSIX_V7_ILP32_OFFBIG -1
# define _POSIX_V6_ILP32_OFF32 -1
# define _POSIX_V6_ILP32_OFFBIG -1
# define _XBS5_ILP32_OFF32 -1
# define _XBS5_ILP32_OFFBIG -1
/* We also have no use (for now) for an environment with bigger pointers
and offsets. */
+# define _POSIX_V7_LPBIG_OFFBIG -1
# define _POSIX_V6_LPBIG_OFFBIG -1
# define _XBS5_LPBIG_OFFBIG -1
/* By default we have 64-bit wide `long int', pointers and `off_t'. */
+# define _POSIX_V7_LP64_OFF64 1
# define _POSIX_V6_LP64_OFF64 1
# define _XBS5_LP64_OFF64 1
@@ -58,15 +64,19 @@
/* By default we have 32-bit wide `int', `long int', pointers and `off_t'
and all platforms support LFS. */
+# define _POSIX_V7_ILP32_OFF32 1
+# define _POSIX_V7_ILP32_OFFBIG 1
# define _POSIX_V6_ILP32_OFF32 1
# define _POSIX_V6_ILP32_OFFBIG 1
# define _XBS5_ILP32_OFF32 1
# define _XBS5_ILP32_OFFBIG 1
/* We optionally provide an environment with the above size but an 64-bit
- side `off_t'. Therefore we don't define _XBS5_ILP32_OFFBIG. */
+ side `off_t'. Therefore we don't define _POSIX_V7_ILP32_OFFBIG. */
/* We can never provide environments with 64-bit wide pointers. */
+# define _POSIX_V7_LP64_OFF64 -1
+# define _POSIX_V7_LPBIG_OFFBIG -1
# define _POSIX_V6_LP64_OFF64 -1
# define _POSIX_V6_LPBIG_OFFBIG -1
# define _XBS5_LP64_OFF64 -1