about summary refs log tree commit diff
path: root/misc
Commit message (Collapse)AuthorAgeFilesLines
* Fix incorrect mount table entry parsing in __getmntent_rVladimir A. Nazarenko2015-01-062-2/+26
| | | | | | | | | When mount entry contains only four fields and have more then one space or tab at the and, mp.mnt_freq and mp.mnt_passno will be set to some specific values as side effect from parsing of previus mount entry. It is because sscanf(""," %d %d ", &a, &b) returns -1, but this case is unprocessed. Values of mp.mnt_freq and mp.mnt_passno stays unchanged. This patch is attempt to fix described issue by removing trailing tabs and spaces.
* Update copyright dates with scripts/update-copyrights.Joseph Myers2015-01-02138-138/+138
|
* Fix warning in misc/tst-mntent2.c.Torvald Riegel2014-12-161-1/+1
|
* Suppress -Wformat-security in tst-error1.c.Roland McGrath2014-12-111-0/+11
|
* De-warning a few stubs.Roland McGrath2014-12-042-21/+30
|
* Fix fgets_unlocked namespace issues (bug 17664).Joseph Myers2014-12-021-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Various POSIX functions bring in res_init.o, res_hconf.o or mntent_r.o, which use fgets_unlocked, which is not a POSIX function. This patch arranges for them to use __fgets_unlocked instead. (The IS_IN (libc) conditional in rec_hconf.c is needed because that file is also used in nscd.) Tested for x86_64 (testsuite, and that disassembly of installed shared libraries is unchanged by the patch except for an assertion line number). Note that most of the linknamespace tests that failed because of fgets_unlocked from the resolver also fail because of other symbols brought in by the resolver, so the number of XFAILs this removes is limited. Also note that fgets_unlocked failures for unistd.h for XPG3/XPG4 showed up that actually unistd.h is declaring too much for XPG3/XPG4 (bug 17665) - there is no actual need to make getusershell.c use __fgets_unlocked (at least as regards formal standards are concerned; maybe it should still change for namespace-cleanness of _DEFAULT_SOURCE) because the functions there aren't actually in any of the supported standards; the correct fix for those failures will be to stop the *usershell* functions appearing in unistd.h for XPG3/XPG4. [BZ #17664] * misc/mntent_r.c (__getmntent_r): Use __fgets_unlocked instead of fgets_unlocked. * resolv/res_hconf.c [IS_IN (libc)] (fgets_unlocked): Define to __fgets_unlocked. * resolv/res_init.c (__res_vinit): Use __fgets_unlocked instead of fgets_unlocked. * conform/Makefile (test-xfail-XPG4/sys/statvfs.h/linknamespace): Remove variable. (test-xfail-POSIX/sys/mman.h/linknamespace): Likewise. (test-xfail-UNIX98/sys/mman.h/linknamespace): Likewise. (test-xfail-UNIX98/sys/statvfs.h/linknamespace): Likewise. (test-xfail-XOPEN2K/sys/mman.h/linknamespace): Likewise. (test-xfail-XOPEN2K/sys/statvfs.h/linknamespace): Likewise. (test-xfail-POSIX2008/sys/mman.h/linknamespace): Likewise. (test-xfail-POSIX2008/sys/statvfs.h/linknamespace): Likewise. (test-xfail-XOPEN2K8/sys/mman.h/linknamespace): Likewise. (test-xfail-XOPEN2K8/sys/statvfs.h/linknamespace): Likewise.
* Avoid deprecated sigblock in misc/tst-pselect.c.Joseph Myers2014-11-271-2/+5
| | | | | | | | | | | | | | misc/tst-pselect.c uses the deprecated sigblock interface, resulting in "tst-pselect.c:42:3: warning: 'sigblock' is deprecated (declared at ../signal/signal.h:189) [-Wdeprecated-declarations]". The choice of sigblock rather than sigprocmask has nothing to do with what this test is testing, so this patch changes it to use sigprocmask to avoid the warning. Tested for x86_64. * misc/tst-pselect.c (do_test): Use sigprocmask instead of sigblock.
* Modify several tests to use test-skeleton.cArjun Shankar2014-11-055-10/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch modifies several test cases to use test-skeleton.c. It was generated by a bash script written for this purpose and thus excludes several other tests which I deemed worth a visual inspection before making the change. I intend to follow up with individual patches to the tests skipped by the script. The script itself resides at http://git.io/WODAmg and should reproduce this very patch when run against master. ChangeLog: 2014-10-30 Arjun Shankar <arjun.is@lostca.se> * catgets/test-gencat.c: Use test-skeleton.c. * catgets/tst-catgets.c: Likewise. * csu/tst-empty.c: Likewise. * elf/tst-audit2.c: Likewise. * elf/tst-global1.c: Likewise. * elf/tst-pathopt.c: Likewise. * elf/tst-piemod1.c: Likewise. * elf/tst-tls10.c: Likewise. * elf/tst-tls11.c: Likewise. * elf/tst-tls12.c: Likewise. * gnulib/tst-gcc.c: Likewise. * iconvdata/tst-e2big.c: Likewise. * iconvdata/tst-loading.c: Likewise. * iconv/tst-iconv1.c: Likewise. * iconv/tst-iconv2.c: Likewise. * inet/test-inet6_opt.c: Likewise. * inet/tst-gethnm.c: Likewise. * inet/tst-network.c: Likewise. * inet/tst-ntoa.c: Likewise. * intl/tst-codeset.c: Likewise. * intl/tst-gettext2.c: Likewise. * intl/tst-gettext3.c: Likewise. * intl/tst-ngettext.c: Likewise. * intl/tst-translit.c: Likewise. * io/test-stat.c: Likewise. * libio/test-fmemopen.c: Likewise. * libio/tst-freopen.c: Likewise. * libio/tst-sscanf.c: Likewise. * libio/tst-ungetwc1.c: Likewise. * libio/tst-ungetwc2.c: Likewise. * libio/tst-widetext.c: Likewise. * localedata/tst-ctype.c: Likewise. * localedata/tst-digits.c: Likewise. * localedata/tst-leaks.c: Likewise. * localedata/tst-mbswcs1.c: Likewise. * localedata/tst-mbswcs2.c: Likewise. * localedata/tst-mbswcs3.c: Likewise. * localedata/tst-mbswcs4.c: Likewise. * localedata/tst-mbswcs5.c: Likewise. * localedata/tst-setlocale.c: Likewise. * localedata/tst-trans.c: Likewise. * localedata/tst-wctype.c: Likewise. * localedata/tst-xlocale1.c: Likewise. * login/tst-grantpt.c: Likewise. * malloc/tst-calloc.c: Likewise. * malloc/tst-malloc.c: Likewise. * malloc/tst-mallocstate.c: Likewise. * malloc/tst-mcheck.c: Likewise. * malloc/tst-mtrace.c: Likewise. * malloc/tst-obstack.c: Likewise. * math/atest-exp2.c: Likewise. * math/atest-exp.c: Likewise. * math/atest-sincos.c: Likewise. * math/test-matherr.c: Likewise. * math/test-misc.c: Likewise. * math/test-powl.c: Likewise. * math/tst-definitions.c: Likewise. * misc/tst-dirname.c: Likewise. * misc/tst-efgcvt.c: Likewise. * misc/tst-fdset.c: Likewise. * misc/tst-hsearch.c: Likewise. * misc/tst-mntent2.c: Likewise. * nptl/tst-sem7.c: Likewise. * nptl/tst-sem8.c: Likewise. * nptl/tst-sem9.c: Likewise. * nss/test-netdb.c: Likewise. * posix/tst-fnmatch.c: Likewise. * posix/tst-getlogin.c: Likewise. * posix/tst-gnuglob.c: Likewise. * posix/tst-mmap.c: Likewise. * pwd/tst-getpw.c: Likewise. * resolv/tst-inet_ntop.c: Likewise. * rt/tst-timer.c: Likewise. * stdio-common/test-fseek.c: Likewise. * stdio-common/test-popen.c: Likewise. * stdio-common/test-vfprintf.c: Likewise. * stdio-common/tst-cookie.c: Likewise. * stdio-common/tst-fileno.c: Likewise. * stdio-common/tst-gets.c: Likewise. * stdio-common/tst-obprintf.c: Likewise. * stdio-common/tst-perror.c: Likewise. * stdio-common/tst-sprintf2.c: Likewise. * stdio-common/tst-sprintf3.c: Likewise. * stdio-common/tst-sprintf.c: Likewise. * stdio-common/tst-swprintf.c: Likewise. * stdio-common/tst-tmpnam.c: Likewise. * stdio-common/tst-unbputc.c: Likewise. * stdio-common/tst-wc-printf.c: Likewise. * stdlib/tst-environ.c: Likewise. * stdlib/tst-fmtmsg.c: Likewise. * stdlib/tst-limits.c: Likewise. * stdlib/tst-rand48-2.c: Likewise. * stdlib/tst-rand48.c: Likewise. * stdlib/tst-random2.c: Likewise. * stdlib/tst-random.c: Likewise. * stdlib/tst-strtol.c: Likewise. * stdlib/tst-strtoll.c: Likewise. * stdlib/tst-tls-atexit.c: Likewise. * stdlib/tst-xpg-basename.c: Likewise. * string/test-ffs.c: Likewise. * string/tst-bswap.c: Likewise. * string/tst-inlcall.c: Likewise. * string/tst-strtok.c: Likewise. * string/tst-strxfrm.c: Likewise. * sysdeps/x86_64/tst-audit10.c: Likewise. * sysdeps/x86_64/tst-audit3.c: Likewise. * sysdeps/x86_64/tst-audit4.c: Likewise. * sysdeps/x86_64/tst-audit5.c: Likewise. * time/tst-ftime_l.c: Likewise. * time/tst-getdate.c: Likewise. * time/tst-mktime3.c: Likewise. * time/tst-mktime.c: Likewise. * time/tst-posixtz.c: Likewise. * time/tst-strptime2.c: Likewise. * time/tst-strptime3.c: Likewise. * wcsmbs/tst-btowc.c: Likewise. * wcsmbs/tst-mbrtowc.c: Likewise. * wcsmbs/tst-mbsrtowcs.c: Likewise. * wcsmbs/tst-wchar-h.c: Likewise. * wcsmbs/tst-wcpncpy.c: Likewise. * wcsmbs/tst-wcrtomb.c: Likewise. * wcsmbs/tst-wcsnlen.c: Likewise. * wcsmbs/tst-wcstof.c: Likewise.
* Remove __libc_pselect alias.Joseph Myers2014-10-311-1/+0
| | | | | | | | | | | | Continuing the removal of unused __libc_* function names, this patch removes the __libc_pselect alias. Tested for x86_64 that installed stripped shared libraries are unchanged by this patch. * misc/pselect.c [!__pselect] (__libc_pselect): Remove alias. * sysdeps/unix/sysv/linux/pselect.c [__NR_pselect6] (__libc_pselect): Likewise.
* Remove __libc_readv and __libc_writev function names.Joseph Myers2014-10-302-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Continuing the removal of __libc_* function names that are no longer used anywhere, this patch removes the __libc_readv and __libc_writev names. Tested for x86_64 that stripped installed shared libraries are unchanged by the patch. * include/sys/uio.h (__libc_readv): Remove declaration. (__libc_writev): Likewise. * misc/readv.c (__libc_readv): Rename to __readv. (__readv): Do not define as alias. (readv): Define as alias of __readv. * misc/writev.c (__libc_writev): Rename to __writev. (__writev): Do not define as alias. (writev): Define as alias of __writev. * sysdeps/posix/readv.c (__libc_readv): Rename to __readv. (__readv): Do not define as alias. (readv): Define unconditionally as alias of __readv. * sysdeps/posix/writev.c (__libc_writev): Rename to __writev. (__writev): Do not define as alias. (writev): Define unconditionally as alias of __writev. * sysdeps/unix/syscalls.list (readv): Do not define __libc_readv name. (writev): Do not define __libc_writev name.
* Make __extern_always_inline usable on clang++ againSiddhesh Poyarekar2014-09-161-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fix for BZ #17266 (884ddc5081278f488ef8cd49951f41cfdbb480ce) removed changes that had gone into cdefs.h to make __extern_always_inline usable with clang++. This patch adds back support for clang to detect if GNU inlining semantics are available, this time without breaking the gcc use case. The check put here is based on the earlier patch and assertion[1] that checking if __GNUC_STDC_INLINE__ or __GNUC_GNU_INLINE__ is defined is sufficient to determine that clang++ suports GNU inlining semantics. Tested with a simple program that builds with __extern_always_inline with the patch and fails compilation without it. #include <stdio.h> #include <sys/cdefs.h> extern void foo_alias (void) __asm ("foo"); __extern_always_inline void foo (void) { puts ("hi oh world!"); return foo_alias (); } void foo_alias (void) { puts ("hell oh world"); } int main () { foo (); } [1] https://sourceware.org/ml/libc-alpha/2012-12/msg00306.html [BZ #17266] * misc/sys/cdefs.h: Define __extern_always_inline for clang 4.2 and newer.
* Revert to defining __extern_inline only for gcc-4.3+ (BZ #17266)Siddhesh Poyarekar2014-09-161-10/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The check for only __GNUC_STDC_INLINE__ and __GNUC_GNU_INLINE__ may not be sufficient since those flags were added during initial support for C99 inlining semantics. There is also a problem with always defining __extern_inline and __extern_always_inline, since it enables inline wrapper functions even when GNU inlining semantics are not guaranteed. This, along with the possibility of such wrappers using redirection (btowc for example) could result in compiler generating an infinitely recusrive call to the function. In fact it was such a recursion that led to this code being written the way it was; see: https://bugzilla.redhat.com/show_bug.cgi?id=186410 The initial change was to fix bugs 14530 and 13741, but they can be resolved by checking if __fortify_function and/or __extern_always_inline are defined, as it has been done in this patch. In addition, I have audited uses of __extern_always_inline to make sure that none of the uses result in compilation errors. There is however a regression in this patch for llvm, since it reverts the llvm expectation that __GNUC_STDC_INLINE__ or __GNUC_GNU_INLINE__ definition imply proper extern inline semantics. 2014-09-16 Siddhesh Poyarekar <siddhesh@redhat.com> Jakub Jelinek <jakub@redhat.com> [BZ #17266] * libio/stdio.h: Check definition of __fortify_function instead of __extern_always_inline to include bits/stdio2.h. * math/bits/math-finite.h [__USE_XOPEN || __USE_ISOC99]: Also check if __extern_always_inline is defined. [__USE_MISC || __USE_XOPEN]: Likewise. [__USE_ISOC99] Likewise. * misc/sys/cdefs.h (__fortify_function): Define only if __extern_always_inline is defined. [!__cplusplus || __GNUC_PREREQ (4,3)]: Revert to defining __extern_always_inline and __extern_inline only for g++-4.3 and newer or a compatible gcc.
* Sync up error.c with gnulibSiddhesh Poyarekar2014-07-101-10/+86
| | | | | | | | | | | | | Summary of changes: - Use of !_LIBC instead of HAVE_CONFIG_H - Code changes in [!_LIBC] that don't affect us - Minor formatting changes - Use __builtin_expect in shared code - Define some macros in [_LIBC] that are used in gnulib but never defined in glibc - Flip macro check for STRERROR_R_CHAR_P so that it does not throw a warning
* Fix Wundef warning for __STDC_VERSION__Siddhesh Poyarekar2014-07-031-1/+3
| | | | | | | | c4c4124473c187b5c4642611390897666c3d3970 added the _Noreturn macro for pre-C11 compilers, but it now throws a new Wundef warning during `make check` for __STDC_VERSION__ which gcc does not define by default. The following patch fixes this in line with other uses of __STDC_VERSION__ in the file.
* misc/sys/cdefs.h: Add _Noreturn macro for pre-C11 compilersPaul Eggert2014-07-021-0/+8
| | | | | | | 2014-07-02 Will Newton <will.newton@linaro.org> Paul Eggert <eggert@cs.ucla.edu> * misc/sys/cdefs.h (_Noreturn): New macro, for pre-C11 compilers.
* Use existing makefile variables for dependencies on glibc libraries.Joseph Myers2014-05-161-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | glibc's Makeconfig defines some variables such as $(libm) and $(libdl) for linking with libraries built by glibc, and nptl/Makeconfig (included by the toplevel Makeconfig) defines others such as $(shared-thread-library). In some places glibc's Makefiles use those variables when linking against the relevant libraries, but in other places they hardcode the location of the libraries in the build tree. This patch cleans up various places to use the variables that already exist (in the case of libm, replacing several duplicate definitions of a $(link-libm) variable in subdirectory Makefiles). (It's not necessarily exactly equivalent to what the existing code does - in particular, $(shared-thread-library) includes libpthread_nonshared, but is replacing places that just referred to libpthread.so. But I think that change is desirable on the general principle of linking things as close as possible to the way in which they would be linked with an installed library, unless there is a clear reason not to do so.) To support running tests with an installed copy of glibc without needing the full build tree from when that copy was built, I think it will be useful to use such variables more generally and systematically - every time the rules for building a test refer to some file from the build tree that's also installed by glibc, use a makefile variable so that the installed-testing case can point those variables to installed copies of the files. This patch just deals with straightforward cases where such variables already exist. It's quite possible some uses of $(shared-thread-library) should actually be a new $(thread-library) variable that's set appropriately in the --disable-shared case, if those uses would in fact work without shared libraries. I didn't change the status quo that those cases hardcode use of a shared library whether or not it's actually needed (but other uses such as $(libm) and $(libdl) would now get the static library if the shared library isn't built, when some previously hardcoded use of the shared library - if they actually need shared libraries, the test itself needs an enable-shared conditional anyway). Tested x86_64. * benchtests/Makefile ($(addprefix $(objpfx)bench-,$(bench-math))): Depend on $(libm), not $(common-objpfx)math/libm.so. ($(addprefix $(objpfx)bench-,$(bench-pthread))): Depend on $(shared-thread-library), not $(common-objpfx)nptl/libpthread.so. * elf/Makefile ($(objpfx)noload): Depend on $(libdl), not $(common-objpfx)dlfcn/libdl.so. ($(objpfx)tst-audit8): Depend on $(libm), not $(common-objpfx)math/libm.so. * malloc/Makefile ($(objpfx)libmemusage.so): Depend on $(libdl), not $(common-objpfx)dlfcn/libdl.so. * math/Makefile ($(addprefix $(objpfx),$(filter-out $(tests-static),$(tests)))): Depend on $(libm), not $(objpfx)libm.so. Do not condition on [$(build-shared) = yes]. ($(objpfx)test-fenv-tls): Depend on $(shared-thread-library), not $(common-objpfx)nptl/libpthread.so. * misc/Makefile ($(objpfx)tst-tsearch): Depend on $(libm), not $(common-objpfx)math/libm.so$(libm.so-version) or $(common-objpfx)math/libm.a depending on [$(build-shared) = yes]. * nptl/Makefile ($(objpfx)tst-unload): Depend on $(libdl), not $(common-objpfx)dlfcn/libdl.so. * setjmp/Makefile (link-libm): Remove variable. ($(objpfx)tst-setjmp-fp): Depend on $(libm), not $(link-libm). * stdio-common/Makefile (link-libm): Remove variable. ($(objpfx)tst-printf-round): Depend on $(libm), not $(link-libm). * stdlib/Makefile (link-libm): Remove variable. ($(objpfx)bug-getcontext): Depend on $(libm), not $(link-libm). ($(objpfx)tst-strtod-round): Likewise. ($(objpfx)tst-tininess): Likewise. ($(objpfx)tst-strtod-underflow): Likewise. ($(objpfx)tst-strtod6): Likewise. ($(objpfx)tst-tls-atexit): Depend on $(shared-thread-library) and $(libdl), not $(common-objpfx)nptl/libpthread.so and $(common-objpfx)dlfcn/libdl.so.
* misc/sys/xattr.h: guard against linux uapi header inclusionSerge Hallyn2014-03-181-0/+2
| | | | | | | | | | | | | | | | If the glibc xattr.h header is included after the uapi header, compilation fails due to an enum re-using a #define from the uapi header. Protect against this by guarding the define and enum inclusions against each other. (A corresponding kernel patch has been sent here: http://lkml.org/lkml/2014/3/7/331 ) (See https://lists.debian.org/debian-glibc/2014/03/msg00029.html and https://sourceware.org/glibc/wiki/Synchronizing_Headers for more information.) Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
* Make tests consistently use *.out output files.Joseph Myers2014-03-071-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch systematically renames miscellaneous tests so their outputs use a *.out name (unless the test is just running some glibc program with its conventional output file name, rather than a special program at all, as in catgets tests generating *.cat). In the case of the iconv test test-iconvconfig, output is redirected where it wasn't before. In various places the "generated" variable is updated to reflect the revised test names; in iconvdata/Makefile a typo (mmtrace-tst-loading) is also fixed. resolv/Makefile sets both "generate" (which appears unused) and "generated". Bitrot in the settings of these variables could no doubt be fixed so that "make clean" after build and testing leaves results the same as after configure (and indeed the tests-special / xtests-special variables could be used to simplify things, by removing those files automatically rather than listing them manually in these variables), and "make distclean" leaves an empty build directory, but right now it appears various files don't get deleted. I think they are liable to continue to bitrot in the absence of routine testing that these targets actually work, given that building in the source directory isn't supported and that was the main use of such makefile targets. Tested x86_64. * elf/Makefile (tests-special): Rename tests to end with .out. ($(objpfx)noload-mem): Likewise. ($(objpfx)tst-leaks1-mem): Likewise. ($(objpfx)tst-leaks1-static-mem.out): Likewise. * iconv/Makefile (xtests-special): Change test-iconvconfig to $(objpfx)test-iconvconfig.out. (test-iconvconfig): Change to $(objpfx)test-iconvconfig.out. Use set -e inside subshell and redirect output to file. * iconvdata/Makefile (generated): Rename tests to end with .out. Correct type. (tests-special): Rename tests to end with .out. ($(objpfx)mtrace-tst-loading): Likewise. * intl/Makefile (generated): Likewise. (tests-special): Likewise. ($(objpfx)mtrace-tst-gettext): Likewise. * misc/Makefile (generated): Likewise. (tests-special): Likewise. ($(objpfx)tst-error1-mem): Likewise. * nptl/Makefile (tests-special): Likewise. ($(objpfx)tst-stack3-mem): Likewise. (generated): Likewise. * posix/Makefile (generated): Likewise. (tests-special): Likewise. (xtests-special): Likewise. ($(objpfx)tst-fnmatch-mem): Likewise. ($(objpfx)bug-regex2-mem): Likewise. ($(objpfx)bug-regex14-mem): Likewise. ($(objpfx)bug-regex21-mem): Likewise. ($(objpfx)bug-regex31-mem): Likewise. ($(objpfx)tst-vfork3-mem): Likewise. ($(objpfx)tst-rxspencer-no-utf8-mem): Likewise. ($(objpfx)tst-pcre-mem): Likewise. ($(objpfx)tst-boost-mem): Likewise. ($(objpfx)bug-ga2-mem): Likewise. ($(objpfx)bug-glob2-mem): Likewise. * resolv/Makefile (generate): Likewise. (tests-special): Likewise. (xtests-special): Likewise. (generated): Likewise. ($(objpfx)mtrace-tst-leaks): Likewise. ($(objpfx)mtrace-tst-leaks2): Likewise. localedata: * Makefile (generated): Rename tests to end with .out. (tests-special): Likewise. ($(objpfx)mtrace-tst-leaks): Likewise.
* Enumerate tests with special rules in tests-special variable.Joseph Myers2014-03-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is a revised and updated version of <https://sourceware.org/ml/libc-alpha/2014-01/msg00196.html>. In order to generate overall summaries of the results of all tests in the glibc testsuite, we need to identify and concatenate the files with the results of individual tests. Tomas Dohnalek's patch used $(common-objpfx)*/*.test-result for this. However, the normal glibc approach is explicit enumeration of the expected set of files with a given property, rather than all files matching some pattern like that. Furthermore, we would like to be able to mark tests as UNRESOLVED if the file with their results is for some reason missing, and in future we would like to be able to mark tests as UNSUPPORTED if they are disabled for a particular configuration (rather than simply having them missing from the list of tests as at present). Such handling of tests that were not run or did not record results requires an explicit enumeration of tests. For the tests following the default makefile rules, $(tests) (and $(xtests)) provides such an enumeration. Others, however, are added directly as dependencies of the "tests" and "xtests" makefile targets. This patch changes the makefiles to put them in variables tests-special and xtests-special, with appropriate dependencies on the tests listed there then being added centrally. Those variables are used in Rules and so need to be set before Rules is included in a subdirectory makefile, which is often earlier in the makefile than the dependencies were present before. We previously discussed the question of where to include Rules; see the question at <https://sourceware.org/ml/libc-alpha/2012-11/msg00798.html>, and a discussion in <https://sourceware.org/ml/libc-alpha/2013-01/msg00337.html> of why Rules is included early rather than late in subdirectory makefiles. It was necessary to avoid an indirection through the check-abi target and get the check-abi-* targets for individual libraries into the tests-special variable. The intl/ test $(objpfx)tst-gettext.out, previously built only because of dependencies from other tests, was also added to tests-special for the same reason. The entries in tests-special are the full makefile targets, complete with $(objpfx) and .out. If a future change causes tests to be named consistently with a .out suffix, this can be changed to include just the path relative to $(objpfx), without .out. Tested x86_64, including that the same set of files is generated in the build directory by a build and testsuite run both before and after the patch (except for changes to the elf/tst-null-argv.debug.out.<number> file name), and a build with run-built-tests=no to verify there aren't any more obvious instances of the issue Marcus Shawcroft reported with a previous version in <https://sourceware.org/ml/libc-alpha/2014-01/msg00462.html>. * Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. (tests): Depend on $(tests-special). * Makerules (check-abi-list): New variable. (check-abi): Depend on $(check-abi-list). [$(subdir) = elf] (tests-special): Add $(objpfx)check-abi-libc.out. [$(build-shared) = yes && subdir] (tests-special): Add $(check-abi-list). [$(build-shared) = yes && subdir] (tests): Do not depend on check-abi. * Rules (tests): Depend on $(tests-special). (xtests): Depend on $(xtests-special). * catgets/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * conform/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * elf/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * grp/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * iconv/Makefile (xtests): Change dependencies to .... (xtests-special): ... additions to this variable. * iconvdata/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * intl/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. Also add $(objpfx)tst-gettext.out. * io/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * libio/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * malloc/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * misc/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * nptl/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * nptl_db/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * posix/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. (xtests): Change dependencies to .... (xtests-special): ... additions to this variable. * resolv/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. (xtests): Change dependencies to .... (xtests-special): ... additions to this variable. * stdio-common/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. (do-tst-unbputc): Remove target. (do-tst-printf): Likewise. * stdlib/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * string/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. * sysdeps/x86/Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable. localedata: * Makefile (tests): Change dependencies to .... (tests-special): ... additions to this variable.
* Fix fallout from Joseph's untested Makeconfig change.Roland McGrath2014-02-281-1/+1
|
* Consistently include Makeconfig after defining subdir.Joseph Myers2014-02-261-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In <https://sourceware.org/ml/libc-alpha/2014-01/msg00196.html> I noted it was necessary to add includes of Makeconfig early in various subdirectory makefiles for the tests-special variable settings added by that patch to be conditional on configuration information. No-one commented on the general question there of whether Makeconfig should always be included immediately after the definition of subdir. This patch implements that early inclusion of Makeconfig in each directory (which is a lot easier than consistent placement of includes of Rules). Includes are added if needed, or moved up if already present. Subdirectory "all:" targets are removed, since Makeconfig provides one. There is potential for further cleanups I haven't done. Rules and Makerules have code such as ifneq "$(findstring env,$(origin headers))" "" headers := endif to override to empty any value of various variables that came from the environment. I think there is a case for Makeconfig setting all the subdirectory variables (other than subdir) to empty to ensure no outside value is going to take effect if a subdirectory fails to define a variable. (A list of such variables, possibly out of date and incomplete, is in manual/maint.texi.) Rules and Makerules would give errors if Makeconfig hadn't already been included, instead of including it themselves. The special code to override values coming from the environment would then be obsolete and could be removed. Tested x86_64, including that installed binaries are identical before and after the patch. * argp/Makefile: Include Makeconfig immediately after defining subdir. * assert/Makefile: Likewise. * benchtests/Makefile: Likewise. * catgets/Makefile: Likewise. * conform/Makefile: Likewise. * crypt/Makefile: Likewise. * csu/Makefile: Likewise. (all): Remove target. * ctype/Makefile: Include Makeconfig immediately after defining subdir. * debug/Makefile: Likewise. * dirent/Makefile: Likewise. * dlfcn/Makefile: Likewise. * gmon/Makefile: Likewise. * gnulib/Makefile: Likewise. * grp/Makefile: Likewise. * gshadow/Makefile: Likewise. * hesiod/Makefile: Likewise. * hurd/Makefile: Likewise. (all): Remove target. * iconvdata/Makefile: Include Makeconfig immediately after defining subdir. * inet/Makefile: Likewise. * intl/Makefile: Likewise. * io/Makefile: Likewise. * libio/Makefile: Likewise. (all): Remove target. * locale/Makefile: Include Makeconfig immediately after defining subdir. * login/Makefile: Likewise. * mach/Makefile: Likewise. (all): Remove target. * malloc/Makefile: Include Makeconfig immediately after defining subdir. (all): Remove target. * manual/Makefile: Include Makeconfig immediately after defining subdir. * math/Makefile: Likewise. * misc/Makefile: Likewise. * nis/Makefile: Likewise. * nss/Makefile: Likewise. * po/Makefile: Likewise. (all): Remove target. * posix/Makefile: Include Makeconfig immediately after defining subdir. * pwd/Makefile: Likewise. * resolv/Makefile: Likewise. * resource/Makefile: Likewise. * rt/Makefile: Likewise. * setjmp/Makefile: Likewise. * shadow/Makefile: Likewise. * signal/Makefile: Likewise. * socket/Makefile: Likewise. * soft-fp/Makefile: Likewise. * stdio-common/Makefile: Likewise. * stdlib/Makefile: Likewise. * streams/Makefile: Likewise. * string/Makefile: Likewise. * sunrpc/Makefile: Likewise. (all): Remove target. * sysvipc/Makefile: Include Makeconfig immediately after defining subdir. * termios/Makefile: Likewise. * time/Makefile: Likewise. * timezone/Makefile: Likewise. (all): Remove target. * wcsmbs/Makefile: Include Makeconfig immediately after defining subdir. * wctype/Makefile: Likewise. libidn/ChangeLog: * Makefile: Include Makeconfig immediately after defining subdir. localedata/ChangeLog: * Makefile: Include Makeconfig immediately after defining subdir. (all): Remove target. nptl/ChangeLog: * Makefile: Include Makeconfig immediately after defining subdir. nptl_db/ChangeLog: * Makefile: Include Makeconfig immediately after defining subdir.
* misc/sys/select.h (__FD_MASK): Avoid signed integer overflow.Florian Weimer2014-02-251-1/+1
| | | | | | | Shifting into the sign position is currently supported as a GCC extension, but explicitly subjected to future changes. Computation in the unsigned type followed by a cast to the signed type is a GCC extension that will be available forever.
* Generate .test-result files for tests with special rules.Joseph Myers2014-02-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch, an updated version of <https://sourceware.org/ml/libc-alpha/2014-01/msg00194.html> now proposed for inclusion in glibc, extends the generation of PASS and FAIL status in .test-result files for individual tests to cover tests with their own custom makefile rules. This is just adding $(evaluate-test) calls to all such rules, since tests with multiple commands were previously split into separate tests. Note that the tests the makefiles expect to fail (posix/annexc and conformtest) currently get FAIL listed in the .test-result file, rather than XFAIL; a subsequent patch will introduce a better XFAIL mechanism. Tested x86_64. * Makefile ($(objpfx)c++-types-check.out): Use $(evaluate-test). ($(objpfx)check-local-headers.out): Likewise. ($(objpfx)begin-end-check.out): Likewise. * Makerules (check-abi-%.out): Likewise. * catgets/Makefile ($(objpfx)test1.cat): Likewise. ($(objpfx)test2.cat): Likewise. ($(objpfx)de/libc.cat): Likewise. ($(objpfx)test-gencat.out): Likewise. * conform/Makefile ($(objpfx)run-conformtest.out): Likewise. * elf/Makefile ($(objpfx)order-cmp.out): Likewise. ($(objpfx)noload-mem): Likewise. ($(objpfx)tst-pathopt.out): Likewise. ($(objpfx)tst-rtld-load-self.out): Likewise. ($(objpfx)tst-array1-cmp.out): Likewise. ($(objpfx)tst-array1-static-cmp.out): Likewise. ($(objpfx)tst-array2-cmp.out): Likewise. ($(objpfx)tst-array3-cmp.out): Likewise. ($(objpfx)tst-array4-cmp.out): Likewise. ($(objpfx)tst-array5-cmp.out): Likewise. ($(objpfx)tst-array5-static-cmp.out): Likewise. ($(objpfx)check-textrel.out): Likewise. ($(objpfx)check-execstack.out): Likewise. ($(objpfx)check-localplt.out): Likewise. ($(objpfx)order2-cmp.out): Likewise. ($(objpfx)tst-leaks1-mem): Likewise. ($(objpfx)tst-leaks1-static-mem): Likewise. ($(objpfx)tst-initorder-cmp.out): Likewise. ($(objpfx)tst-initorder2-cmp.out): Likewise. ($(objpfx)tst-unused-dep.out): Likewise. ($(objpfx)tst-unused-dep-cmp.out): Likewise. * grp/Makefile ($(objpfx)tst_fgetgrent.out): Likewise. * iconv/Makefile (test-iconvconfig): Likewise. * iconvdata/Makefile ($(objpfx)mtrace-tst-loading): Likewise. ($(objpfx)iconv-test.out): Likewise. ($(objpfx)tst-tables.out): Likewise. * intl/Makefile ($(objpfx)mtrace-tst-gettext): Likewise. ($(objpfx)tst-gettext.out): Likewise. ($(objpfx)tst-translit.out): Likewise. ($(objpfx)tst-gettext2.out): Likewise. ($(objpfx)tst-gettext4.out): Likewise. ($(objpfx)tst-gettext6.out): Likewise. * io/Makefile ($(objpfx)ftwtest.out): Likewise. * libio/Makefile ($(objpfx)test-freopen.out): Likewise. ($(objpfx)tst-fopenloc-cmp.out): Likewise. ($(objpfx)tst-fopenloc-mem.out): Likewise. * malloc/Makefile ($(objpfx)tst-mtrace.out): Likewise. * misc/Makefile ($(objpfx)tst-error1-mem): Likewise. * posix/Makefile ($(objpfx)globtest.out): Likewise. ($(objpfx)wordexp-tst.out): Likewise. ($(objpfx)annexc.out): Likewise. ($(objpfx)tst-fnmatch-mem): Likewise. ($(objpfx)bug-regex2-mem): Likewise. ($(objpfx)bug-regex14-mem): Likewise. ($(objpfx)bug-regex21-mem): Likewise. ($(objpfx)bug-regex31-mem): Likewise. ($(objpfx)tst-vfork3-mem): Likewise. ($(objpfx)tst-rxspencer-no-utf8-mem): Likewise. ($(objpfx)tst-pcre-mem): Likewise. ($(objpfx)tst-boost-mem): Likewise. ($(objpfx)tst-getconf.out): Likewise. ($(objpfx)bug-ga2-mem): Likewise. ($(objpfx)bug-glob2-mem): Likewise. * resolv/Makefile ($(objpfx)mtrace-tst-leaks): Likewise. ($(objpfx)mtrace-tst-leaks2): Likewise. * stdio-common/Makefile ($(objpfx)tst-unbputc.out): Likewise. ($(objpfx)tst-printf.out): Likewise. ($(objpfx)tst-setvbuf1.out): Likewise. ($(objpfx)tst-setvbuf1-cmp.out): Likewise. * stdlib/Makefile ($(objpfx)isomac.out): Likewise. ($(objpfx)tst-fmtmsg.out): Likewise. * string/Makefile ($(objpfx)tst-svc-cmp.out): Likewise. * sysdeps/x86/Makefile ($(objpfx)tst-xmmymm.out): Likewise. localedata: * Makefile ($(objpfx)sort-test.out): Use $(evaluate-test). ($(objpfx)tst-fmon.out): Likewise. ($(objpfx)tst-numeric.out): Likewise. ($(objpfx)tst-locale.out): Likewise. ($(objpfx)tst-rpmatch.out): Likewise. ($(objpfx)tst-trans.out): Likewise. ($(objpfx)tst-mbswcs.out): Likewise. ($(objpfx)tst-ctype.out): Likewise. ($(objpfx)tst-wctype.out): Likewise. ($(objpfx)tst-langinfo.out): Likewise. ($(objpfx)mtrace-tst-leaks): Likewise. nptl: * Makefile ($(objpfx)tst-stack3-mem): Use $(evaluate-test). ($(objpfx)tst-tls6.out): Likewise. ($(objpfx)tst-cleanup0.out): Likewise. ($(objpfx)tst-cleanup0-cmp.out): Likewise. ($(objpfx)tst-cancel-wrappers.out): Likewise. ($(objpfx)tst-oddstacklimit.out): Likewise. nptl_db: * Makefile ($(objpfx)db-symbols.out): Use $(evaluate-test).
* Complete _BSD_SOURCE / _SVID_source followup cleanup.Joseph Myers2014-02-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch completes the headers cleanup consequent on removal of _BSD_SOURCE and _SVID_SOURCE (apart from any subsequent deprecations): * #endif conditionals that referred to BSD or SVID are updated. * Redundant __USE_* tests in cases involving __USE_MISC are removed. This includes cases such as __USE_MISC || __USE_ISOC99, where __USE_MISC is redundant (because __USE_MISC is only ever defined in the default / _DEFAULT_SOURCE / _GNU_SOURCE case, when __USE_ISOC99 is also defined; the same applies to the non-XSI-extended POSIX versions), and cases involving __USE_GNU, where __USE_GNU is redundant (because if __USE_GNU is defined, so are the other __USE_* macros). There may well be other cases of __USE_FOO || __USE_BAR tests that could be simplified because one macro implies the other; this patch only addresses cases involving __USE_MISC. Tested x86_64. * bits/fcntl.h [__USE_MISC]: Remove redundant conditionals. * bits/sigaction.h [__USE_MISC]: Likewise. * bits/waitstatus.h: Update #endif comments. * ctype/ctype.h: Likewise. * dirent/dirent.h: Likewise. [__USE_MISC]: Remove redundant conditionals. * grp/grp.h: Update #endif comments. [__USE_GNU]: Remove redundant conditionals. [__USE_MISC]: Likewise. * inet/netinet/in.h [__USE_GNU]: Likewise. * io/sys/stat.h [__USE_MISC]: Likewise. * libio/bits/stdio-ldbl.h [__USE_MISC]: Likewise. * libio/bits/stdio.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * libio/bits/stdio2.h [__USE_MISC]: Likewise. * libio/stdio.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * math/bits/math-finite.h [__USE_MISC]: Likewise. * math/bits/mathcalls.h [__USE_MISC]: Likewise. * math/math.h: Update #else and #endif comments. [__USE_MISC]: Remove redundant conditionals. * misc/sys/uio.h: Update #endif comments. * posix/bits/unistd.h [__USE_MISC]: Remove redundant conditionals. * posix/glob.h [__USE_MISC]: Likewise. * posix/sys/types.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * posix/sys/wait.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * posix/unistd.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * pwd/pwd.h [__USE_GNU]: Likewise. [__USE_MISC]: Likewise. * resolv/netdb.h [__USE_GNU]: Likewise. * signal/signal.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * stdlib/stdlib.h: Update #else and #endif comments. [__USE_MISC]: Remove redundant conditionals. [__USE_GNU]: Likewise. * string/bits/string2.h [__USE_MISC]: Likewise. * string/string.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * sysdeps/m68k/m680x0/fpu/bits/mathinline.h [__USE_MISC]: Likewise. * sysdeps/mach/hurd/bits/fcntl.h [__USE_MISC]: Likewise. * sysdeps/mach/hurd/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/alpha/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/alpha/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/bits/fcntl-linux.h: Update #endif comments. [__USE_MISC]: Remove redundant conditionals. * sysdeps/unix/sysv/linux/bits/in.h [__USE_GNU]: Likewise. * sysdeps/unix/sysv/linux/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/bits/socket.h [__USE_GNU]: Likewise. * sysdeps/unix/sysv/linux/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/ia64/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/m68k/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/mips/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/mips/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/powerpc/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/s390/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/s390/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/sparc/bits/sigaction.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/sparc/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/unix/sysv/linux/x86/bits/stat.h [__USE_MISC]: Likewise. * sysdeps/x86/bits/string.h: Update #endif comments. * sysdeps/x86/fpu/bits/mathinline.h [__USE_MISC]: Remove redundant conditionals. * time/sys/time.h: Update #endif comments. * time/time.h: Likewise. [__USE_MISC]: Remove redundant conditionals.
* Combine __USE_BSD and __USE_SVID into __USE_MISC.Joseph Myers2014-02-126-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch cleans up following the obsoletion of _BSD_SOURCE and _SVID_SOURCE by combining __USE_BSD and __USE_SVID into __USE_MISC. The only non-mechanical part of this patch is the changes to features.h; everything else is simple substitution of __USE_MISC for the old macros. Thus, this patch leaves obviously redundant conditionals such as "defined __USE_MISC || defined __USE_MISC", and does not update #endif comments where they referred to BSD or SVID in words instead of the literal macro name. This is intended to facilitate patch review by separating the less mechanical changes from these purely mechanical changes into a separate patch. (I do intend to integrate all the changes from <https://sourceware.org/ml/libc-alpha/2013-12/msg00226.html>, which I believe includes all the trailing comment updates, in subsequent patches.) Tested x86_64. * include/features.h (__USE_BSD): Remove macro definitions. (__USE_SVID): Likewise. (_BSD_SOURCE): Likewise. (_SVID_SOURCE): Likewise. [!defined _BSD_SOURCE && !defined _SVID_SOURCE]: Remove condition from definition of _DEFAULT_SOURCE. [_BSD_SOURCE || _SVID_SOURCE]: Change condition to [_DEFAULT_SOURCE]. * bits/fcntl.h [__USE_BSD]: Change condition to [__USE_MISC]. * bits/mman.h [__USE_BSD]: Likewise. * bits/termios.h [__USE_BSD]: Likewise. * bits/waitstatus.h [__USE_BSD]: Likewise. * ctype/ctype.h [__USE_SVID]: Likewise. * dirent/dirent.h [__USE_BSD]: Likewise. * grp/grp.h [__USE_SVID]: Likewise. [__USE_BSD]: Likewise. * inet/netinet/igmp.h [__USE_BSD]: Likewise. * io/fcntl.h [__USE_BSD]: Likewise. * io/ftw.h [__USE_BSD]: Likewise. * io/sys/stat.h [__USE_BSD]: Likewise. * libio/bits/stdio-ldbl.h [__USE_BSD]: Likewise. * libio/bits/stdio2.h [__USE_BSD]: Likewise. * libio/stdio.h [__USE_SVID]: Likewise. [__USE_BSD]: Likewise. * math/math.h [__USE_SVID]: Likewise. [__USE_BSD]: Likewise. * misc/bits/syslog-ldbl.h [__USE_BSD]: Likewise. * misc/bits/syslog.h [__USE_BSD]: Likewise. * misc/search.h [__USE_SVID]: Likewise. * misc/sys/mman.h [__USE_BSD]: Likewise. * misc/sys/syslog.h [__USE_BSD]: Likewise. * misc/sys/uio.h [__USE_BSD]: Likewise. * posix/bits/unistd.h [__USE_BSD]: Likewise. * posix/glob.h [__USE_BSD]: Likewise. * posix/regex.h [__USE_BSD]: Likewise. * posix/sys/types.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * posix/sys/utsname.h [__USE_SVID]: Likewise. * posix/sys/wait.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * posix/unistd.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * pwd/pwd.h [__USE_SVID]: Likewise. * resolv/netdb.h [__USE_BSD]: Likewise. * setjmp/setjmp.h [__USE_BSD]: Likewise. * signal/signal.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * socket/sys/socket.h [__USE_BSD]: Likewise. * stdlib/fmtmsg.h [__USE_SVID]: Likewise. * stdlib/stdlib.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * string/bits/string2.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * string/bits/string3.h [__USE_BSD]: Likewise. * string/endian.h [__USE_BSD]: Likewise. * string/string.h [__USE_SVID]: Likewise. [__USE_BSD]: Likewise. * string/strings.h [__USE_BSD]: Likewise. * sysdeps/generic/netinet/ip.h [__USE_BSD]: Likewise. * sysdeps/gnu/netinet/ip_icmp.h [__USE_BSD]: Likewise. * sysdeps/mach/hurd/bits/fcntl.h [__USE_BSD]: Likewise. * sysdeps/mach/hurd/bits/stat.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/alpha/bits/mman.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/alpha/bits/termios.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/bits/fcntl-linux.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/bits/mman-linux.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/bits/sys_errlist.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/bits/termios.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/mips/bits/termios.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/netinet/if_ether.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/netinet/if_fddi.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/netinet/if_tr.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/powerpc/bits/termios.h [__USE_BSD]: Likewise. * sysdeps/unix/sysv/linux/sparc/bits/termios.h [__USE_BSD]: Likewise. * sysdeps/x86/bits/string.h [__USE_BSD]: Likewise. * sysvipc/sys/ipc.h [__USE_SVID]: Likewise. * termios/termios.h [__USE_BSD]: Likewise. * time/sys/time.h [__USE_BSD]: Likewise. * time/time.h [__USE_BSD]: Likewise. [__USE_SVID]: Likewise. * sysdeps/unix/sysv/linux/hppa/bits/mman.h [__USE_BSD]: Change condition to [__USE_MISC].
* Use glibc_likely instead __builtin_expect.Ondřej Bílka2014-02-102-2/+2
|
* Update copyright notices with scripts/update-copyrightsAllan McRae2014-01-01138-138/+138
|
* Add error reporting (via errno) to getauxval().Brooks Moses2013-12-182-2/+5
| | | | | | | | | | | | [BZ 15846] As discussed in the recent thread on my $EXEC_ORIGIN patch and in BZ 15846, getauxval() presently has no unambiguous way of reporting an error condition. It currently returns zero on error, but this may also be a valid result for some auxv entries. As there is no clear invalid result for all current and future auxv entries, this patch sets errno (following a suggestion in the BZ entry). This version of the patch also adds documentation and tests for the value-not-found conditions in getauxval().
* Remove libbsd-compat dummy library.Joseph Myers2013-12-171-2/+1
|
* Fix error_tail overflow in allocation calculation.Ondřej Bílka2013-10-141-1/+1
|
* Update generic swapon definition to match prototype.Ryan S. Arnold2013-10-041-2/+1
|
* Add GLRO(dl_hwcap2) for new AT_HWCAP2 auxv_t a_type.Ryan S. Arnold2013-06-281-0/+2
|
* Use (void) in no-arguments function definitions.Joseph Myers2013-06-0813-22/+22
|
* Avoid use of "register" as optimization hint.Joseph Myers2013-06-074-13/+13
|
* Remove trailing whitespace.Joseph Myers2013-06-051-1/+1
|
* Only defined DEV_BSIZE if not already defined.Aurelien Jarno2013-05-081-1/+3
|
* Use __gnu_inline__ for __extern_always_inline in g++-4.2Richard Smith2013-05-011-8/+6
| | | | | | | | | | | | | Use the __gnu_inline__ attribute in _FORTIFY_SOURCE's __extern_always_inline macro whenever the compiler supports it. Previously this macro only included the __gnu_inline__ attribute in C++ mode for gcc >= 4.3. However, __gnu_inline__ semantics are always desired for the __extern_always_inline functions, and are available in g++ 4.2 (and some releases of g++ 4.1, and also in Clang, which claims to be g++ 4.2). This change stops g++-4.2 from emitting weak definitions for the fortify wrapper functions if they can't be inlined, and also improves Clang compatibility.
* Fix copy'n'pastos.Thomas Schwinge2013-03-151-1/+1
|
* sys/cdefs.h: export __attribute_alloc_size__Mike Frysinger2013-02-181-0/+9
| | | | | | | | Since we want to use this in installed headers, move it to the installed sys/cdefs.h. This requires a slight tweaking of the name (add trailing underscores). Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* Fix build warnings in some test casesSiddhesh Poyarekar2013-02-181-0/+1
| | | | Include stdlib.h to get declaration of exit(3)
* Remove bounded-pointers build system support.Joseph Myers2013-02-151-4/+0
|
* Remove __ptrvalue, __bounded and __unbounded.Joseph Myers2013-02-131-8/+0
|
* Fix a typo in the mremap comment.Roland McGrath2013-02-111-1/+1
|
* Whitespace fix for __glibc_likely/__glibc_unlikely defns.Roland McGrath2013-01-231-4/+4
|
* Hide reference to mktemp in libpthreadAndreas Schwab2013-01-162-1/+3
|
* Remove unused macro ALLOCA_LIMIT.Roland McGrath2013-01-091-1/+0
|
* Fix copyright notice corruption from update-copyright bug.Joseph Myers2013-01-022-2/+2
|
* Update copyright notices with scripts/update-copyrights.Joseph Myers2013-01-02138-145/+138
|
* Add script to update copyright notices and reformat some to facilitate its use.Joseph Myers2013-01-011-1/+1
|
* Add __glibc_likely as an alias for __builtin_expect when availableSiddhesh Poyarekar2012-12-281-0/+2
|