about summary refs log tree commit diff
Commit message (Collapse)AuthorAgeFilesLines
...
* Update translationsSiddhesh Poyarekar2020-03-042-10/+236
| | | | Incorporated updated translations from translationproject.org
* Convert Python scripts to Python 3Alistair Francis2020-03-037-7/+7
| | | | | | | | | Change all of the #! lines in Python scripts that are called from Makefiles to reference /usr/bin/python3. All of the scripts called from Makefiles are already run with Python 3, so let's make sure they are explicitly using Python 3 if called manually.
* alpha: Do not build with -fpicFlorian Weimer2020-03-031-4/+0
| | | | | | | | | | | | | | The combination of GCC 10 and binutils 2.35 (both unreleased) is no longer able to link the dynamic linker, due to a GP16 relocation overflow error: glibc/alpha-linux-gnu/elf/librtld.os: in function `calloc': glibc/elf/../include/rtld-malloc.h:44:(.text+0xd98): relocation truncated to fit: GPREL16 against symbol `__rtld_calloc' defined in .data.rel.ro section in glibc/alpha-linux-gnu/elf/librtld.os glibc/alpha-linux-gnu/elf/librtld.os: in function `malloc': glibc/elf/../include/rtld-malloc.h:56:(.text+0x2978): relocation truncated to fit: GPREL16 against symbol `__rtld_malloc' defined in .data.rel.ro section in glibc/alpha-linux-gnu/elf/librtld.os This is arguably a linker bug; the object files and their section size requirements look reasonable enough. Using -fPIC (the default) works around this issue.
* y2038: linux: Provide __utime64 implementationLukasz Majewski2020-03-033-1/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch replaces auto generated wrapper (as described in sysdeps/unix/sysv/linux/syscalls.list) for utime with one which adds extra support for setting file's access and modification 64 bit time on machines with __TIMESIZE != 64. Internally, the __utimensat_time64 helper function is used. This patch is necessary for having architectures with __WORDSIZE == 32 && __TIMESIZE != 64 Y2038 safe. Moreover, a 32 bit version - __utime has been refactored to internally use __utime64. The __utime is now supposed to be used on systems still supporting 32 bit time (__TIMESIZE != 64) - hence the necessary conversion between struct utimbuf and struct __utimbuf64. Build tests: ./src/scripts/build-many-glibcs.py glibcs Run-time tests: - Run specific tests on ARM/x86 32bit systems (qemu): https://github.com/lmajewski/meta-y2038 and run tests: https://github.com/lmajewski/y2038-tests/commits/master Above tests were performed with Y2038 redirection applied as well as without to test proper usage of both __utime64 and __utime. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* y2038: linux: Provide __utimes64 implementationLukasz Majewski2020-03-032-11/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch provides new __utimes64 explicit 64 bit function for setting file's 64 bit attributes for access and modification time. Internally, the __utimensat64_helper function is used. This patch is necessary for having architectures with __WORDSIZE == 32 Y2038 safe. Moreover, a 32 bit version - __utimes has been refactored to internally use __utimes64. The __utimes is now supposed to be used on systems still supporting 32 bit time (__TIMESIZE != 64) - hence the necessary conversion of struct timeval to 64 bit struct __timeval64. Build tests: ./src/scripts/build-many-glibcs.py glibcs Run-time tests: - Run specific tests on ARM/x86 32bit systems (qemu): https://github.com/lmajewski/meta-y2038 and run tests: https://github.com/lmajewski/y2038-tests/commits/master Above tests were performed with Y2038 redirection applied as well as without to test proper usage of both __utimes64 and __utimes. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* y2038: Introduce struct __utimbuf64 - new internal glibc typeLukasz Majewski2020-03-031-0/+12
| | | | | | | | | | | This type is a glibc's "internal" type to store file's access and modification times in __time64_t rather than __time_t, which makes it Y2038-proof. Build tests: ./src/scripts/build-many-glibcs.py glibcs Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org> Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
* microblaze: vfork is always availableFlorian Weimer2020-03-031-4/+0
| | | | | | | | | | Due to the built-in tables, __NR_vfork is always defined, so the fork-based fallback code is never used. (It appears that the vfork system call was wired up when the port was contributed to the kernel.) Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* m68k: getpagesize syscall number is always availableFlorian Weimer2020-03-031-4/+0
| | | | | | Due to the built-in tables, __NR_getpagesize is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: epoll_pwait syscall number is always availableFlorian Weimer2020-03-031-16/+0
| | | | | | Due to the built-in tables, __NR_epoll_pwait is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* x86_64: Do not define __NR_semtimedop in <sysdep.h>Florian Weimer2020-03-031-7/+0
| | | | | | The definition is always available from the built-in system call table. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* ia64: Do not define __NR_semtimedop in <sysdep.h>Florian Weimer2020-03-031-6/+0
| | | | | | The definition is always available from the built-in system call table. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: open_by_handle_at syscall number is always availableFlorian Weimer2020-03-031-9/+0
| | | | | | Due to the built-in tables, __NR_open_by_handle_at is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: set_robust_list syscall number is always availableFlorian Weimer2020-03-033-14/+6
| | | | | | | Due to the built-in tables, __NR_set_robust_list is always defined (although it may not be available at run time). Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: pciconfig_iobase syscall number is always available on alphaFlorian Weimer2020-03-031-2/+0
| | | | | | Due to the built-in tables, __NR_pciconfig_iobase is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: getdents64 syscall number is always available on MIPSFlorian Weimer2020-03-031-2/+0
| | | | | | | Due to the built-in tables, __NR_getdents64 is always defined, although it may not be supported at run time. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: Clean up preadv2, pwritev2 system call namesFlorian Weimer2020-03-034-22/+7
| | | | | | | | | | | With the built-in tables __NR_preadv2 and __NR_pwritev2 are always defined. The kernel has never defined __NR_preadv64v2 and __NR_pwritev64v2 and is unlikely to do so, given that the preadv2 and pwritev2 system calls themselves are 64-bit. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: exit_group syscall number is always availableFlorian Weimer2020-03-031-2/+0
| | | | | | Due to the built-in tables, __NR_exit_group is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: set_tid_address syscall number is always availableFlorian Weimer2020-03-031-2/+0
| | | | | | Due to the built-in tables, __NR_set_tid_address is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: pkey_mprotect syscall number is always availableFlorian Weimer2020-03-031-5/+0
| | | | | | Due to the built-in tables, __NR_pkey_mprotect is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: rt_sigqueueinfo syscall number is always availableFlorian Weimer2020-03-032-10/+0
| | | | | | | | | Due to the built-in tables, __NR_rt_sigqueueinfo is always defined. sysdeps/pthread/time_routines.c is not updated because it is shared with Hurd. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: getrandom syscall number is always availableFlorian Weimer2020-03-032-22/+0
| | | | | | Due to the built-in tables, __NR_getrandom is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: Clean up preadv, pwritev system call namesFlorian Weimer2020-03-034-28/+4
| | | | | | | The names __NR_preadv64, __NR_pwritev64 appear to be a glibc invention. With the built-in tables, __NR_preadv and __NR_pwritev are always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: Clean up pread64/pwrite64 system call namesFlorian Weimer2020-03-037-40/+4
| | | | | | | | | Linux removed the last definitions of __NR_pread and __NR_pwrite in commit 4ba66a9760722ccbb691b8f7116cad2f791cca7b, the removal of the blackfin port. All architectures now define __NR_pread64 and __NR_pwrite64 only. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: sigaltstack syscall number is always availableFlorian Weimer2020-03-031-4/+0
| | | | | | Due to the built-in tables, __NR_sigaltstack is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: sched_getaffinity syscall number is always availableFlorian Weimer2020-03-031-7/+3
| | | | | | Due to the built-in tables, __NR_sched_getaffinity is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: sched_setaffinity syscall number is always availableFlorian Weimer2020-03-031-6/+1
| | | | | | Due to the built-in tables, __NR_sched_setaffinity is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: statx syscall number is always availableFlorian Weimer2020-03-031-7/+4
| | | | | | Due to the built-in tables, __NR_statx is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: mq_* syscall numbers are always availableFlorian Weimer2020-03-037-41/+0
| | | | | | | | Due to the built-in tables, __NR_mq_getsetattr, __NR_mq_notify, __NR_mq_open, __NR_mq_timedreceive, __NR_mq_timedsend, __NR_mq_unlink are always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: mlock2 syscall number is always availableFlorian Weimer2020-03-031-2/+0
| | | | | | Due to the built-in tables, __NR_mlock2 is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: copy_file_range syscall number is always availableFlorian Weimer2020-03-031-5/+0
| | | | | | Due to the built-in tables, __NR_copy_file_range is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* Linux: renameat2 syscall number is always availableFlorian Weimer2020-03-031-4/+3
| | | | | | Due to the built-in tables, __NR_renameat2 is always defined. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* build-many-glibcs.py: Add list-compilers, list-glibcs commandsFlorian Weimer2020-03-031-4/+21
| | | | | These commands are helpful for scripting the distribution of build-many-glibcs.py runs across multiple builders.
* build-many-glibcs.py: Add --shallow optionFlorian Weimer2020-03-031-3/+12
| | | | | | | | The history is not used by build-many-glibcs.py itself. --replace-sources deletes an existing source tree before switching the version. But some users prefer to have the full history available, therefore make shallow clones optional with the --shallow option.
* Fixed typo in run_command_array() in support/shell-container.cGirish Joshi2020-03-021-1/+1
| | | | https://sourceware.org/bugzilla/show_bug.cgi?id=23991
* Add missing libc_hidden_def for __utimensat64Andreas Schwab2020-03-021-0/+2
|
* elf: Add elf/check-wx-segment, a test for the presence of WX segmentsFlorian Weimer2020-03-024-2/+108
| | | | | | | Writable, executable segments defeat security hardening. The existing check for DT_TEXTREL does not catch this. hppa and SPARC currently keep the PLT in an RWX load segment.
* i386: Use comdat instead of .gnu.linkonce for i386 setup pic register (BZ ↵Adhemerval Zanella2020-02-281-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | #20543) GCC has moved from using .gnu.linkonce for i386 setup pic register with minimum current version (as for binutils minimum binutils that support comdat). Trying to pinpoint when binutils has added comdat support for i686, it seems it was around 2004 [1]. I also checking with some ancient binutils older than 2.16 I see: test.o: In function `__x86.get_pc_thunk.bx': test.o(.text.__x86.get_pc_thunk.bx+0x0): multiple definition of `__x86.get_pc_thunk.bx' /usr/lib/gcc/x86_64-linux-gnu/5/../../../i386-linux-gnu/crti.o(.gnu.linkonce.t.__x86.get_pc_thunk.bx+0x0): first defined here Which seems that such version can not handle either comdat at all or a mix of linkonce and comdat. For binutils 2.16.1 I am getting a different issue trying to link a binary with and more recent ctri.o (unrecognized relocation (0x2b) in section `.init', which is R_386_GOT32X and old binutils won't generate it anyway). So I think that either unlikely someone will use an older binutils than the one used to glibc and even this scenario may fail with some issue as the R_386_GOT32X. Also, 2.16.1 is quite old and not really supported (glibc itself required 2.25). Checked on i686-linux-gnu. [1] https://gcc.gnu.org/ml/gcc/2004-05/msg00030.html
* ldbl-128ibm-compat: link tst-ldbl-efgcvt against loader tooPaul E. Murphy2020-02-281-0/+1
| | | | | | This also requires the linker workaround to ensure everything links correctly. See comment in sysdeps/powerpc/powerpc64/le/Makefile for details.
* ldbl-128ibm-compat: enforce ibm128 on compat testsPaul E. Murphy2020-02-281-0/+9
| | | | | | For lack of a more comprehensive solution, tack on the ibm128 ABI compiler options for the totalorder{,mag}l compat tests which exist prior to enabling this feature.
* ldbl-128ibm-compat: Provide nexttoward functionsGabriel F. T. Gomes2020-02-285-4/+65
| | | | | | | | | | | | | | | | | | | | | | | | | The functions in the nexttoward family are special, in the sense that they always have a long double argument, regardless of their suffix (i.e.: nexttowardf and nexttoward have a long double argument, besides the float and double arguments). On top of that, they are also special because nexttoward functions are not part of the _FloatN API, hence __nexttowardf128 do not exist. This patch adds 4 new function implementations for the new long double format: __nexttoward_to_ieee128 __nexttowardf_to_ieee128 __nexttowardieee128 (as an alias to __nextafterieee128) Likewise, rename "long double" "_Float128" in shared ldbl-128 files to ensure correct type is used irrespective of ABI switches. Thank you to those who helped out with this patch: Co-Authored-By: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
* ldbl-128ibm-compat: Provide a significand implementationTulio Magno Quites Machado Filho2020-02-282-0/+26
| | | | | Reuse the template in order to provide the global symbol __significandieee128.
* ldbl-128ibm-compat: Redirect complex math functionsRajalakshmi Srinivasaraghavan2020-02-281-2/+19
| | | | | | | The API doesn't change, i.e. compilers using a long double format compatible with the IEEE 128-bit extended precision format are redirected from *l functions to __*ieee128 symbols using the same mechanism already used with -mlong-double-64 for complex math functions.
* ldbl-128ibm-compat: Redirect long double functions to f128/ieee128 functionsTulio Magno Quites Machado Filho2020-02-285-18/+85
| | | | | | | | | | | | | | | | Modify the headers to redirect long double functions to global __*f128 symbols or to __*ieee128 otherwise. Most of the functions in math.h benefit from the infrastructure already available for __LDBL_COMPAT. The only exceptions are nexttowardf and nexttoward that need especial treatment. Both math/bits/mathcalls-helper-functions.h and math/bits/mathcalls.h were modified in order to provide alternative redirection destinations that are essential to support functions that should not be redirected to the same name pattern of the rest of the functions, i.e.: __fpclassify, __signbit, __iseqsig, __issignaling, isinf, finite and isnan, which will be redirected to __*f128 instead of __*ieee128 used for the rest.
* posix: Remove posix waitidAdhemerval Zanella2020-02-271-61/+9
| | | | | | | | | | | | | | | | The POSIX waitid implementation is problematic in some ways: - It emulates using waitpid, which default implementation calls wait4 and wait4 returns ENOSYS as default. - Also by using waitpid it does not allod support the WNOWAIT, WEXITED, WSTOPPED, or WCONTINUED flag. With current POSIX specification the flags are no longer marked as optional. Also due BZ#23091 Hurd still uses the implementation, so it is moved to as a Hurd arch-specific folder (with some minor cleanups). Checked against a i686-gnu (run-built-tests=no)
* posix: Refactor tst-waitid (BZ #14666)Adhemerval Zanella2020-02-271-396/+153
| | | | | | | | | | | | | The main changes are: - Adapt to libsupport. - Synchronize the signal handler using atomics. - Replace waitpid by waitid calls. - Use support_process_state_wait to wait for child state. - Add tests for P_PGID and P_ALL. - Use sigwaitinfo instead of global state set by the signal handler. Checked on x86_64-linux-gnu and i686-linux-gnu.
* support: Add support_process_state_waitAdhemerval Zanella2020-02-276-0/+278
| | | | | | | | | | | | | | It allows parent process to wait for child state using a polling strategy over procfs on Linux. The polling is used over ptrace to avoid the need to handle signals on the target pid and to handle some system specific limitation (such as YAMA). The polling has some limitations, such as resource consumption due the procfs read in a loop and the lack of synchronization after the state is obtained. The interface idea is to simplify some sleep synchronization waitid tests and is to reduce timeouts by replacing arbitrary waits.
* malloc/tst-mallocfork2: Kill lingering process for unexpected failuresAdhemerval Zanella2020-02-271-11/+28
| | | | | | | | | | | | | | | If the test fails due some unexpected failure after the children creation, either in the signal handler by calling abort or in the main loop; the created children might not be killed properly. This patches fixes it by: * Avoid aborting in the signal handler by setting a flag that an error has occured and add a check in the main loop. * Add a atexit handler to handle kill child processes. Checked on x86_64-linux-gnu.
* elf: Apply attribute_relro to pointers in elf/dl-minimal.cFlorian Weimer2020-02-261-8/+8
| | | | | | | | | | | | | The present code leaves the function pointers unprotected, but moves some of the static functions into .data.rel.ro instead. This causes the linker to produce an allocatable, executable, writable section and eventually an RWX load segment. Not only do we really do not want that, it also breaks valgrind because valgrind does not load debuginfo from the mmap interceptor if all it sees are RX and RWX mappings. Fixes commit 3a0ecccb599a6b1ad4b149dc569c0080e92d057b ("ld.so: Do not export free/calloc/malloc/realloc functions [BZ #25486]").
* powerpc: Refactor fenvinline.hRogerio Alves2020-02-251-13/+19
| | | | | | | This patch refactor fenviline.h replaces some statements for builtins. Reviewed-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
* nss_nis: Use NSS_DECLARE_MODULE_FUNCTIONSFlorian Weimer2020-02-256-28/+54
| | | | | This commit removes the minor optimization based on strong aliases because it loses type safety.