diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2018-12-27 14:12:05 +0000 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2018-12-27 14:12:05 +0000 |
commit | 963c37d5c0eb62b38f8764b23931c0dcdd497a13 (patch) | |
tree | 12a521ddf17b3e1bb26594656bbb05903c54afd0 /conform/data | |
parent | 7bb5f8a836b916d6ebf7b6921b136e99cea2442d (diff) | |
parent | 3c03baca37fdcb52c3881e653ca392bba7a99c2b (diff) |
Merge tag 'glibc-2.28' into baseline-2.28baseline
The GNU C Library
=================
The GNU C Library version 2.28 is now available.
The GNU C Library is used as *the* C library in the GNU system and
in GNU/Linux systems, as well as many other systems that use Linux
as the kernel.
The GNU C Library is primarily designed to be a portable
and high performance C library. It follows all relevant
standards including ISO C11 and POSIX.1-2008. It is also
internationalized and has one of the most complete
internationalization interfaces known.
The GNU C Library webpage is at http://www.gnu.org/software/libc/
Packages for the 2.28 release may be downloaded from:
http://ftpmirror.gnu.org/libc/
http://ftp.gnu.org/gnu/libc/
The mirror list is at http://www.gnu.org/order/ftp.html
NEWS for version 2.28
=====================
Major new features:
* The localization data for ISO 14651 is updated to match the 2016
Edition 4 release of the standard, this matches data provided by
Unicode 9.0.0. This update introduces significant improvements to the
collation of Unicode characters. This release deviates slightly from
the standard in that the collation element ordering for lowercase and
uppercase LATIN script characters is adjusted to ensure that regular
expressions with ranges like [a-z] and [A-Z] don't interleave e.g. A
is not matched by [a-z]. With the update many locales have been
updated to take advantage of the new collation information. The new
collation information has increased the size of the compiled locale
archive or binary locales.
* The GNU C Library can now be compiled with support for Intel CET, AKA
Intel Control-flow Enforcement Technology. When the library is built
with --enable-cet, the resulting glibc is protected with indirect
branch tracking (IBT) and shadow stack (SHSTK). CET-enabled glibc is
compatible with all existing executables and shared libraries. This
feature is currently supported on i386, x86_64 and x32 with GCC 8 and
binutils 2.29 or later. Note that CET-enabled glibc requires CPUs
capable of multi-byte NOPs, like x86-64 processors as well as Intel
Pentium Pro or newer. NOTE: --enable-cet has been tested for i686,
x86_64 and x32 on non-CET processors. --enable-cet has been tested
for x86_64 and x32 on CET SDVs, but Intel CET support hasn't been
validated for i686.
* The GNU C Library now has correct support for ABSOLUTE symbols
(SHN_ABS-relative symbols). Previously such ABSOLUTE symbols were
relocated incorrectly or in some cases discarded. The GNU linker can
make use of the newer semantics, but it must communicate it to the
dynamic loader by setting the ELF file's identification (EI_ABIVERSION
field) to indicate such support is required.
* Unicode 11.0.0 Support: Character encoding, character type info, and
transliteration tables are all updated to Unicode 11.0.0, using
generator scripts contributed by Mike FABIAN (Red Hat).
* <math.h> functions that round their results to a narrower type are added
from TS 18661-1:2014 and TS 18661-3:2015:
- fadd, faddl, daddl and corresponding fMaddfN, fMaddfNx, fMxaddfN and
fMxaddfNx functions.
- fsub, fsubl, dsubl and corresponding fMsubfN, fMsubfNx, fMxsubfN and
fMxsubfNx functions.
- fmul, fmull, dmull and corresponding fMmulfN, fMmulfNx, fMxmulfN and
fMxmulfNx functions.
- fdiv, fdivl, ddivl and corresponding fMdivfN, fMdivfNx, fMxdivfN and
fMxdivfNx functions.
* Two grammatical forms of month names are now supported for the following
languages: Armenian, Asturian, Catalan, Czech, Kashubian, Occitan, Ossetian,
Scottish Gaelic, Upper Sorbian, and Walloon. The following languages now
support two grammatical forms in abbreviated month names: Catalan, Greek,
and Kashubian.
* Newly added locales: Lower Sorbian (dsb_DE) and Yakut (sah_RU) also
include the support for two grammatical forms of month names.
* Building and running on GNU/Hurd systems now works without out-of-tree
patches.
* The renameat2 function has been added, a variant of the renameat function
which has a flags argument. If the flags are zero, the renameat2 function
acts like renameat. If the flag is not zero and there is no kernel
support for renameat2, the function will fail with an errno value of
EINVAL. This is different from the existing gnulib function renameatu,
which performs a plain rename operation in case of a RENAME_NOREPLACE
flags and a non-existing destination (and therefore has a race condition
that can clobber the destination inadvertently).
* The statx function has been added, a variant of the fstatat64
function with an additional flags argument. If there is no direct
kernel support for statx, glibc provides basic stat support based on
the fstatat64 function.
* IDN domain names in getaddrinfo and getnameinfo now use the system libidn2
library if installed. libidn2 version 2.0.5 or later is recommended. If
libidn2 is not available, internationalized domain names are not encoded
or decoded even if the AI_IDN or NI_IDN flags are passed to getaddrinfo or
getnameinfo. (getaddrinfo calls with non-ASCII names and AI_IDN will fail
with an encoding error.) Flags which used to change the IDN encoding and
decoding behavior (AI_IDN_ALLOW_UNASSIGNED, AI_IDN_USE_STD3_ASCII_RULES,
NI_IDN_ALLOW_UNASSIGNED, NI_IDN_USE_STD3_ASCII_RULES) have been
deprecated. They no longer have any effect.
* Parsing of dynamic string tokens in DT_RPATH, DT_RUNPATH, DT_NEEDED,
DT_AUXILIARY, and DT_FILTER has been expanded to support the full
range of ELF gABI expressions including such constructs as
'$ORIGIN$ORIGIN' (if valid). For SUID/GUID applications the rules
have been further restricted, and where in the past a dynamic string
token sequence may have been interpreted as a literal string it will
now cause a load failure. These load failures were always considered
unspecified behaviour from the perspective of the dynamic loader, and
for safety are now load errors e.g. /foo/${ORIGIN}.so in DT_NEEDED
results in a load failure now.
* Support for ISO C threads (ISO/IEC 9899:2011) has been added. The
implementation includes all the standard functions provided by
<threads.h>:
- thrd_current, thrd_equal, thrd_sleep, thrd_yield, thrd_create,
thrd_detach, thrd_exit, and thrd_join for thread management.
- mtx_init, mtx_lock, mtx_timedlock, mtx_trylock, mtx_unlock, and
mtx_destroy for mutual exclusion.
- call_once for function call synchronization.
- cnd_broadcast, cnd_destroy, cnd_init, cnd_signal, cnd_timedwait, and
cnd_wait for conditional variables.
- tss_create, tss_delete, tss_get, and tss_set for thread-local storage.
Application developers must link against libpthread to use ISO C threads.
Deprecated and removed features, and other changes affecting compatibility:
* The nonstandard header files <libio.h> and <_G_config.h> are no longer
installed. Software that was using either header should be updated to
use standard <stdio.h> interfaces instead.
* The stdio functions 'getc' and 'putc' are no longer defined as macros.
This was never required by the C standard, and the macros just expanded
to call alternative names for the same functions. If you hoped getc and
putc would provide performance improvements over fgetc and fputc, instead
investigate using (f)getc_unlocked and (f)putc_unlocked, and, if
necessary, flockfile and funlockfile.
* All stdio functions now treat end-of-file as a sticky condition. If you
read from a file until EOF, and then the file is enlarged by another
process, you must call clearerr or another function with the same effect
(e.g. fseek, rewind) before you can read the additional data. This
corrects a longstanding C99 conformance bug. It is most likely to affect
programs that use stdio to read interactive input from a terminal.
(Bug #1190.)
* The macros 'major', 'minor', and 'makedev' are now only available from
the header <sys/sysmacros.h>; not from <sys/types.h> or various other
headers that happen to include <sys/types.h>. These macros are rarely
used, not part of POSIX nor XSI, and their names frequently collide with
user code; see https://sourceware.org/bugzilla/show_bug.cgi?id=19239 for
further explanation.
<sys/sysmacros.h> is a GNU extension. Portable programs that require
these macros should first include <sys/types.h>, and then include
<sys/sysmacros.h> if __GNU_LIBRARY__ is defined.
* The tilegx*-*-linux-gnu configurations are no longer supported.
* The obsolete function ustat is no longer available to newly linked
binaries; the headers <ustat.h> and <sys/ustat.h> have been removed. This
function has been deprecated in favor of fstatfs and statfs.
* The obsolete function nfsservctl is no longer available to newly linked
binaries. This function was specific to systems using the Linux kernel
and could not usefully be used with the GNU C Library on systems with
version 3.1 or later of the Linux kernel.
* The obsolete function name llseek is no longer available to newly linked
binaries. This function was specific to systems using the Linux kernel
and was not declared in a header. Programs should use the lseek64 name
for this function instead.
* The AI_IDN_ALLOW_UNASSIGNED and NI_IDN_ALLOW_UNASSIGNED flags for the
getaddrinfo and getnameinfo functions have been deprecated. The behavior
previously selected by them is now always enabled.
* The AI_IDN_USE_STD3_ASCII_RULES and NI_IDN_USE_STD3_ASCII_RULES flags for
the getaddrinfo and getnameinfo functions have been deprecated. The STD3
restriction (rejecting '_' in host names, among other things) has been
removed, for increased compatibility with non-IDN name resolution.
* The fcntl function now have a Long File Support variant named fcntl64. It
is added to fix some Linux Open File Description (OFD) locks usage on non
LFS mode. As for others *64 functions, fcntl64 semantics are analogous with
fcntl and LFS support is handled transparently. Also for Linux, the OFD
locks act as a cancellation entrypoint.
* The obsolete functions encrypt, encrypt_r, setkey, setkey_r, cbc_crypt,
ecb_crypt, and des_setparity are no longer available to newly linked
binaries, and the headers <rpc/des_crypt.h> and <rpc/rpc_des.h> are no
longer installed. These functions encrypted and decrypted data with the
DES block cipher, which is no longer considered secure. Software that
still uses these functions should switch to a modern cryptography library,
such as libgcrypt.
* Reflecting the removal of the encrypt and setkey functions above, the
macro _XOPEN_CRYPT is no longer defined. As a consequence, the crypt
function is no longer declared unless _DEFAULT_SOURCE or _GNU_SOURCE is
enabled.
* The obsolete function fcrypt is no longer available to newly linked
binaries. It was just another name for the standard function crypt,
and it has not appeared in any header file in many years.
* We have tentative plans to hand off maintenance of the passphrase-hashing
library, libcrypt, to a separate development project that will, we hope,
keep up better with new passphrase-hashing algorithms. We will continue
to declare 'crypt' in <unistd.h>, and programs that use 'crypt' or
'crypt_r' should not need to change at all; however, distributions will
need to install <crypt.h> and libcrypt from a separate project.
In this release, if the configure option --disable-crypt is used, glibc
will not install <crypt.h> or libcrypt, making room for the separate
project's versions of these files. The plan is to make this the default
behavior in a future release.
Changes to build and runtime requirements:
GNU make 4.0 or later is now required to build glibc.
Security related changes:
CVE-2016-6261, CVE-2016-6263, CVE-2017-14062: Various vulnerabilities have
been fixed by removing the glibc-internal IDNA implementation and using
the system-provided libidn2 library instead. Originally reported by Hanno
Böck and Christian Weisgerber.
CVE-2017-18269: An SSE2-based memmove implementation for the i386
architecture could corrupt memory. Reported by Max Horn.
CVE-2018-11236: Very long pathname arguments to realpath function could
result in an integer overflow and buffer overflow. Reported by Alexey
Izbyshev.
CVE-2018-11237: The mempcpy implementation for the Intel Xeon Phi
architecture could write beyond the target buffer, resulting in a buffer
overflow. Reported by Andreas Schwab.
The following bugs are resolved with this release:
[1190] stdio: fgetc()/fread() behaviour is not POSIX compliant
[6889] manual: 'PWD' mentioned but not specified
[13575] libc: SSIZE_MAX defined as LONG_MAX is inconsistent with ssize_t,
when __WORDSIZE != 64
[13762] regex: re_search etc. should return -2 on memory exhaustion
[13888] build: /tmp usage during testing
[13932] math: dbl-64 pow unexpectedly slow for some inputs
[14092] nptl: Support C11 threads
[14095] localedata: Review / update collation data from Unicode / ISO
14651
[14508] libc: -Wformat warnings
[14553] libc: Namespace pollution loff_t in sys/types.h
[14890] libc: Make NT_PRFPREG canonical.
[15105] libc: Extra PLT references with -Os
[15512] libc: __bswap_constant_16 not compiled when -Werror -Wsign-
conversion is given
[16335] manual: Feature test macro documentation incomplete and out of
date
[16552] libc: Unify umount implementations in terms of umount2
[17082] libc: htons et al.: statement-expressions prevent use on global
scope with -O1 and higher
[17343] libc: Signed integer overflow in /stdlib/random_r.c
[17438] localedata: pt_BR: wrong d_fmt delimiter
[17662] libc: please implement binding for the new renameat2 syscall
[17721] libc: __restrict defined as /* Ignore */ even in c11
[17979] libc: inconsistency between uchar.h and stdint.h
[18018] dynamic-link: Additional $ORIGIN handling issues (CVE-2011-0536)
[18023] libc: extend_alloca is broken (questionable pointer comparison,
horrible machine code)
[18124] libc: hppa: setcontext erroneously returns -1 as exit code for
last constant.
[18471] libc: llseek should be a compat symbol
[18473] soft-fp: [powerpc-nofpu] __sqrtsf2, __sqrtdf2 should be compat
symbols
[18991] nss: nss_files skips large entry in database
[19239] libc: Including stdlib.h ends up with macros major and minor being
defined
[19463] libc: linknamespace failures when compiled with -Os
[19485] localedata: csb_PL: Update month translations + add yesstr/nostr
[19527] locale: Normalized charset name not recognized by setlocale
[19667] string: Missing Sanity Check for malloc calls in file 'testcopy.c'
[19668] libc: Missing Sanity Check for malloc() in file 'tst-setcontext-
fpscr.c'
[19728] network: out of bounds stack read in libidn function
idna_to_ascii_4i (CVE-2016-6261)
[19729] network: out of bounds heap read on invalid utf-8 inputs in
stringprep_utf8_nfkc_normalize (CVE-2016-6263)
[19818] dynamic-link: Absolute (SHN_ABS) symbols incorrectly relocated by
the base address
[20079] libc: Add SHT_X86_64_UNWIND to elf.h
[20251] libc: 32bit programs pass garbage in struct flock for OFD locks
[20419] dynamic-link: files with large allocated notes crash in
open_verify
[20530] libc: bswap_16 should use __builtin_bswap16() when available
[20890] dynamic-link: ldconfig: fsync the files before atomic rename
[20980] manual: CFLAGS environment variable replaces vital options
[21163] regex: Assertion failure in pop_fail_stack when executing a
malformed regexp (CVE-2015-8985)
[21234] manual: use of CFLAGS makes glibc detect no optimization
[21269] dynamic-link: i386 sigaction sa_restorer handling is wrong
[21313] build: Compile Error GCC 5.4.0 MIPS with -0S
[21314] build: Compile Error GCC 5.2.0 MIPS with -0s
[21508] locale: intl/tst-gettext failure with latest msgfmt
[21547] localedata: Tibetan script collation broken (Dzongkha and Tibetan)
[21812] network: getifaddrs() returns entries with ifa_name == NULL
[21895] libc: ppc64 setjmp/longjmp not fully interoperable with static
dlopen
[21942] dynamic-link: _dl_dst_substitute incorrectly handles $ORIGIN: with
AT_SECURE=1
[22241] localedata: New locale: Yakut (Sakha) locale for Russia (sah_RU)
[22247] network: Integer overflow in the decode_digit function in
puny_decode.c in libidn (CVE-2017-14062)
[22342] nscd: NSCD not properly caching netgroup
[22391] nptl: Signal function clear NPTL internal symbols inconsistently
[22550] localedata: es_ES locale (and other es_* locales): collation
should treat ñ as a primary different character, sync the collation
for Spanish with CLDR
[22638] dynamic-link: sparc: static binaries are broken if glibc is built
by gcc configured with --enable-default-pie
[22639] time: year 2039 bug for localtime etc. on 64-bit platforms
[22644] string: memmove-sse2-unaligned on 32bit x86 produces garbage when
crossing 2GB threshold (CVE-2017-18269)
[22646] localedata: redundant data (LC_TIME) for es_CL, es_CU, es_EC and
es_BO
[22735] time: Misleading typo in time.h source comment regarding
CLOCKS_PER_SECOND
[22753] libc: preadv2/pwritev2 fallback code should handle offset=-1
[22761] libc: No trailing `%n' conversion specifier in FMT passed from
`__assert_perror_fail ()' to `__assert_fail_base ()'
[22766] libc: all glibc internal dlopen should use RTLD_NOW for robust
dlopen failures
[22786] libc: Stack buffer overflow in realpath() if input size is close
to SSIZE_MAX (CVE-2018-11236)
[22787] dynamic-link: _dl_check_caller returns false when libc is linked
through an absolute DT_NEEDED path
[22792] build: tcb-offsets.h dependency dropped
[22797] libc: pkey_get() uses non-reserved name of argument
[22807] libc: PTRACE_* constants missing for powerpc
[22818] glob: posix/tst-glob_lstat_compat failure on alpha
[22827] dynamic-link: RISC-V ELF64 parser mis-reads flag in ldconfig
[22830] malloc: malloc_stats doesn't restore cancellation state on stderr
[22848] localedata: ca_ES: update date definitions from CLDR
[22862] build: _DEFAULT_SOURCE is defined even when _ISOC11_SOURCE is
[22884] math: RISCV fmax/fmin handle signalling NANs incorrectly
[22896] localedata: Update locale data for an_ES
[22902] math: float128 test failures with GCC 8
[22918] libc: multiple common of `__nss_shadow_database'
[22919] libc: sparc32: backtrace yields infinite backtrace with
makecontext
[22926] libc: FTBFS on powerpcspe
[22932] localedata: lt_LT: Update of abbreviated month names from CLDR
required
[22937] localedata: Greek (el_GR, el_CY) locales actually need ab_alt_mon
[22947] libc: FAIL: misc/tst-preadvwritev2
[22963] localedata: cs_CZ: Add alternative month names
[22987] math: [powerpc/sparc] fdim inlines errno, exceptions handling
[22996] localedata: change LC_PAPER to en_US in es_BO locale
[22998] dynamic-link: execstack tests are disabled when SELinux is
disabled
[23005] network: Crash in __res_context_send after memory allocation
failure
[23007] math: strtod cannot handle -nan
[23024] nss: getlogin_r is performing NSS lookups when loginid isn't set
[23036] regex: regex equivalence class regression
[23037] libc: initialize msg_flags to zero for sendmmsg() calls
[23069] libc: sigaction broken on riscv64-linux-gnu
[23094] localedata: hr_HR: wrong thousands_sep and mon_thousands_sep
[23102] dynamic-link: Incorrect parsing of multiple consecutive $variable
patterns in runpath entries (e.g. $ORIGIN$ORIGIN)
[23137] nptl: s390: pthread_join sometimes block indefinitely (on 31bit
and libc build with -Os)
[23140] localedata: More languages need two forms of month names
[23145] libc: _init/_fini aren't marked as hidden
[23152] localedata: gd_GB: Fix typo in "May" (abbreviated)
[23171] math: C++ iseqsig for long double converts arguments to double
[23178] nscd: sudo will fail when it is run in concurrent with commands
that changes /etc/passwd
[23196] string: __mempcpy_avx512_no_vzeroupper mishandles large copies
(CVE-2018-11237)
[23206] dynamic-link: static-pie + dlopen breaks debugger interaction
[23208] localedata: New locale - Lower Sorbian (dsb)
[23233] regex: Memory leak in build_charclass_op function in file
posix/regcomp.c
[23236] stdio: Harden function pointers in _IO_str_fields
[23250] nptl: Offset of __private_ss differs from GCC
[23253] math: tgamma test suite failures on i686 with -march=x86-64
-mtune=generic -mfpmath=sse
[23259] dynamic-link: Unsubstituted ${ORIGIN} remains in DT_NEEDED for
AT_SECURE
[23264] libc: posix_spawnp wrongly executes ENOEXEC in non compat mode
[23266] nis: stringop-truncation warning with new gcc8.1 in nisplus-
parser.c
[23272] math: fma(INFINITY,INFIITY,0.0) should be INFINITY
[23277] math: nan function should not have const attribute
[23279] math: scanf and strtod wrong for some hex floating-point
[23280] math: wscanf rounds wrong; wcstod is ok for negative numbers and
directed rounding
[23290] localedata: IBM273 is not equivalent to ISO-8859-1
[23303] build: undefined reference to symbol
'__parse_hwcap_and_convert_at_platform@@GLIBC_2.23'
[23307] dynamic-link: Absolute symbols whose value is zero ignored in
lookup
[23313] stdio: libio vtables validation and standard file object
interposition
[23329] libc: The __libc_freeres infrastructure is not properly run across
DSO boundaries.
[23349] libc: Various glibc headers no longer compatible with
<linux/time.h>
[23351] malloc: Remove unused code related to heap dumps and malloc
checking
[23363] stdio: stdio-common/tst-printf.c has non-free license
[23396] regex: Regex equivalence regression in single-byte locales
[23422] localedata: oc_FR: More updates of locale data
[23442] build: New warning with GCC 8
[23448] libc: Out of bounds access in IBM-1390 converter
[23456] libc: Wrong index_cpu_LZCNT
[23458] build: tst-get-cpu-features-static isn't added to tests
[23459] libc: COMMON_CPUID_INDEX_80000001 isn't populated for Intel
processors
[23467] dynamic-link: x86/CET: A property note parser bug
Release Notes
=============
https://sourceware.org/glibc/wiki/Release/2.28
Contributors
============
This release was made possible by the contributions of many people.
The maintainers are grateful to everyone who has contributed
changes or bug reports. These include:
Adhemerval Zanella
Agustina Arzille
Alan Modra
Alexandre Oliva
Amit Pawar
Andreas Schwab
Andrew Senkevich
Andrew Waterman
Aurelien Jarno
Carlos O'Donell
Chung-Lin Tang
DJ Delorie
Daniel Alvarez
David Michael
Dmitry V. Levin
Dragan Stanojevic - Nevidljivi
Florian Weimer
Flávio Cruz
Francois Goichon
Gabriel F. T. Gomes
H.J. Lu
Herman ten Brugge
Hongbo Zhang
Igor Gnatenko
Jesse Hathaway
John David Anglin
Joseph Myers
Leonardo Sandoval
Maciej W. Rozycki
Mark Wielaard
Martin Sebor
Michael Wolf
Mike FABIAN
Patrick McGehearty
Patsy Franklin
Paul Pluzhnikov
Quentin PAGÈS
Rafal Luzynski
Rajalakshmi Srinivasaraghavan
Raymond Nicholson
Rical Jasan
Richard Braun
Robert Buj
Rogerio Alves
Samuel Thibault
Sean McKean
Siddhesh Poyarekar
Stefan Liebler
Steve Ellcey
Sylvain Lesage
Szabolcs Nagy
Thomas Schwinge
Tulio Magno Quites Machado Filho
Valery Timiriliyev
Vincent Chen
Wilco Dijkstra
Zack Weinberg
Zong Li
Diffstat (limited to 'conform/data')
65 files changed, 397 insertions, 265 deletions
diff --git a/conform/data/aio.h-data b/conform/data/aio.h-data index e87923ed70..adb291b6e1 100644 --- a/conform/data/aio.h-data +++ b/conform/data/aio.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined XPG42 type {struct aiocb} // Test elements of the AIO control struct. diff --git a/conform/data/arpa/inet.h-data b/conform/data/arpa/inet.h-data index 2bd3aeea0a..d4ab6bb72a 100644 --- a/conform/data/arpa/inet.h-data +++ b/conform/data/arpa/inet.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 // in_port_t should have exactly 16 bits type in_port_t // in_addr_t should have exactly 32 bits diff --git a/conform/data/complex.h-data b/conform/data/complex.h-data index 7de888f81b..4af7757bd7 100644 --- a/conform/data/complex.h-data +++ b/conform/data/complex.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 macro complex macro _Complex_I optional-macro imaginary diff --git a/conform/data/ctype.h-data b/conform/data/ctype.h-data index 3ee21c9b7d..7e10794e46 100644 --- a/conform/data/ctype.h-data +++ b/conform/data/ctype.h-data @@ -12,7 +12,7 @@ function int isxdigit (int) function int tolower (int) function int toupper (int) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int isblank (int) #endif diff --git a/conform/data/dlfcn.h-data b/conform/data/dlfcn.h-data index a954c9db46..b6658ae8ca 100644 --- a/conform/data/dlfcn.h-data +++ b/conform/data/dlfcn.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 macro RTLD_LAZY macro RTLD_NOW macro RTLD_GLOBAL diff --git a/conform/data/fcntl.h-data b/conform/data/fcntl.h-data index 1971d4a742..2d5827f6ec 100644 --- a/conform/data/fcntl.h-data +++ b/conform/data/fcntl.h-data @@ -7,7 +7,7 @@ constant F_SETFL constant F_GETLK constant F_SETLK constant F_SETLKW -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant F_GETOWN constant F_SETOWN #endif @@ -36,7 +36,7 @@ constant O_TRUNC constant O_APPEND constant O_NONBLOCK constant O_SYNC -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 constant O_DSYNC constant O_RSYNC #endif @@ -48,15 +48,6 @@ constant O_RDWR constant O_WRONLY #if !defined POSIX -constant S_IFMT -constant S_IFBLK -constant S_IFCHR -constant S_IFIFO -constant S_IFREG -constant S_IFDIR -constant S_IFLNK -constant S_IFSOCK - constant S_IRWXU constant S_IRUSR constant S_IWUSR @@ -87,8 +78,9 @@ constant POSIX_FADV_NOREUSE type {struct flock} -element {struct flock} short l_type -element {struct flock} short l_whence +// Bug 23081: l_type and l_whence members of flock structure have type int instead of short +xfail[i386-gnu]-element {struct flock} short l_type +xfail[i386-gnu]-element {struct flock} short l_whence element {struct flock} off_t l_start element {struct flock} off_t l_len element {struct flock} pid_t l_pid diff --git a/conform/data/fenv.h-data b/conform/data/fenv.h-data index bb33d4b06e..280b72864c 100644 --- a/conform/data/fenv.h-data +++ b/conform/data/fenv.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 type fenv_t type fexcept_t diff --git a/conform/data/float.h-data b/conform/data/float.h-data index 350802ac29..7b98fc0344 100644 --- a/conform/data/float.h-data +++ b/conform/data/float.h-data @@ -38,7 +38,7 @@ macro-constant FLT_MIN <= 1.0E-37 macro-constant DBL_MIN <= 1.0E-37 macro-constant LDBL_MIN <= 1.0E-37 -#if !defined ISO && !defined XPG3 && !defined XPG4 && !defined POSIX && !defined UNIX98 +#if !defined ISO && !defined XPG4 && !defined XPG42 && !defined POSIX && !defined UNIX98 macro-int-constant DECIMAL_DIG >= 10 macro-int-constant FLT_EVAL_METHOD #endif diff --git a/conform/data/fmtmsg.h-data b/conform/data/fmtmsg.h-data index e64d87ce40..c1b18ad4a4 100644 --- a/conform/data/fmtmsg.h-data +++ b/conform/data/fmtmsg.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 macro MM_HARD constant MM_HARD diff --git a/conform/data/ftw.h-data b/conform/data/ftw.h-data index 0fa586a6fc..340334bfd4 100644 --- a/conform/data/ftw.h-data +++ b/conform/data/ftw.h-data @@ -1,13 +1,19 @@ #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +# ifndef XPG4 type {struct FTW} element {struct FTW} int base element {struct FTW} int level +# endif macro FTW_F macro FTW_D macro FTW_DNR +# if !defined XPG4 && !defined XPG42 macro FTW_DP +# endif macro FTW_NS + +# ifndef XPG4 macro FTW_SL macro FTW_SLN @@ -15,9 +21,12 @@ macro FTW_PHYS macro FTW_MOUNT macro FTW_DEPTH macro FTW_CHDIR +# endif function int ftw (const char*, int (*) (const char *, const struct stat*, int), int) +# ifndef XPG4 function int nftw (const char*, int (*) (const char *, const struct stat*, int, struct FTW *), int, int) +# endif allow-header sys/stat.h diff --git a/conform/data/grp.h-data b/conform/data/grp.h-data index 53e880d418..1688444586 100644 --- a/conform/data/grp.h-data +++ b/conform/data/grp.h-data @@ -19,7 +19,7 @@ function {struct group*} getgrgid (gid_t) function {struct group*} getgrnam (const char*) 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**) -# if !defined XPG3 && !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function {struct group*} getgrent (void) function void endgrent (void) function void setgrent (void) diff --git a/conform/data/inttypes.h-data b/conform/data/inttypes.h-data index 8c076dff88..2ae5b951be 100644 --- a/conform/data/inttypes.h-data +++ b/conform/data/inttypes.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 #include "stdint.h-data" type imaxdiv_t diff --git a/conform/data/iso646.h-data b/conform/data/iso646.h-data index d4afaa5795..9e307f734d 100644 --- a/conform/data/iso646.h-data +++ b/conform/data/iso646.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 macro and macro and_eq macro bitand diff --git a/conform/data/langinfo.h-data b/conform/data/langinfo.h-data index 51dd925a8a..6bbb3872a0 100644 --- a/conform/data/langinfo.h-data +++ b/conform/data/langinfo.h-data @@ -55,6 +55,11 @@ constant YESEXPR constant NOEXPR constant CRNCYSTR +# if defined XPG4 || defined XPG42 || defined UNIX98 +constant YESSTR +constant NOSTR +# endif + type nl_item # if defined XOPEN2K8 || defined POSIX2008 type locale_t diff --git a/conform/data/libgen.h-data b/conform/data/libgen.h-data index 443cd0bd22..e9eb5fafc9 100644 --- a/conform/data/libgen.h-data +++ b/conform/data/libgen.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 function {char*} basename (char*) function {char*} dirname (char*) diff --git a/conform/data/limits.h-data b/conform/data/limits.h-data index 726db1e632..23114a5fa0 100644 --- a/conform/data/limits.h-data +++ b/conform/data/limits.h-data @@ -32,12 +32,12 @@ allow AIO_LISTIO_MAX allow AIO_MAX allow AIO_PRIO_DELTA_MAX allow ARG_MAX -#if !defined POSIX && !defined XPG3 +#if !defined POSIX && !defined XPG4 allow ATEXIT_MAX #endif allow CHILD_MAX allow DELAYTIMER_MAX -#if !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined POSIX && !defined POSIX2008 && !defined XPG4 allow IOV_MAX #endif allow LOGIN_NAME_MAX @@ -56,18 +56,18 @@ allow RTSIG_MAX allow SEM_NSEMS_MAX allow SEM_VALUE_MAX allow SIGQUEUE_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 allow SS_REPL_MAX #endif allow STREAM_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 allow SYMLOOP_MAX #endif allow TIMER_MAX allow TTY_NAME_MAX allow TZNAME_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined XPG4 && !defined XPG42 allow FILESIZEBITS #endif allow LINK_MAX @@ -76,7 +76,7 @@ allow MAX_INPUT allow NAME_MAX allow PATH_MAX allow PIPE_BUF -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 allow POSIX_ALLOC_SIZE_MIN allow POSIX_REC_INCR_XFER_SIZE allow POSIX_REC_MAX_XFER_SIZE @@ -88,7 +88,7 @@ macro-constant BC_BASE_MAX >= _POSIX2_BC_BASE_MAX macro-constant BC_DIM_MAX >= _POSIX2_BC_DIM_MAX macro-constant BC_SCALE_MAX >= _POSIX2_BC_SCALE_MAX macro-constant BC_STRING_MAX >= _POSIX2_BC_STRING_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined XPG4 && !defined XPG42 macro CHARCLASS_NAME_MAX #endif macro-constant COLL_WEIGHTS_MAX >= _POSIX2_COLL_WEIGHTS_MAX @@ -102,7 +102,7 @@ constant _POSIX_CLOCKRES_MIN == 20000000 constant _POSIX_AIO_LISTIO_MAX == 2 constant _POSIX_AIO_MAX == 1 constant _POSIX_ARG_MAX == 4096 -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant _POSIX_CHILD_MAX == 25 #else constant _POSIX_CHILD_MAX == 6 @@ -115,12 +115,12 @@ constant _POSIX_MAX_INPUT == 255 constant _POSIX_MQ_OPEN_MAX == 8 constant _POSIX_MQ_PRIO_MAX == 32 constant _POSIX_NAME_MAX == 14 -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant _POSIX_NGROUPS_MAX == 8 #else constant _POSIX_NGROUPS_MAX == 0 #endif -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant _POSIX_OPEN_MAX == 20 #else constant _POSIX_OPEN_MAX == 16 @@ -134,7 +134,7 @@ constant _POSIX_SEM_VALUE_MAX == 32767 constant _POSIX_SIGQUEUE_MAX == 32 constant _POSIX_SSIZE_MAX == 32767 constant _POSIX_STREAM_MAX == 8 -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 optional-constant _POSIX_SS_REPL_MAX == 4 optional-constant _POSIX_SYMLINK_MAX == 255 optional-constant _POSIX_SYMLOOP_MAX == 8 @@ -144,7 +144,7 @@ constant _POSIX_THREAD_KEYS_MAX == 128 constant _POSIX_THREAD_THREADS_MAX == 64 constant _POSIX_TIMER_MAX == 32 constant _POSIX_TTY_NAME_MAX == 9 -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant _POSIX_TZNAME_MAX == 6 #else constant _POSIX_TZNAME_MAX == 3 @@ -153,14 +153,14 @@ macro-constant _POSIX2_BC_BASE_MAX == 99 macro-constant _POSIX2_BC_DIM_MAX == 2048 macro-constant _POSIX2_BC_SCALE_MAX == 99 macro-constant _POSIX2_BC_STRING_MAX == 1000 -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant _POSIX2_CHARCLASS_NAME_MAX == 14 #endif macro-constant _POSIX2_COLL_WEIGHTS_MAX == 2 macro-constant _POSIX2_EXPR_NEST_MAX == 32 macro-constant _POSIX2_LINE_MAX == 2048 macro-constant _POSIX2_RE_DUP_MAX == 255 -#if !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined POSIX && !defined POSIX2008 && !defined XPG4 optional-constant _XOPEN_IOV_MAX == 16 #endif @@ -170,10 +170,10 @@ constant LONG_BIT >= 32 #endif constant SSIZE_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined POSIX optional-constant CHARCLASS_NAME_MAX >= 14 #endif -#if !defined POSIX && !defined XPG3 +#if !defined POSIX optional-constant NL_ARGMAX >= 9 # if !defined POSIX2008 optional-constant NL_LANGMAX >= 14 @@ -188,12 +188,12 @@ optional-constant NL_TEXTMAX optional-constant NZERO >= 20 # endif #endif -#if defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 optional-constant TMP_MAX >= 10000 #endif allow *_MAX -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 allow *_MIN #endif allow *_t diff --git a/conform/data/locale.h-data b/conform/data/locale.h-data index adcd25f656..266264ac6d 100644 --- a/conform/data/locale.h-data +++ b/conform/data/locale.h-data @@ -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 -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 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 diff --git a/conform/data/math.h-data b/conform/data/math.h-data index 71533339ce..0c50755792 100644 --- a/conform/data/math.h-data +++ b/conform/data/math.h-data @@ -1,7 +1,7 @@ macro-constant HUGE_VAL {double} #if !defined ISO && !defined POSIX -# if !defined XPG3 && !defined XPG4 && !defined UNIX98 +# if !defined XPG4 && !defined XPG42 && !defined UNIX98 macro fpclassify macro isfinite macro isinf @@ -17,7 +17,7 @@ macro isunordered type float_t type double_t # endif -# if defined XPG3 || defined XPG4 || defined UNIX98 +# if defined XPG4 || defined XPG42 || defined UNIX98 function int isnan (double) # endif @@ -38,7 +38,7 @@ constant M_SQRT1_2 constant MAXFLOAT # endif -# if !defined XPG3 && !defined XPG4 && !defined UNIX98 +# if !defined XPG4 && !defined XPG42 && !defined UNIX98 macro-constant HUGE_VALF {float} macro-constant HUGE_VALL {long double} macro-constant INFINITY {float} @@ -69,13 +69,13 @@ function double asin (double) function double atan (double) function double atan2 (double, double) function double ceil (double) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function double copysign (double, double) #endif function double cos (double) function double cosh (double) function double exp (double) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function double exp2 (double) #endif function double fabs (double) @@ -85,7 +85,7 @@ function double frexp (double, int*) function double ldexp (double, int) function double log (double) function double log10 (double) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function double log2 (double) #endif function double modf (double, double*) @@ -99,7 +99,7 @@ function double tanh (double) function double erf (double) function double erfc (double) #endif -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function double gamma (double) #endif #if !defined ISO && !defined POSIX @@ -110,7 +110,7 @@ function double j1 (double) function double jn (int, double) # endif function double lgamma (double) -# if !defined XPG3 && !defined XPG4 && !defined UNIX98 +# if !defined XPG4 && !defined XPG42 && !defined UNIX98 function double tgamma (double) # endif # if !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 @@ -118,7 +118,7 @@ function double y0 (double) function double y1 (double) function double yn (int, double) # endif -# if !defined XPG3 +# if !defined XPG4 function double acosh (double) function double asinh (double) function double atanh (double) @@ -128,13 +128,13 @@ function int ilogb (double) function double log1p (double) function double logb (double) function double nextafter (double, double) -# if !defined XPG4 && !defined UNIX98 +# if !defined XPG42 && !defined UNIX98 function double nexttoward (double, long double) function double nearbyint (double) # endif function double remainder (double, double) function double rint (double) -# if !defined XPG4 && !defined UNIX98 +# if !defined XPG42 && !defined UNIX98 function double round (double) function double trunc (double) function long lrint (double) @@ -143,10 +143,10 @@ function long lround (double) function {long long} llround (double) function double remquo (double, double, int*) # endif -# if defined XPG4 || defined UNIX98 || defined XOPEN2K +# if defined XPG42 || defined UNIX98 || defined XOPEN2K function double scalb (double, double) # endif -# if !defined XPG4 && !defined UNIX98 +# if !defined XPG42 && !defined UNIX98 function double scalbn (double, int) function double scalbln (double, long) function double fdim (double, double) @@ -163,7 +163,7 @@ allow signgam # endif #endif -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function float acosf (float) function float asinf (float) function float atanf (float) @@ -330,6 +330,6 @@ allow tanhl #if !defined ISO && !defined ISO99 && !defined ISO11 allow *_t #endif -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 allow FP_[ABCDEFGHIJKLMNOPQRSTUVWXYZ]* #endif diff --git a/conform/data/mqueue.h-data b/conform/data/mqueue.h-data index 76652ce661..42ccd8551e 100644 --- a/conform/data/mqueue.h-data +++ b/conform/data/mqueue.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined XPG42 // should test for not an array type. type mqd_t @@ -10,10 +10,11 @@ element {struct sigevent} {void(*} sigev_notify_function )(union sigval) element {struct sigevent} {pthread_attr_t*} sigev_notify_attributes type {struct mq_attr} -element {struct mq_attr} long mq_flags -element {struct mq_attr} long mq_maxmsg -element {struct mq_attr} long mq_msgsize -element {struct mq_attr} long mq_curmsgs +// Bug 21279: mq_attr elements have wrong type. +xfail[x86_64-x32-linux]-element {struct mq_attr} long mq_flags +xfail[x86_64-x32-linux]-element {struct mq_attr} long mq_maxmsg +xfail[x86_64-x32-linux]-element {struct mq_attr} long mq_msgsize +xfail[x86_64-x32-linux]-element {struct mq_attr} long mq_curmsgs function int mq_close (mqd_t) function int mq_getattr (mqd_t, struct mq_attr*) diff --git a/conform/data/ndbm.h-data b/conform/data/ndbm.h-data index 43c6a38d79..2ee7a59253 100644 --- a/conform/data/ndbm.h-data +++ b/conform/data/ndbm.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 type datum element datum {void*} dptr element datum size_t dsize diff --git a/conform/data/net/if.h-data b/conform/data/net/if.h-data index fd8509567f..8a4d89c067 100644 --- a/conform/data/net/if.h-data +++ b/conform/data/net/if.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 type {struct if_nameindex} element {struct if_nameindex} {unsigned int} if_index diff --git a/conform/data/netdb.h-data b/conform/data/netdb.h-data index 63a42ae179..c6d8b70a0d 100644 --- a/conform/data/netdb.h-data +++ b/conform/data/netdb.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 optional-type in_port_t optional-type in_addr_t @@ -15,7 +15,8 @@ type {struct netent} element {struct netent} {char*} n_name element {struct netent} {char**} n_aliases element {struct netent} int n_addrtype -element {struct netent} uint32_t n_net +// Bug 21260: n_net has wrong type. +xfail[alpha-linux]-element {struct netent} uint32_t n_net type uint32_t @@ -44,7 +45,7 @@ macro NO_RECOVERY macro TRY_AGAIN #endif -#if !defined XPG4 && !defined UNIX98 +#if !defined XPG42 && !defined UNIX98 type {struct addrinfo} element {struct addrinfo} int ai_flags element {struct addrinfo} int ai_family @@ -85,7 +86,7 @@ function void endhostent (void) function void endnetent (void) function void endprotoent (void) function void endservent (void) -#if !defined XPG4 && !defined UNIX98 +#if !defined XPG42 && !defined UNIX98 function void freeaddrinfo (struct addrinfo*) function {const char*} gai_strerror (int) function int getaddrinfo (const char*, const char*, const struct addrinfo*, struct addrinfo**) @@ -93,7 +94,7 @@ function int getaddrinfo (const char*, const char*, const struct addrinfo*, stru function {struct hostent*} gethostbyaddr (const void*, socklen_t, int) function {struct hostent*} gethostbyname (const char*) function {struct hostent*} gethostent (void) -#if !defined XPG4 && !defined UNIX98 +#if !defined XPG42 && !defined UNIX98 function int getnameinfo (const struct sockaddr*, socklen_t, char*, socklen_t, char*, socklen_t, int) #endif function {struct netent*} getnetbyaddr (uint32_t, int) diff --git a/conform/data/netinet/in.h-data b/conform/data/netinet/in.h-data index 928432651b..ccc74db608 100644 --- a/conform/data/netinet/in.h-data +++ b/conform/data/netinet/in.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type in_port_t type in_addr_t @@ -92,4 +92,6 @@ allow IPV6_* allow IPPORT_* allow IPPROTO_* allow SOCK_* +allow sin_* +allow sin6_* #endif diff --git a/conform/data/poll.h-data b/conform/data/poll.h-data index 84777dffa1..f7ebb91715 100644 --- a/conform/data/poll.h-data +++ b/conform/data/poll.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type {struct pollfd} element {struct pollfd} int fd element {struct pollfd} {short int} events diff --git a/conform/data/pthread.h-data b/conform/data/pthread.h-data index c1e32c8d01..6b10499458 100644 --- a/conform/data/pthread.h-data +++ b/conform/data/pthread.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined XPG42 constant PTHREAD_CANCEL_ASYNCHRONOUS constant PTHREAD_CANCEL_ENABLE constant PTHREAD_CANCEL_DEFERRED diff --git a/conform/data/pwd.h-data b/conform/data/pwd.h-data index 64d617fdcf..e86433d6a7 100644 --- a/conform/data/pwd.h-data +++ b/conform/data/pwd.h-data @@ -23,7 +23,7 @@ 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**) -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function void endpwent (void) function {struct passwd*} getpwent (void) function void setpwent (void) diff --git a/conform/data/sched.h-data b/conform/data/sched.h-data index 610406d96b..63e5eb2567 100644 --- a/conform/data/sched.h-data +++ b/conform/data/sched.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined XPG42 # if defined POSIX || defined UNIX98 # include "time.h-data" # else diff --git a/conform/data/search.h-data b/conform/data/search.h-data index 3abbc6690f..e99f7e6c1d 100644 --- a/conform/data/search.h-data +++ b/conform/data/search.h-data @@ -17,10 +17,14 @@ constant leaf function int hcreate (size_t) function void hdestroy (void) function {ENTRY*} hsearch (ENTRY, ACTION) +#ifndef XPG4 function void insque (void*, void*) +#endif function {void*} lfind (const void*, const void*, size_t*, size_t, int (*)(const void*, const void*)) function {void*} lsearch (const void*, void*, size_t*, size_t, int (*)(const void*, const void*)) +#ifndef XPG4 function void remque (void*) +#endif function {void*} tdelete (const void*, void**, int(*)(const void*, const void*)) function {void*} tfind (const void*, void*const*, int(*)(const void*, const void*)) function {void*} tsearch (const void*, void**, int(*)(const void*, const void*)) diff --git a/conform/data/semaphore.h-data b/conform/data/semaphore.h-data index 8c3497baa6..066c2f721b 100644 --- a/conform/data/semaphore.h-data +++ b/conform/data/semaphore.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined XPG42 type sem_t constant SEM_FAILED @@ -20,7 +20,9 @@ allow-header fcntl.h # if !defined POSIX2008 && !defined XOPEN2K8 allow-header sys/types.h # endif -# if !defined POSIX && !defined UNIX98 && !defined XOPEN2K +// Consider addition of this permission in POSIX.1:2008 as a bug fix, +// so allow for POSIX.1:2001 as well since that includes sem_timedwait. +# if !defined POSIX && !defined UNIX98 allow-header time.h # endif diff --git a/conform/data/signal.h-data b/conform/data/signal.h-data index 7584865f12..11e54adb04 100644 --- a/conform/data/signal.h-data +++ b/conform/data/signal.h-data @@ -24,16 +24,19 @@ type mcontext_t type ucontext_t element ucontext_t {ucontext_t*} uc_link -element ucontext_t sigset_t uc_sigmask +// Bug 21634: uc_sigmask has wrong type. +xfail[ia64-linux]-element ucontext_t sigset_t uc_sigmask element ucontext_t stack_t uc_stack -element ucontext_t mcontext_t uc_mcontext +// Bug 21635: uc_mcontext has wrong type. +xfail[powerpc32-linux]-element ucontext_t mcontext_t uc_mcontext type {struct timespec} element {struct timespec} __time_t tv_sec -element {struct timespec} long tv_nsec +// Bug 16437: tv_nsec has wrong type. +xfail[x86_64-x32-linux]-element {struct timespec} long tv_nsec #endif -#if defined POSIX || defined UNIX98 || defined XOPEN2K8 || defined POSIX2008 +#if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 element {union sigval} int sival_int element {union sigval} {void*} sival_ptr @@ -80,18 +83,18 @@ macro-int-constant SIGSTOP {int} > 0 macro-int-constant SIGTSTP {int} > 0 macro-int-constant SIGTTIN {int} > 0 macro-int-constant SIGTTOU {int} > 0 -# ifndef XPG3 +# ifndef XPG4 macro-int-constant SIGBUS {int} > 0 # endif -# if !defined POSIX && !defined XPG3 +# if !defined POSIX && !defined XPG4 macro-int-constant SIGPOLL {int} > 0 macro-int-constant SIGPROF {int} > 0 macro-int-constant SIGSYS {int} > 0 # endif -# if !defined POSIX && !defined XPG3 && !defined POSIX2008 +# if !defined POSIX && !defined XPG4 && !defined POSIX2008 macro-int-constant SIGTRAP {int} > 0 # endif -# if !defined POSIX && !defined XPG3 +# if !defined POSIX && !defined XPG4 macro-int-constant SIGURG {int} > 0 macro-int-constant SIGVTALRM {int} > 0 macro-int-constant SIGXCPU {int} > 0 @@ -103,36 +106,44 @@ type {struct sigaction} element {struct sigaction} {void(*} sa_handler )(int) element {struct sigaction} sigset_t sa_mask element {struct sigaction} int sa_flags +# ifndef XPG4 element {struct sigaction} {void(*} sa_sigaction )(int, siginfo_t*, void*) +# endif constant SA_NOCLDSTOP -constant SA_SIGINFO +# ifndef XPG4 +// Bug 23089: hurd: missing siginfo support. +xfail[i386-gnu]-constant SA_SIGINFO +# endif constant SIG_BLOCK constant SIG_UNBLOCK constant SIG_SETMASK -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 constant SA_ONSTACK # endif -# if !defined POSIX +# if !defined XPG4 && !defined POSIX constant SA_RESETHAND constant SA_RESTART -constant SA_NOCLDWAIT +// Bug 23090: hurd: missing SA_NOCLDWAIT support. +xfail[i386-gnu]-constant SA_NOCLDWAIT constant SA_NODEFER # endif -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 constant SS_ONSTACK constant SS_DISABLE constant MINSIGSTKSZ constant SIGSTKSZ # endif -# if !defined POSIX +# if !defined XPG4 && !defined POSIX type ucontext_t element ucontext_t {ucontext_t*} uc_link -element ucontext_t sigset_t uc_sigmask +// Bug 21634: uc_sigmask has wrong type. +xfail[ia64-linux]-element ucontext_t sigset_t uc_sigmask element ucontext_t stack_t uc_stack -element ucontext_t mcontext_t uc_mcontext +// Bug 21635: uc_mcontext has wrong type. +xfail[powerpc32-linux]-element ucontext_t mcontext_t uc_mcontext type stack_t @@ -140,13 +151,15 @@ element stack_t {void*} ss_sp element stack_t size_t ss_size element stack_t int ss_flags +# if !defined XOPEN2K8 && !defined POSIX2008 type {struct sigstack} element {struct sigstack} int ss_onstack element {struct sigstack} {void*} ss_sp +# endif # endif -# ifndef XPG3 +# ifndef XPG4 type siginfo_t element siginfo_t int si_signo @@ -161,12 +174,12 @@ element siginfo_t {void*} si_addr element siginfo_t int si_status element siginfo_t long si_band # endif -# ifndef XPG4 +# ifndef XPG42 element siginfo_t {union sigval} si_value # endif # endif -# if !defined POSIX && !defined XPG3 +# if !defined POSIX && !defined XPG4 constant ILL_ILLOPC constant ILL_ILLOPN constant ILL_ILLADR @@ -201,62 +214,64 @@ constant POLL_ERR constant POLL_PRI constant POLL_HUP # endif -# if !defined POSIX && !defined XPG3 && !defined POSIX2008 +# if !defined POSIX && !defined XPG4 && !defined POSIX2008 constant TRAP_BRKPT constant TRAP_TRACE # endif +# if !defined XPG4 && !defined XPG42 constant SI_USER constant SI_QUEUE constant SI_TIMER constant SI_ASYNCIO constant SI_MESGQ +# endif -# if !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008 function void (*bsd_signal (int, void(*)(int)))(int) # endif function int kill (pid_t, int) -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function int killpg (pid_t, int) # endif -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 function int pthread_kill (pthread_t, int) function int pthread_sigmask (int, const sigset_t*, sigset_t*) # endif function int sigaction (int, const struct sigaction*, struct sigaction*) function int sigaddset (sigset_t*, int) -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !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 +# if !defined XPG4 && !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) -#if !defined POSIX && !defined POSIX2008 +#if !defined XPG4 && !defined POSIX && !defined POSIX2008 function int sigpause (int) # endif function int sigpending (sigset_t*) function int sigprocmask (int, const sigset_t*, sigset_t*) -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 function int sigqueue (pid_t, int, const union sigval) # endif -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function int sigrelse (int) function void (*sigset (int, void(*)(int)))(int) # endif -# if !defined POSIX +# if defined XPG42 || defined UNIX98 function int sigstack (struct sigstack*, struct sigstack*) # endif function int sigsuspend (const sigset_t*) -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 function int sigtimedwait (const sigset_t*, siginfo_t*, const struct timespec*) # endif +# if !defined XPG4 && !defined XPG42 function int sigwait (const sigset_t*, int*) -# if !defined XPG3 && !defined XPG4 function int sigwaitinfo (const sigset_t*, siginfo_t*) # endif # if defined XOPEN2K8 || defined POSIX2008 @@ -268,19 +283,19 @@ function void psignal (int, const char*) // poorfnmatch implementation doesn't grok the right form. allow sa_* allow SA_* -# ifndef XPG3 +# ifndef XPG4 allow si_* allow SI_* # endif -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 allow sigev_* allow SIGEV_* allow sival_* # endif -# if !defined POSIX && !defined XPG3 && !defined XPG4 +# if !defined POSIX && !defined XPG4 && !defined XPG42 allow uc_* # endif -# if !defined POSIX && !defined XPG3 +# if !defined POSIX && !defined XPG4 allow BUS_* allow CLD_* allow FPE_* @@ -288,7 +303,7 @@ allow ILL_* allow POLL_* allow SEGV_* # endif -# if !defined POSIX && !defined XPG3 && !defined POSIX2008 +# if !defined POSIX && !defined XPG4 && !defined POSIX2008 allow SS_* allow SV_* allow TRAP_* diff --git a/conform/data/spawn.h-data b/conform/data/spawn.h-data index fb206f7ecf..de4aaa7fe2 100644 --- a/conform/data/spawn.h-data +++ b/conform/data/spawn.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 type posix_spawnattr_t type posix_spawn_file_actions_t # if defined XOPEN2K8 || defined POSIX2008 diff --git a/conform/data/stdarg.h-data b/conform/data/stdarg.h-data index 2c87a3b56d..53addb91fa 100644 --- a/conform/data/stdarg.h-data +++ b/conform/data/stdarg.h-data @@ -5,7 +5,7 @@ macro va_start macro va_arg macro va_end -#if defined ISO99 || defined ISO11 || defined POSIX2008 || defined XOPEN2K8 +#if defined ISO99 || defined ISO11 || defined XOPEN2K || defined POSIX2008 || defined XOPEN2K8 macro va_copy #endif diff --git a/conform/data/stdbool.h-data b/conform/data/stdbool.h-data index 9ef218c5e2..a030e9cffe 100644 --- a/conform/data/stdbool.h-data +++ b/conform/data/stdbool.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 macro bool macro-int-constant true {int} == 1 macro-int-constant false {int} == 0 diff --git a/conform/data/stdint.h-data b/conform/data/stdint.h-data index f6689513cc..4e84e17fb8 100644 --- a/conform/data/stdint.h-data +++ b/conform/data/stdint.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 // The requirements for some types and corresponding macros are from POSIX. type int8_t type int16_t diff --git a/conform/data/stdio.h-data b/conform/data/stdio.h-data index 9089180a10..3ef2460661 100644 --- a/conform/data/stdio.h-data +++ b/conform/data/stdio.h-data @@ -41,7 +41,7 @@ type fpos_t #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX type va_list #else -#define va_list _G_va_list +#define va_list __gnuc_va_list #endif type size_t #if defined XOPEN2K8 || defined POSIX2008 @@ -52,7 +52,7 @@ type ssize_t function void clearerr (FILE*) #if !defined ISO && !defined ISO99 && !defined ISO11 function {char*} ctermid (char*) -# if defined XPG3 || defined XPG4 || defined UNIX98 +# if defined XPG4 || defined XPG42 || defined UNIX98 function {char*} cuserid (char*) # endif #endif @@ -60,7 +60,7 @@ function {char*} cuserid (char*) function int dprintf (int, const char*, ...) #endif function int fclose (FILE*) -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined ISO11 function {FILE*} fdopen (int, const char*) #endif function int feof (FILE*) @@ -72,7 +72,7 @@ function {char*} fgets (char*, int, FILE*) #if !defined ISO && !defined ISO99 && !defined ISO11 function int fileno (FILE*) #endif -#if defined POSIX || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function void flockfile (FILE*) #endif #if defined XOPEN2K8 || defined POSIX2008 @@ -86,22 +86,22 @@ function size_t fread (void*, size_t, size_t, FILE*) function {FILE*} freopen (const char*, const char*, FILE*) function int fscanf (FILE*, const char*, ...) function int fseek (FILE*, long int, int) -#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function int fseeko (FILE*, off_t, int) #endif function int fsetpos (FILE*, const fpos_t*) function {long int} ftell (FILE*) -#if defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function off_t ftello (FILE*) #endif -#if defined POSIX || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function int ftrylockfile (FILE*) function void funlockfile (FILE*) #endif function size_t fwrite (const void*, size_t, size_t, FILE*) function int getc (FILE*) function int getchar (void) -#if defined POSIX || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function int getc_unlocked (FILE*) function int getchar_unlocked (void) #endif @@ -109,13 +109,13 @@ function int getchar_unlocked (void) function ssize_t getdelim (char**, size_t*, int, FILE*) function ssize_t getline (char**, size_t*, FILE*) #endif -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function int getopt (int, char *const[], const char *) #endif #if !defined ISO11 function {char*} gets (char*) #endif -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function int getw (FILE*) #endif #if defined XOPEN2K8 || defined POSIX2008 @@ -131,12 +131,12 @@ function {FILE*} popen (const char*, const char*) function int printf (const char*, ...) function int putc (int, FILE*) function int putchar (int) -#if defined POSIX || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 +#if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function int putc_unlocked (int, FILE*) function int putchar_unlocked (int) #endif function int puts (const char*) -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function int putw (int, FILE*) #endif function int remove (const char*) @@ -148,12 +148,12 @@ function void rewind (FILE*) function int scanf (const char*, ...) function void setbuf (FILE*, char*) function int setvbuf (FILE*, char*, int, size_t) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 function int snprintf (char*, size_t, const char*, ...) #endif function int sprintf (char *, const char *, ...) function int sscanf (const char*, const char*, ...) -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 +#if defined XPG4 || defined XPG42 || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 function {char*} tempnam (const char*, const char*) #endif function {FILE*} tmpfile (void) @@ -163,18 +163,18 @@ function int ungetc (int, FILE*) function int vdprintf (int, const char*, va_list) #endif function int vfprintf (FILE*, const char*, va_list) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int vfscanf (FILE*, const char*, va_list) #endif function int vprintf (const char*, va_list) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int vscanf (const char*, va_list) #endif -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 function int vsnprintf (char*, size_t, const char*, va_list) #endif function int vsprintf (char*, const char*, va_list) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int vsscanf (const char*, const char*, va_list) #endif diff --git a/conform/data/stdlib.h-data b/conform/data/stdlib.h-data index abe296a2ab..6913828196 100644 --- a/conform/data/stdlib.h-data +++ b/conform/data/stdlib.h-data @@ -32,10 +32,10 @@ macro WSTOPSIG macro WTERMSIG #endif -#if !defined ISO && !defined XPG3 && !defined XPG4 && !defined UNIX98 && !defined POSIX +#if !defined ISO && !defined XPG4 && !defined XPG42 && !defined UNIX98 && !defined POSIX function void _Exit (int) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function long a64l (const char*) #endif function void abort (void) @@ -50,7 +50,7 @@ function int at_quick_exit (void (*) (void)) function double atof (const char*) function int atoi (const char*) function {long int} atol (const char*) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function {long long} atoll (const char*) #endif function {void*} bsearch (const void*, const void*, size_t, size_t, int(*)(const void*, const void*)) @@ -59,28 +59,32 @@ function div_t div (int, int) #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function double drand48 (void) #endif -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function {char*} ecvt (double, int, int*, int*) #endif #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function double erand48 (unsigned short int[3]) #endif function void exit (int) -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function {char*} fcvt (double, int, int*, int*) #endif function void free (void*) -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function {char*} gcvt (double, int, char*) #endif function {char*} getenv (const char*) -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX function int getsubopt (char**, char *const*, char**) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function int grantpt (int) function {char*} initstate (unsigned int, char*, size_t) +#endif +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function {long int} jrand48 (unsigned short int[3]) +#endif +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {char*} l64a (long) #endif function {long int} labs (long int) @@ -88,7 +92,7 @@ function {long int} labs (long int) function void lcong48 (unsigned short int[7]) #endif function ldiv_t ldiv (long int, long int) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function {long long} llabs (long long) function lldiv_t lldiv (long long, long long) #endif @@ -102,10 +106,10 @@ function int mbtowc (wchar_t*, const char*, size_t) #if defined XOPEN2K8 || defined POSIX2008 function {char*} mkdtemp (char*) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XOPEN2K8 && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined XOPEN2K8 && !defined POSIX2008 function {char*} mktemp (char*) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX function int mkstemp (char*) #endif #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 @@ -118,8 +122,10 @@ function int posix_memalign (void**, size_t, size_t) #if defined XOPEN2K || defined XOPEN2K8 function int posix_openpt (int) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {char*} ptsname (int) +#endif +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function int putenv (char*) #endif function void qsort (void*, size_t, size_t, int(*)(const void*, const void*)) @@ -130,48 +136,51 @@ function int rand (void) #if defined POSIX || defined UNIX98 || defined XOPEN2K || defined XOPEN2K8 || defined POSIX2008 function int rand_r (unsigned int*) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function long random (void) #endif function {void*} realloc (void*, size_t) -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {char*} realpath (const char*, char*) +#endif +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function {unsigned short int*} seed48 (unsigned short int[3]) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int setenv (const char*, const char*, int) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 -function void setkey (const char*) +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {char*} setstate (char*) #endif function void srand (unsigned int) #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 function void srand48 (long int) +#endif +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function void srandom (unsigned) #endif function double strtod (const char*, char**) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function float strtof (const char*, char**) function {long double} strtold (const char*, char**) #endif function {long int} strtol (const char*, char**, int) function {unsigned long int} strtoul (const char*, char**, int) -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function {long long int} strtoll (const char*, char**, int) function {unsigned long long int} strtoull (const char*, char**, int) #endif function int system (const char*) -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG42 || defined UNIX98 function int ttyslot (void) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function int unlockpt (int) #endif -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int unsetenv (const char*) #endif -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG42 || defined UNIX98 function {void*} valloc (size_t) #endif function size_t wcstombs (char*, const wchar_t*, size_t) diff --git a/conform/data/string.h-data b/conform/data/string.h-data index cc3b1c9732..e06f941498 100644 --- a/conform/data/string.h-data +++ b/conform/data/string.h-data @@ -27,7 +27,7 @@ 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*) -#if !defined ISO && !defined ISO99 & !defined ISO11 && !defined POSIX && !defined POSIX2008 +#if !defined ISO && !defined ISO99 & !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {char*} strdup (const char*) #endif function {char*} strerror (int) diff --git a/conform/data/strings.h-data b/conform/data/strings.h-data index d22609a0f8..13827ebed9 100644 --- a/conform/data/strings.h-data +++ b/conform/data/strings.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 # if !defined XOPEN2K8 && !defined POSIX2008 function int bcmp (const void*, const void*, size_t) function void bcopy (const void*, void*, size_t) diff --git a/conform/data/stropts.h-data b/conform/data/stropts.h-data index e43dac8c9e..c4b1343411 100644 --- a/conform/data/stropts.h-data +++ b/conform/data/stropts.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type {struct bandinfo} element {struct bandinfo} {unsigned char} bi_pri diff --git a/conform/data/sys/ipc.h-data b/conform/data/sys/ipc.h-data index 70dc3f6fe6..09e8f68f8e 100644 --- a/conform/data/sys/ipc.h-data +++ b/conform/data/sys/ipc.h-data @@ -1,10 +1,11 @@ #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 type {struct ipc_perm} -element {struct ipc_perm} uid_t uid -element {struct ipc_perm} gid_t gid -element {struct ipc_perm} uid_t cuid -element {struct ipc_perm} gid_t cgid +// Bug 23082: uid/gid/cuid/cgid/mode have type unsigned short instead of uid_t and mode_t. +xfail[i386-gnu]-element {struct ipc_perm} uid_t uid +xfail[i386-gnu]-element {struct ipc_perm} gid_t gid +xfail[i386-gnu]-element {struct ipc_perm} uid_t cuid +xfail[i386-gnu]-element {struct ipc_perm} gid_t cgid // Bug 18231: wrong type for mode member. xfail-element {struct ipc_perm} mode_t mode diff --git a/conform/data/sys/mman.h-data b/conform/data/sys/mman.h-data index 3a88684bc5..a74388338e 100644 --- a/conform/data/sys/mman.h-data +++ b/conform/data/sys/mman.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 constant PROT_READ constant PROT_WRITE constant PROT_EXEC @@ -17,7 +17,7 @@ constant MCL_FUTURE constant MAP_FAILED -# if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +# if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 constant POSIX_MADV_NORMAL constant POSIX_MADV_SEQUENTIAL constant POSIX_MADV_RANDOM diff --git a/conform/data/sys/msg.h-data b/conform/data/sys/msg.h-data index a8290cab52..f5e9f1c82a 100644 --- a/conform/data/sys/msg.h-data +++ b/conform/data/sys/msg.h-data @@ -9,8 +9,9 @@ constant MSG_NOERROR element {struct msqid_ds} {struct ipc_perm} msg_perm element {struct msqid_ds} msgqnum_t msg_qnum element {struct msqid_ds} msglen_t msg_qbytes -element {struct msqid_ds} pid_t msg_lspid -element {struct msqid_ds} pid_t msg_lrpid +// Bug 23083: msg_lspid/msg_lrpid have type unsigned short instead of pid_t. +xfail[i386-gnu]-element {struct msqid_ds} pid_t msg_lspid +xfail[i386-gnu]-element {struct msqid_ds} pid_t msg_lrpid element {struct msqid_ds} time_t msg_stime element {struct msqid_ds} time_t msg_rtime element {struct msqid_ds} time_t msg_ctime diff --git a/conform/data/sys/resource.h-data b/conform/data/sys/resource.h-data index 5c46dea301..cedbee1a40 100644 --- a/conform/data/sys/resource.h-data +++ b/conform/data/sys/resource.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 constant PRIO_PROCESS constant PRIO_PGRP constant PRIO_USER diff --git a/conform/data/sys/select.h-data b/conform/data/sys/select.h-data index d414ec4624..44d63ebd2d 100644 --- a/conform/data/sys/select.h-data +++ b/conform/data/sys/select.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 type time_t type suseconds_t @@ -10,10 +10,11 @@ type sigset_t type {struct timespec} element {struct timespec} time_t tv_sec -element {struct timespec} long tv_nsec +// Bug 16437: tv_nsec has wrong type. +xfail[x86_64-x32-linux]-element {struct timespec} long tv_nsec type fd_set -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 element fd_set long fds_bits [] #endif diff --git a/conform/data/sys/shm.h-data b/conform/data/sys/shm.h-data index a006cdbb92..778b194f50 100644 --- a/conform/data/sys/shm.h-data +++ b/conform/data/sys/shm.h-data @@ -9,8 +9,9 @@ type {struct shmid_ds} element {struct shmid_ds} {struct ipc_perm} shm_perm element {struct shmid_ds} size_t shm_segsz -element {struct shmid_ds} pid_t shm_lpid -element {struct shmid_ds} pid_t shm_cpid +// Bug 23085: shm_lpid/shm_cpid have type unsigned short instead of pid_t +xfail[i386-gnu]-element {struct shmid_ds} pid_t shm_lpid +xfail[i386-gnu]-element {struct shmid_ds} pid_t shm_cpid element {struct shmid_ds} shmatt_t shm_nattch element {struct shmid_ds} time_t shm_atime element {struct shmid_ds} time_t shm_dtime diff --git a/conform/data/sys/socket.h-data b/conform/data/sys/socket.h-data index 442d4d288a..8796c57570 100644 --- a/conform/data/sys/socket.h-data +++ b/conform/data/sys/socket.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type socklen_t type sa_family_t @@ -113,7 +113,7 @@ function int setsockopt (int, int, int, const void*, socklen_t) function int shutdown (int, int) function int socket (int, int, int) function int socketpair (int, int, int, int[2]) -#if !defined XPG4 && !defined UNIX98 +#if !defined XPG42 && !defined UNIX98 function int sockatmark (int) #endif @@ -136,4 +136,5 @@ allow MSG_* allow PF_* allow SCM_* allow SHUT_* +allow *_t #endif diff --git a/conform/data/sys/stat.h-data b/conform/data/sys/stat.h-data index f5b17a31ac..03be4814ec 100644 --- a/conform/data/sys/stat.h-data +++ b/conform/data/sys/stat.h-data @@ -1,6 +1,6 @@ #if !defined ISO && !defined ISO99 && !defined ISO11 -#if !defined POSIX && !defined POSIX2008 && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined POSIX2008 && !defined XPG4 && !defined XPG42 type blkcnt_t type blksize_t #endif @@ -26,14 +26,17 @@ type time_t type {struct stat} -element {struct stat} dev_t st_dev +// Bug 17786: st_dev has wrong type. +// Bug 23084: st_dev has type unsigned long long instead of dev_t (unsigned). +xfail[mips-o32-linux|i386-gnu]-element {struct stat} dev_t st_dev element {struct stat} ino_t st_ino 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 +// Bug 21278: st_rdev has wrong type. +xfail[mips-o32-linux]-element {struct stat} dev_t st_rdev #endif element {struct stat} off_t st_size element {struct stat} time_t st_atime @@ -44,15 +47,24 @@ element {struct stat} {struct timespec} st_atim element {struct stat} {struct timespec} st_mtim element {struct stat} {struct timespec} st_ctim #endif -#if !defined POSIX && !defined POSIX2008 +#if !defined XPG4 && !defined POSIX && !defined POSIX2008 +# ifdef XPG42 +// The XPG42 use of "long" for these fields is not compatible with the +// use of typedefs in future standards to support values outside the +// range of "long". +xfail-element {struct stat} long st_blksize +xfail-element {struct stat} long st_blocks +# else element {struct stat} blksize_t st_blksize element {struct stat} blkcnt_t st_blocks +# endif #endif # if defined XOPEN2K8 || defined POSIX2008 type {struct timespec} element {struct timespec} time_t tv_sec -element {struct timespec} long tv_nsec +// Bug 16437: tv_nsec has wrong type. +xfail[x86_64-x32-linux]-element {struct timespec} long tv_nsec # endif #if !defined POSIX && !defined POSIX2008 @@ -62,8 +74,10 @@ constant S_IFCHR constant S_IFIFO constant S_IFREG constant S_IFDIR +# ifndef XPG4 constant S_IFLNK constant S_IFSOCK +# endif #endif constant S_IRWXU @@ -80,7 +94,7 @@ constant S_IWOTH constant S_IXOTH constant S_ISUID constant S_ISGID -#if !defined POSIX && !defined POSIX2008 +#if !defined XPG4 && !defined POSIX && !defined POSIX2008 constant S_ISVTX #endif @@ -89,7 +103,7 @@ macro S_ISCHR macro S_ISDIR macro S_ISFIFO macro S_ISREG -#if !defined POSIX +#if !defined XPG4 && !defined POSIX macro S_ISLNK macro S_ISSOCK #endif @@ -98,7 +112,7 @@ macro S_ISSOCK optional-macro S_TYPEISMQ optional-macro S_TYPEISSEM optional-macro S_TYPEISSHM -# if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +# if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 optional-macro S_TYPEISTMO # endif @@ -108,7 +122,9 @@ constant UTIME_OMIT # endif function int chmod (const char*, mode_t) +# ifndef XPG4 function int fchmod (int, mode_t) +# endif # if defined XOPEN2K8 || defined POSIX2008 function int fchmodat (int, const char*, mode_t, int) # endif @@ -117,7 +133,7 @@ function int fstat (int, struct stat*) function int fstatat (int, const char*, struct stat*, int) function int futimens (int, const struct timespec[2]) # endif -#if !defined POSIX +#if !defined XPG4 && !defined POSIX function int lstat (const char*, struct stat*) #endif function int mkdir (const char*, mode_t) @@ -128,7 +144,7 @@ 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 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function int mknod (const char*, mode_t, dev_t) # endif # ifdef XOPEN2K8 diff --git a/conform/data/sys/statvfs.h-data b/conform/data/sys/statvfs.h-data index fa56fbeee1..2a74813e3d 100644 --- a/conform/data/sys/statvfs.h-data +++ b/conform/data/sys/statvfs.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type {struct statvfs} element {struct statvfs} {unsigned long} f_bsize @@ -9,7 +9,8 @@ element {struct statvfs} fsblkcnt_t f_bavail element {struct statvfs} fsfilcnt_t f_files element {struct statvfs} fsfilcnt_t f_ffree element {struct statvfs} fsfilcnt_t f_favail -element {struct statvfs} {unsigned long} f_fsid +// Bug 23086: f_fsid has type unsigned long long instead of unsigned long +xfail[i386-gnu]-element {struct statvfs} {unsigned long} f_fsid element {struct statvfs} {unsigned long} f_flag element {struct statvfs} {unsigned long} f_namemax diff --git a/conform/data/sys/time.h-data b/conform/data/sys/time.h-data index 1d07bd6380..30523e1af4 100644 --- a/conform/data/sys/time.h-data +++ b/conform/data/sys/time.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 type {struct timeval} element {struct timeval} time_t tv_sec diff --git a/conform/data/sys/timeb.h-data b/conform/data/sys/timeb.h-data index 08ae3c0932..9638f73c8f 100644 --- a/conform/data/sys/timeb.h-data +++ b/conform/data/sys/timeb.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined POSIX2008 && !defined XOPEN2K8 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined POSIX2008 && !defined XOPEN2K8 type {struct timeb} element {struct timeb} time_t time diff --git a/conform/data/sys/types.h-data b/conform/data/sys/types.h-data index 36c5efac63..cc28eb76d4 100644 --- a/conform/data/sys/types.h-data +++ b/conform/data/sys/types.h-data @@ -1,9 +1,13 @@ #if !defined ISO && !defined ISO99 && !defined ISO11 #if !defined POSIX +# if !defined XPG4 && !defined XPG42 type blkcnt_t type blksize_t +# endif type clock_t +# if !defined XPG4 && !defined XPG42 type clockid_t +# endif #endif type dev_t # if !defined POSIX @@ -22,7 +26,7 @@ type mode_t type nlink_t type off_t type pid_t -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 type pthread_attr_t #if !defined POSIX && !defined UNIX98 type pthread_barrier_t diff --git a/conform/data/sys/uio.h-data b/conform/data/sys/uio.h-data index 06cea074cd..b9fc66177c 100644 --- a/conform/data/sys/uio.h-data +++ b/conform/data/sys/uio.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined POSIX2008 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined POSIX2008 type {struct iovec} element {struct iovec} {void*} iov_base diff --git a/conform/data/sys/un.h-data b/conform/data/sys/un.h-data index 3bf7968683..08bf9bcfd7 100644 --- a/conform/data/sys/un.h-data +++ b/conform/data/sys/un.h-data @@ -1,8 +1,10 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 type {struct sockaddr_un} element {struct sockaddr_un} sa_family_t sun_family element {struct sockaddr_un} char sun_path [] type sa_family_t + +allow sun_* #endif diff --git a/conform/data/sys/wait.h-data b/conform/data/sys/wait.h-data index e0787e3b5d..ed3869b34f 100644 --- a/conform/data/sys/wait.h-data +++ b/conform/data/sys/wait.h-data @@ -7,8 +7,9 @@ constant WNOHANG constant WUNTRACED macro WEXITSTATUS -# if !defined POSIX && !defined POSIX2008 -macro WIFCONTINUED +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 +// Bug 23091: hurd: missing waitid support. +xfail[i386-gnu]-macro WIFCONTINUED # endif macro WIFEXITED macro WIFSIGNALED @@ -16,17 +17,18 @@ macro WIFSTOPPED macro WSTOPSIG macro WTERMSIG -# ifndef POSIX -constant WEXITED -constant WSTOPPED +// Bug 23091: hurd: missing waitid support. +# if !defined XPG4 && !defined POSIX +xfail[i386-gnu]-constant WEXITED +xfail[i386-gnu]-constant WSTOPPED # ifndef POSIX2008 -constant WCONTINUED +xfail[i386-gnu]-constant WCONTINUED # endif constant WNOHANG -constant WNOWAIT +xfail[i386-gnu]-constant WNOWAIT # endif -#if !defined POSIX +#if !defined XPG4 && !defined POSIX type idtype_t constant P_ALL @@ -45,10 +47,12 @@ element siginfo_t uid_t si_uid element siginfo_t {void*} si_addr element siginfo_t int si_status element siginfo_t long si_band +# ifndef XPG42 element siginfo_t {union sigval} si_value +# endif #endif -#if !defined POSIX && !defined XPG3 && !defined XOPEN2K8 && !defined POSIX2008 +#if !defined POSIX && !defined XPG4 && !defined XOPEN2K8 && !defined POSIX2008 type {struct rusage} element {struct rusage} {struct timeval} ru_utime @@ -60,15 +64,15 @@ type pid_t #endif function pid_t wait (int*) -#if !defined POSIX && !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008 +#if !defined XPG4 && !defined POSIX && !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008 function pid_t wait3 (int*, int, struct rusage*) #endif -#if !defined POSIX +#if !defined XPG4 && !defined POSIX function int waitid (idtype_t, id_t, siginfo_t*, int) #endif function pid_t waitpid (pid_t, int*, int) -#if !defined POSIX +#if !defined XPG4 && !defined POSIX allow-header signal.h allow-header sys/resource.h diff --git a/conform/data/syslog.h-data b/conform/data/syslog.h-data index 05619cf489..6604d76d3e 100644 --- a/conform/data/syslog.h-data +++ b/conform/data/syslog.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 constant LOG_PID constant LOG_CONS constant LOG_NDELAY diff --git a/conform/data/termios.h-data b/conform/data/termios.h-data index de34bf5956..9aec2f5a17 100644 --- a/conform/data/termios.h-data +++ b/conform/data/termios.h-data @@ -144,7 +144,7 @@ function int tcdrain (int) function int tcflow (int, int) function int tcflush (int, int) function int tcgetattr (int, struct termios*) -#ifndef POSIX +#if !defined POSIX && !defined XPG4 function pid_t tcgetsid (int) #endif function int tcsendbreak (int, int) diff --git a/conform/data/tgmath.h-data b/conform/data/tgmath.h-data index 5f72502191..d852adc3e4 100644 --- a/conform/data/tgmath.h-data +++ b/conform/data/tgmath.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 #include "math.h-data" #include "complex.h-data" diff --git a/conform/data/threads.h-data b/conform/data/threads.h-data new file mode 100644 index 0000000000..406e497726 --- /dev/null +++ b/conform/data/threads.h-data @@ -0,0 +1,57 @@ +#if defined ISO11 + +macro ONCE_FLAG_INIT +macro thread_local +macro-int-constant TSS_DTOR_ITERATIONS + +constant thrd_success +constant thrd_busy +constant thrd_error +constant thrd_nomem +constant thrd_timedout + +constant mtx_plain +constant mtx_recursive +constant mtx_timed + +type thrd_t +type thrd_start_t +type mtx_t +type once_flag +type cnd_t +type tss_t +type tss_dtor_t + +function int thrd_create (thrd_t*, thrd_start_t, void*) +function int thrd_equal (thrd_t, thrd_t) +function thrd_t thrd_current (void) +function int thrd_sleep (const struct timespec*, struct timespec*) +function void thrd_exit (int) +function int thrd_detach (thrd_t) +function int thrd_join (thrd_t, int*) +function void thrd_yield (void) + +function int mtx_init (mtx_t*, int) +function int mtx_lock (mtx_t*) +function int mtx_timedlock (mtx_t*, const struct timespec*) +function int mtx_trylock (mtx_t*) +function int mtx_unlock (mtx_t*) +function void mtx_destroy (mtx_t*) + +function void call_once (once_flag*, void (*)(void)) + +function int cnd_init (cnd_t*) +function int cnd_signal (cnd_t*) +function int cnd_broadcast (cnd_t*) +function int cnd_wait (cnd_t*, mtx_t*) +function int cnd_timedwait (cnd_t*, mtx_t*, const struct timespec*) +function void cnd_destroy (cnd_t*) + +function int tss_create (tss_t*, tss_dtor_t) +function {void*} tss_get (tss_t) +function int tss_set (tss_t, void*) +function void tss_delete (tss_t) + +#include "time.h-data" + +#endif diff --git a/conform/data/time.h-data b/conform/data/time.h-data index ddd9a074c8..9c1c19596e 100644 --- a/conform/data/time.h-data +++ b/conform/data/time.h-data @@ -5,11 +5,12 @@ macro CLOCKS_PER_SEC {clock_t} macro-int-constant TIME_UTC > 0 #endif -#if !defined ISO && !defined ISO99 && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined ISO99 && !defined XPG4 && !defined XPG42 type {struct timespec} element {struct timespec} time_t tv_sec -element {struct timespec} long tv_nsec +// Bug 16437: tv_nsec has wrong type. +xfail[x86_64-x32-linux]-element {struct timespec} long tv_nsec #endif type size_t @@ -45,7 +46,7 @@ function int timespec_get (struct timespec *, int) # if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008 symbol CLK_TCK # endif -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 # if !defined POSIX && !defined UNIX98 constant CLOCK_PROCESS_CPUTIME_ID constant CLOCK_THREAD_CPUTIME_ID @@ -72,31 +73,31 @@ type locale_t tag {struct sigevent} # endif -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 variable int getdate_err # endif function {char*} asctime_r (const struct tm*, char*) -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int clock_getcpuclockid (pid_t, clockid_t*) #endif -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 function int clock_getres (clockid_t, struct timespec*) function int clock_gettime (clockid_t, struct timespec*) #endif -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int clock_nanosleep (clockid_t, int, const struct timespec*, struct timespec*) #endif -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 function int clock_settime (clockid_t, const struct timespec*) #endif function {char*} ctime_r (const time_t*, char*) -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function {struct tm*} getdate (const char*) # endif function {struct tm*} gmtime_r (const time_t*, struct tm*) function {struct tm*} localtime_r (const time_t*, struct tm*) -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 function int nanosleep (const struct timespec*, struct timespec*) # endif # if defined XOPEN2K8 || defined POSIX2008 @@ -105,7 +106,7 @@ function size_t strftime_l (char*, size_t, const char*, const struct tm*, locale # if !defined POSIX && !defined POSIX2008 function {char*} strptime (const char*, const char*, struct tm*) # endif -# if !defined XPG3 && !defined XPG4 +# if !defined XPG4 && !defined XPG42 function int timer_create (clockid_t, struct sigevent*, timer_t*) function int timer_delete (timer_t) function int timer_gettime (timer_t, struct itimerspec*) diff --git a/conform/data/ucontext.h-data b/conform/data/ucontext.h-data index dc2f4cb0da..a840f464fc 100644 --- a/conform/data/ucontext.h-data +++ b/conform/data/ucontext.h-data @@ -1,12 +1,14 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG3 && !defined POSIX2008 && !defined XOPEN2K8 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined POSIX2008 && !defined XOPEN2K8 type mcontext_t type ucontext_t element ucontext_t {ucontext_t*} uc_link -element ucontext_t sigset_t uc_sigmask +// Bug 21634: uc_sigmask has wrong type. +xfail[ia64-linux]-element ucontext_t sigset_t uc_sigmask element ucontext_t stack_t uc_stack -element ucontext_t mcontext_t uc_mcontext +// Bug 21635: uc_mcontext has wrong type. +xfail[powerpc32-linux]-element ucontext_t mcontext_t uc_mcontext type sigset_t type stack_t diff --git a/conform/data/unistd.h-data b/conform/data/unistd.h-data index 9c00d44551..aa070528e8 100644 --- a/conform/data/unistd.h-data +++ b/conform/data/unistd.h-data @@ -7,7 +7,7 @@ #endif constant _POSIX_VERSION -#if defined POSIX || defined XPG3 || defined XPG4 || defined UNIX98 +#if defined POSIX || defined XPG4 || defined XPG42 || defined UNIX98 constant _POSIX2_C_VERSION #endif #ifndef POSIX @@ -375,7 +375,7 @@ constant _SC_THREAD_ROBUST_PRIO_INHERIT constant _SC_THREAD_ROBUST_PRIO_PROTECT #endif -#if !defined POSIX && !defined POSIX2008 +#if !defined XPG4 && !defined POSIX && !defined POSIX2008 constant F_LOCK constant F_ULOCK constant F_TEST @@ -417,28 +417,27 @@ type off_t type pid_t #endif -#if !defined POSIX +#if !defined POSIX && !defined XPG4 type useconds_t +# ifndef XPG42 type intptr_t +# endif #endif function int access (const char*, int) function {unsigned int} alarm (unsigned int) -#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008 +#if !defined XOPEN2K && !defined XOPEN2K8 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function int brk (void*) #endif function int chdir (const char*) -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function int chroot (const char*) #endif 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 -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 function {char*} ctermid (char*) function {char*} cuserid (char*) #endif @@ -447,9 +446,6 @@ allow cuserid #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*, ...) @@ -460,16 +456,16 @@ function void _exit (int) # if defined XOPEN2K8 || defined POSIX2008 function int faccessat (int, const char*, int, int) # endif -#if !defined POSIX +#if !defined XPG4 && !defined POSIX function int fchown (int, uid_t, gid_t) #endif # if defined XOPEN2K8 || defined POSIX2008 function int fchownat (int, const char*, uid_t, gid_t, int) # endif -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function int fchdir (int) #endif -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 function int fdatasync (int) #endif # if defined XOPEN2K8 || defined POSIX2008 @@ -478,52 +474,56 @@ function int fexecve (int, char *const[], char *const[]) function pid_t fork (void) function {long int} fpathconf (int, int) function int fsync (int) +#ifndef XPG4 function int ftruncate (int, off_t) +#endif function {char*} getcwd (char*, size_t) -#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008 +#if !defined XOPEN2K && !defined XOPEN2K8 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function int getdtablesize (void) #endif 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 +#if !defined XPG4 && !defined POSIX && !defined POSIX2008 function long gethostid (void) #endif -#if !defined POSIX +#if !defined POSIX && !defined XPG4 function int gethostname (char*, size_t) #endif function {char*} getlogin (void) -#if !defined XPG3 && !defined XPG4 +#if !defined XPG4 && !defined XPG42 function int getlogin_r (char*, size_t) #endif function int getopt (int, char*const[], const char*) -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG42 || defined UNIX98 function int getpagesize (void) +#endif +#if defined XPG4 || defined XPG42 || defined UNIX98 function {char*} getpass (const char*) #endif -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function pid_t getpgid (pid_t) #endif function pid_t getpgrp (void) function pid_t getpid (void) function pid_t getppid (void) -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function pid_t getsid (pid_t) #endif function uid_t getuid (void) -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function {char*} getwd (char*) #endif function int isatty (int) -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function int lchown (const char*, uid_t, gid_t) #endif 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 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function int lockf (int, int, off_t) # endif function off_t lseek (int, off_t, int) @@ -533,33 +533,33 @@ function int nice (int) function {long int} pathconf (const char*, int) function int pause (void) function int pipe (int[2]) -#if !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined XPG4 && !defined XPG42 function ssize_t pread (int, void*, size_t, off_t) #endif -#if !defined POSIX && !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008 && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008 && !defined XPG4 && !defined XPG42 function int pthread_atfork (void(*)(void), void(*)(void), void(*)(void)) #endif -#if !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined POSIX && !defined XPG4 && !defined XPG42 function ssize_t pwrite (int, const void*, size_t, off_t) #endif function ssize_t read (int, void*, size_t) -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function ssize_t readlink (const char*, char*, size_t) #endif # if defined XOPEN2K8 || defined POSIX2008 function ssize_t readlinkat (int, const char*, char*, size_t) # endif function int rmdir (const char*) -#if !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX && !defined POSIX2008 +#if !defined XOPEN2K && !defined XOPEN2K8 && !defined XPG4 && !defined POSIX && !defined POSIX2008 function {void*} sbrk (intptr_t) #endif -#if !defined POSIX && !defined XPG3 && !defined XPG4 && !defined UNIX98 +#if !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98 function int setegid (gid_t) function int seteuid (uid_t) #endif function int setgid (gid_t) function int setpgid (pid_t, pid_t) -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !defined POSIX && !defined POSIX2008 function pid_t setpgrp (void) function int setregid (gid_t, gid_t) function int setreuid (uid_t, uid_t) @@ -570,31 +570,31 @@ function {unsigned int} sleep (unsigned int) # if !defined POSIX && !defined POSIX2008 function void swab (const void*, void*, ssize_t) # endif -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function int symlink (const char*, const char*) # endif # if defined XOPEN2K8 || defined POSIX2008 function int symlinkat (const char*, int, const char*) # endif -# if !defined POSIX && !defined POSIX2008 +# if !defined XPG4 && !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) -#ifndef POSIX +#if !defined XPG4 && !defined POSIX function int truncate (const char*, off_t) #endif function {char*} ttyname (int) function int ttyname_r (int, char*, size_t) -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function useconds_t ualarm (useconds_t, useconds_t) #endif function int unlink (const char*) # if defined XOPEN2K8 || defined POSIX2008 function int unlinkat (int, const char*, int) # endif -#if defined XPG3 || defined XPG4 || defined UNIX98 || defined XOPEN2K +#if defined XPG42 || defined UNIX98 || defined XOPEN2K function int usleep (useconds_t) function pid_t vfork (void) #endif diff --git a/conform/data/utmpx.h-data b/conform/data/utmpx.h-data index 80641ff8f0..cfe2a08634 100644 --- a/conform/data/utmpx.h-data +++ b/conform/data/utmpx.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG3 +#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008 && !defined XPG4 type {struct utmpx} element {struct utmpx} char ut_user [] diff --git a/conform/data/varargs.h-data b/conform/data/varargs.h-data index 48435fe387..2366edb1fa 100644 --- a/conform/data/varargs.h-data +++ b/conform/data/varargs.h-data @@ -1,4 +1,4 @@ -#if defined XPG3 || defined XPG4 || defined UNIX98 +#if defined XPG4 || defined XPG42 || defined UNIX98 macro va_alist macro va_dcl type va_list diff --git a/conform/data/wchar.h-data b/conform/data/wchar.h-data index c65ec404c8..0beae8957d 100644 --- a/conform/data/wchar.h-data +++ b/conform/data/wchar.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 type wchar_t type wint_t # if !defined ISO99 && !defined ISO11 && !defined POSIX2008 diff --git a/conform/data/wctype.h-data b/conform/data/wctype.h-data index 91638e61dc..944fe6efab 100644 --- a/conform/data/wctype.h-data +++ b/conform/data/wctype.h-data @@ -1,4 +1,4 @@ -#if !defined ISO && !defined POSIX && !defined XPG3 && !defined XPG4 +#if !defined ISO && !defined POSIX && !defined XPG4 && !defined XPG42 type wint_t type wctrans_t type wctype_t |