summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-03-10ia64: disable atomic testsWaldemar Brodkorb
2016-02-29arm: fix __JMP_BUF_SP definitionMax Filippov
__JMP_BUF_SP is the index of a stack pointer slot in the __jmp_buf. According to ARM __sigsetjmp code it does not depend on configuration parameter __UCLIBC_HAS_FPU__. Make its definition unconditional. __JMP_BUF_SP is used in the unwind_stop through the _JMPBUF_CFA_UNWINDS_ADJ macro, this change fixes cleanup routines call on thread cancellation in configurations with hard FP. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
2016-02-24xtensa: fix stack unwinding over __default_sa_restorerMax Filippov
For some xtensa cores generated code gets arranged so that __default_sa_restorer immediately follows preceding function. E.g.: 40a1b: c03340 sub a3, a3, a4 40a1e: f01d retw.n 00040a20 <__default_sa_restorer>: 40a20: e1a022 movi a2, 225 40a23: 005000 syscall ... Contents of the .eh_frame section: ... 000007f4 00000014 000007f8 FDE cie=00000000 pc=0004076c..00040a20 DW_CFA_advance_loc4: 3 to 0004076f DW_CFA_def_cfa_offset: 48 Due to the way xtensa libgcc uw_frame_state_for calls _Unwind_Find_FDE for non-signal frames, FDE for the previous function is found during thread cancellation signal stack unwinding in that case. Signal stack frame is not recognized and is not unwound properly, breaking cleanup routines calling for cancelled thread. Insert padding before the __default_sa_restorer so that no FDE is found for it, MD_FALLBACK_FRAME_STATE_FOR is called by uw_frame_state_for and the frame is correctly recognized as signal frame. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
2016-02-24ARC: Disable obstackAnton Kolesov
Obstack was enabled in ARC defconfig to enable builds of native binutils and GDB. This is not needed after earlier patch which removes invalid _GNU_OBSTACK_INTERFACE_VERSION definition in cases when obstack is not selected in uClibc configuration. With this change binutils and GDB would use obstack implementation from their own source trees. In fact with recent binutils it is not possible to build it using obstack implementation in uClibc, because binutils/include/obstack.h started to use _obstack_free function instead of obstack_free, but _obstack_free is not defined in uClibc. Signed-off-by: Anton Kolesov <Anton.Kolesov@synopsys.com> Cc: Vineet Gupta <Vineet.Gupta1@synopsys.com> Cc: Alexey Brodkin <abrodkin@synopsys.com>
2016-02-24Advertise obstack only when chosenAnton Kolesov
This is similar to this patch for GNU glob: ff6ce3999db93a52d1cd22510f8508b660ddf54e. The problem is that libiberty/obstack.c file checks for _GNU_OBSTACK_INTERFACE_VERSION == _OBSTACK_INTERFACE_VERSION and elides libiberty obstack implementation if there is already a compatible implementation in libc. Therefore define should be set only when obstack is actually selected, otherwise it is not possible to build binutils and gdb with uClibc. Signed-off-by: Anton Kolesov <Anton.Kolesov@synopsys.com> Cc: Vineet Gupta <Vineet.Gupta1@synopsys.com> Cc: Alexey Brodkin <abrodkin@synopsys.com>
2016-02-24Replace /etc/resolv.conf with _PATH_RESCONF to allow portability of the code ↵Ubaldo Porcheddu
on system where resolv.conf is not in /etc . Signed-off-by: Ubaldo Porcheddu <ubaldo@eja.it>
2016-02-24Replaced any occurence of /bin/sh with _PATH_BSHELL to allow easier ↵Ubaldo Porcheddu
portability on system with default shell on a different directory, like for instance on android. Signed-off-by: Ubaldo Porcheddu <ubaldo@eja.it>
2016-02-21arm: allow to build with DODEBUG=yWaldemar Brodkorb
Avoids following linking error: /usr/lib/gcc/arm-openadk-linux-uclibceabihf/5.3.0/libgcc.a(unwind-arm.o): In function `unwind_phase2': ../w-gcc-5.3.0-1/gcc-5.3.0/libgcc/unwind-arm-common.inc:289: undefined reference to `abort' /usr/lib/gcc/arm-openadk-linux-uclibceabihf/5.3.0/libgcc.a(unwind-arm.o): In function `unwind_phase2_forced': ../w-gcc-5.3.0-1/gcc-5.3.0/libgcc/unwind-arm-common.inc:346: undefined reference to `memcpy' collect2: error: ld returned 1 exit status
2016-02-21mips64: with n64 ABI mapping failedWaldemar Brodkorb
Booting on Lemote Yeelong with a page size != 4kb ld.so is crashing and failed to load libc.so. Do not hardcode the offset for n64 ABI.
2016-02-20test: update ulps for SPARCWaldemar Brodkorb
2016-02-19test: update ulps file for ARMWaldemar Brodkorb
2016-02-19mark a.out support as not availableWaldemar Brodkorb
Some architectures do not provide the Linux header, so packages which include a.out.h might fail. Some discussions seen on the buildroot mailinglist.
2016-02-19libm: remove dead codeWaldemar Brodkorb
_IEEE_LIBM is always defined, so the other code is never used. I don't know when it was actively used.
2016-02-17increase timeouts to successfully run on slower hardware/emulation, f.e. xtensaWaldemar Brodkorb
2016-02-17refresh xtensa ulps fileWaldemar Brodkorb
2016-02-10libm: add ULPS for cris architectureWaldemar Brodkorb
2016-02-07frv: resurrect port somehow, totally untestedWaldemar Brodkorb
The FR-V port is really broken, and I have no emulator or hardware for this platform. I tried to get some hardware from RedHat, who made the FR-V port initially. Unfortunately Fujitsi didn't agreed to sent me some of their unused spare hardware lying @RedHat. As I invested some time to get stuff compiled, I decided to add the code and may be anytime later I can gain access to some emulator or hardware. GDB simulator for FR-V doesn't support booting Linux AFAIK.
2016-02-03mips: fix build if threads are disabledWaldemar Brodkorb
Reported-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
2016-02-02include/netdb.h: Do not define IDN-related flags.Thomas Claveirole
getaddrinfo() does not implement IDN encoding, and always fail when provided an IDN flag (e.g., AI_IDN) with EAI_BADFLAGS. Some packages (such as the VLC media player) check for AI_IDN before they use it; providing an unimplemented AI_IDN in the libc makes these package fail. As a result they make calls to getaddrinfo() with AI_IDN that always fail while they could have made successful calls without AI_IDN instead. Thus, do not define IDN flags: it is better not to compile rather than to compile a code that always fail. Signed-off-by: Thomas Claveirole <thomas.claveirole@green-communications.fr>
2016-01-31bump version for releasev1.0.12Waldemar Brodkorb
2016-01-31mips: fix clashing symbolsWaldemar Brodkorb
ISC bind9 uses ptrsize, better use something else. Reported-By: Gustavo Zacarias <gustavo@zacarias.com.ar> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31mips64: fix memcpy, patch from glibcWaldemar Brodkorb
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31add $ORIGIN test-caseWaldemar Brodkorb
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31ldso: Use single rtld_flags interpretation through all the callsLeonid Lisovskiy
Implement single rtld_flags interpretation through all the do_dlopen()/_dl_load_shared_library()/_dl_load_elf_shared_library() calls chain. This adds the ability to use the flags, passed to dlopen(), in all underlaying functions and implement rtld_flags inheritance. Saves a few bytes code. Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31ldso: Fix fail of $ORIGIN expansion in case of RTLD_NOLOADLeonid Lisovskiy
$ORIGIN expansion in search_for_named_library() wrongly takes into account all bits of rflags. Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31Provide __adjtimex() alias, like glibc.Leonid Lisovskiy
Althought recent versions of sofware don't require it, old ntpd wants - see http://bugs.ntp.org/show_bug.cgi?id=769 Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31tests: Extend OMIT LDFLAGS logic to test binaries tooLeonid Lisovskiy
In continue of 72215487 "tests: add OMIT logic to remove compilation flag." commit. Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31Make sure to always terminate decoded stringWaldemar Brodkorb
Write a terminating '\0' to dest when the first byte of the encoded data is 0. This corner case was previously missed. Signed-off-by: Daniel Fahlgren <daniel@fahlgren.se> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31Do not follow compressed items forever.Waldemar Brodkorb
It is possible to get stuck in an infinite loop when receiving a specially crafted DNS reply. Exit the loop after a number of iteration and consider the packet invalid. Signed-off-by: Daniel Fahlgren <daniel@fahlgren.se> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-31libdl: dlopen() mustn't forget RTLD_NODELETE flagLeonid Lisovskiy
If RTLD_NODELETE is passed to dlopen() rather than set on shared library itself, flag propagation to rtld_flags is missed. Test-case taken from glibc. Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com> Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-30add exp10() from glibcWaldemar Brodkorb
Some software make use of exp10, so add it. Basic testing with LTP. Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
2016-01-27nios2: allow to build toolchainWaldemar Brodkorb
At least allow to compile a toolchain targeting nios2 without MMU.
2016-01-27test: disable tests requiring math headersWaldemar Brodkorb
2016-01-25hppa: unbreak toolchain buildingWaldemar Brodkorb
At least allow to build a toolchain for hppa. Sync some headers with glibc.
2016-01-12Suppress warning "_GNU_SOURCE" redefinedWaldemar Brodkorb
libc/sysdeps/linux/common/euidaccess.c:1:1: warning: "_GNU_SOURCE" redefined In file included from <command-line>:0: ./include/libc-symbols.h:52:1: warning: this is the location of the previous definition Signed-Off-By: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10bump version for releasev1.0.11Waldemar Brodkorb
2016-01-10h8300: O_DIRECT and O_DIRECTORY swapping.Yoshinori Sato
Different define of latest kernel. kernel define is #define O_DIRECT 00040000 /* direct disk access hint */ #define O_DIRECTORY 00200000 /* must be a directory */ Yoshinori Sato <ysato@users.sourceforge.jp>
2016-01-10ARCH_NATIVE_BIT should in the first place be passed when building utils for hostEugene Rudoy
ARCH_NATIVE_BIT should in the first place be passed when building utils for host (BUILD_CFLAGS-utils). It could also be passed when building utils for target (CFLAGS-utils), but this is actually not necessary as ARCH_NATIVE_BIT and __WORDSIZE are identical in this case. Fixes 5ec4477584b69fe5f1410649b2eb3a63835fb649 (makes it actually work). Signed-off-by: Eugene Rudoy <gene@freetz.org>
2016-01-10order of special checks mattersWaldemar Brodkorb
The order of special checks seems critical for some applications. Xorg 1.18.0 fails to start with XNFreallocarray error. Took me some time to run with MALLOC_DEBUG=2 to find out. MALLOC_STANDARD is not affected.
2016-01-10NPTL: fix infinite recursionWaldemar Brodkorb
fix infinite recursion on application exit triggered by linking libc before libpthread. Patch from OpenWrt. Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10NPTL: Fix __pthread_once old style declarationWaldemar Brodkorb
Trivial fix. Signed-Off-By: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10Add implementation for copysignl for i386Waldemar Brodkorb
Patch from OpenWrt. Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10Implement legacy bcopy/bzero/bcmp/index/rindex as inline functionsWaldemar Brodkorb
patch from OpenWrt. Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10Provide XTI __t_scalar_t types, like glibcWaldemar Brodkorb
Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-10test-skeleton: Fixes from glibcWaldemar Brodkorb
glibc commits d7a05d0728 test-skeleton: Kill any child process's offspring cc8dcf96e7 test-skeleton: Support temporary files without memory leaks [BZ#18333] Reported-by: Leonid Lisovskiy <lly.dev@gmail.com>
2016-01-09fix compile with DODEBUG=yWaldemar Brodkorb
Since more projects using two-stage cross-compile process we cannot add libgcc_eh.a unconditionally. We must check if a real file is referenced by the cross-compiler. Toolchains with --disabel-shared build have a single libgcc.a containing all required symbols. Tested with a debug build for x86.
2016-01-07disable always failing tst-signal7Waldemar Brodkorb
The required test for the internal NPTL used signals isn't implemented.
2016-01-06Remove alias.Yoshinori Sato
open_cancel and open2_cancel have diffrent argument on open. So can't alias this functions. Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
2016-01-06openat argument fix.Yoshinori Sato
If argument passing to register case (ex. -mregparam=3). This case set all parameters set to register from caller. But callee refer to stack. So can't get parameter. Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
2016-01-06pthread_atfork handlers not removed during dlcloseWaldemar Brodkorb
Invoke pthread_atfork handler cleanup when removing the associated DSO... If a program loads a DSO (dlopen) that sets up a pthread_atfork handler(s), and then subsequently closes the DSO, the handler(s) are left in place. If fork() is subsequently called, the handlers are invoked even though the DSO has been removed causing crashes or unpredictable code execution. This is because the code in __cxa_finalize(atexit.c)to invoke the unregister_atfork() routine is ifdef'd out with the comment that it hasn't been "looked into this yet...". Refs.: http://bugs.busybox.net/show_bug.cgi?id=8211 http://sourceware.org/bugzilla/show_bug.cgi?id=13502 Add test-case, enable cleanup for NPTL only. Signed-off-by: John Ata <john.ata@baesystems.com> Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>