summaryrefslogtreecommitdiff
path: root/libc
AgeCommit message (Collapse)Author
2015-01-26merge upstream changesWaldemar Brodkorb
2015-01-26libc: sync_file_range missing commaBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2015-01-24libc: ppc64 etc: Fix sync_file_rangeBernhard Reutner-Fischer
Fix copy'n paste error for ppc64 and other sync_file_range2 arches Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2015-01-23add argument check in mknodWang Yufen
mknod() in glibc/eglibc will check the argument, like this, ... if (k_dev != dev) { __set_errno (EINVAL); return -1; } ... So add argument check in uclibc's mknod() too. Signed-off-by: Wang Yufen <wangyufen@huawei.com> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2015-01-23add argument check in setenv()Xishi Qiu
setenv() in glibc/eglibc will check the argument, like this, ... if (name == NULL || *name == '\0' || strchr (name, '=') != NULL) { __set_errno (EINVAL); return -1; } ... So add argument check in uclibc's setenv() too. Signed-off-by: Xishi Qiu <qiuxishi@huawei.com> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2015-01-22libc: Avoid redundant setting of ENOMEMBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2015-01-09enable microblaze. at least toolchain creation is working without NPTLWaldemar Brodkorb
2015-01-01shut up GCC, part 2Thorsten Glaser
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
2015-01-01shut up GCCThorsten Glaser
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
2015-01-01I think this is what you meanThorsten Glaser
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
2015-01-01silence GCCThorsten Glaser
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
2015-01-01remove apparently unused code, this time for realThorsten Glaser
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
2015-01-01remove unused Linux 2.0 compat code, otherwise c6x without NPTL is brokenWaldemar Brodkorb
2014-12-30remove another two warnings.Waldemar Brodkorb
2014-12-28reduce some unneeded warnings.Waldemar Brodkorb
2014-12-28for mips64 with N32 ABI we need to use newfstatatWaldemar Brodkorb
Fixes compile errors with latest util-linux.
2014-12-25merge upstream changesWaldemar Brodkorb
2014-12-15mkostemp: fix implementationAnthony G. Basile
mkostemp(char *template, int flags) generates a unique temporary filename from a template. The flags parameter accepts three of the same flags as open(2): O_APPEND, O_CLOEXEC, and O_SYNC. The current implementation of mkostemp(3) does not respect the flags and in fact confuses the flags with the file mode which should always be S_IRUSR | S_IWUSR. This patch corrects this issue. Signed-off-by: Anthony G. Basile <blueness@gentoo.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-12-15stdio: Fix printing 0.0Bernhard Reutner-Fischer
We were relying on FE_DIVBYZERO being turned off when printing "%f", +-.0 Avoid the whole issue by looking at the sign-bit (in a rough approximation). Note that we do not handle gracefully: printf ("\n%llf\n", -0.0); printf ("\n%llf\n", 0.0); nor %Lf for both when NOT cast to long double. Avoiding an FPE due to broken numbers like these does not make sense to me. Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-12-12unistd: allow to turn off getopt_longBernhard Reutner-Fischer
The GNU variant of getopt() previously had no way to turn off getopt_long() support.
2014-12-10mkostemp: fix implementationAnthony G. Basile
mkostemp(char *template, int flags) generates a unique temporary filename from a template. The flags parameter accepts three of the same flags as open(2): O_APPEND, O_CLOEXEC, and O_SYNC. The current implementation of mkostemp(3) does not respect the flags and in fact confuses the flags with the file mode which should always be S_IRUSR | S_IWUSR. This patch corrects this issue. Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-12-10add argument check in mknodwangyufen
mknod() in glibc/eglibc will check the argument, like this, ... if (k_dev != dev) { __set_errno (EINVAL); return -1; } ... So add argument check in uclibc's mknod() too. Signed-off-by: Wang Yufen <wangyufen@huawei.com>
2014-12-06arm: add RESET_PID in the clone implWang Yufen
Called getpid() When creating a new process with clone(), getpid() returns the father_process's value. It should be child_process's value. The reason is missing a RESET_PID in the arm clone impl. Signed-off-by: Wang Yufen <wangyufen@huawei.com> Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
2014-12-04Merge remote-tracking branch 'origin/upstream'Waldemar Brodkorb
2014-12-03mips: rename siginfo _timer membersBernhard Reutner-Fischer
Rename _timer[12] to si_tid and si_overrun to fix compilation of strace-4.9+ Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-12-01Merge remote-tracking branch 'origin/upstream'Waldemar Brodkorb
2014-11-19locale: Add wcsftime()Bernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-11-11Merge remote-tracking branch 'origin/upstream'Waldemar Brodkorb
2014-11-10statfs: fix compile error when UCLIBC_LINUX_SPECIFIC is not setAnthony G. Basile
statfs() is a Linux-specific function. When building without UCLIBC_LINUX_SPECIFIC set, libc_hidden_proto(statfs) in include/sys/statfs.h is unmatched with libc_hidden_def(statfs) in libc/sysdeps/linux/common/statfs.c, leading to a compile error. This patch fixes this, as well as adds statfs() to the list of Linux-specific functions in extra/Configs/Config.in. Signed-off-by: Anthony G. Basile <blueness@gentoo.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-10-11m68k: remove reg.hWaldemar Brodkorb
If reg.h exist, gdbserver fails to compile. I am not sure if this header file is needed for anything.
2014-10-01remove forced gcc optimizationWaldemar Brodkorb
It was added in 6d6bd8ba78434ecb09395582b5f3e41febd4d4ee, but it is unclear for me, why this is needed or if it is required. I don't think we should depend on some gcc optimization, which might change in the future. Anyway, this breaks c6x toolchain building (ICE), so I remove it. Testsuite run for supported architectures didn't add any new errors.
2014-09-26Add eventfd_read() and eventfd_write()Waldemar Brodkorb
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2014-09-26Do not define unimplemented functionsCristian Morales Vega
e.g. fminf() is not implemented, only fmin(), but both are defined. Signed-off-by: Cristian Morales Vega <cristian@samknows.com>
2014-09-26cris: remove call to HIDDEN_JUMPTARGETWaldemar Brodkorb
errno_location is no longer hidden, so remove the call to the macro, like done for sparc recently.
2014-09-26cris: do not include asm/elf.hWaldemar Brodkorb
elf.h is not exported by the Linux kernel, do not include it here. Done like in other architectures.
2014-09-22xtensa: add support for NPTLWaldemar Brodkorb
Changes from: https://github.com/foss-xtensa/uClibc/commits/xtensa_nptl Author: Chris Zankel <chris@zankel.net> Author: Baruch Siach <baruch@tkos.co.il>
2014-09-20linuxthreads: remove unused s390 codeWaldemar Brodkorb
Cleanup linuxthreads by removing unused s390 code. Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
2014-09-17m68k: libc: add fmovem* mcffpu conditionBernhard Reutner-Fischer
add fmovem{x,.d,.*} ISA conditional Fixes assembler errors for 5206. isa_a, isa_b (or a+, don't remember) do not have emx, use em.d there. Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-16sparc: update ptrace.h to latest from glibcGustavo Zacarias
Update sys/ptrace.h to latest glibc release for a lot of missing definitions. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-16powerpc: update ptrace.h to latest from glibcGustavo Zacarias
Update sys/ptrace.h to latest glibc release for a lot of missing definitions. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-16libc: silence missing prototype warningBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-16buildsys: fix IS_IN_lib*Bernhard Reutner-Fischer
define NOT_IN_libc / IS_IN_libxxx appropriately to fix pthread_once Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-09libc: add fallocate() and fallocate64()Anthony G. Basile
We add the Linux-specific function fallocate() which allows the user to directly manipulate allocate space for a file. fallocate() can operate in different modes, but the default mode is equivalent to posix_fallocate() which is specified in POSIX.1. Recent releases of e2fsprogs 1.42.11 and above expect fallocate64() to be available. Signed-off-by: Anthony G. Basile <blueness@gentoo.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-05libc: split multi-source epoll.cBernhard Reutner-Fischer
We cannot override individual functions on a per-arch basis otherwise Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-09-04sparc: remove sparc64/sparcv9 codeWaldemar Brodkorb
The sparc64/sparcv9 code is incomplete. Furthermore there is no real embedded hardware for sparc64 available, so better remove it until someone comes up with a complete port. Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-08-28m68k: fix typoWaldemar Brodkorb
otherwise you get compile warnings, when building for m68k. Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-08-28Revert "sparc: disable cancellable system, as it fails in strange ways right ↵Waldemar Brodkorb
now" This reverts commit 1db4f8f8389f6a935ecd83aff7fcce5d1cf2c0f3. It is unclear in which way this is breaking sparc systems. With this change added you get following linking error: libpthread/nptl/libpthread_so.a(pt-system.oS): In function `__libc_system': libc/stdlib/system.c:64: undefined reference to `__wait4_nocancel' Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-08-28Revert "sparc: use HIDDEN_JUMPTARGET for errno"Waldemar Brodkorb
This reverts commit f51fb26dbcceee9e48d10facc830bd4a549f6cc2. This fixes linking error for sparc build. While building a sparc system you get following linking error: libc/sysdeps/linux/sparc/pipe.S:54: undefined reference to `__GI___errno_location' Removing the HIDDEN_JUMPTARGET fixes the issue, while using gcc 4.8.3/binutils 2.24. The definition of __errno_location was changed recently here: http://git.uclibc.org/uClibc/commit/?id=8f550715c2b211036fc273add3cb5219397ed312 Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-08-25microblaze: Remove duplicate F_{S,G}ETPIPE_SZBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-08-25fcntl.h: Define F_SETPIPE_SZ and F_GETPIPE_SZKhem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>