summaryrefslogtreecommitdiffstats
path: root/package/uclibc/0.9.32.1
diff options
context:
space:
mode:
Diffstat (limited to 'package/uclibc/0.9.32.1')
-rw-r--r--package/uclibc/0.9.32.1/uclibc-Fix-__libc_epoll_pwait-compile-failure-on-x86.patch43
-rw-r--r--package/uclibc/0.9.32.1/uclibc-Fix-e500-__fe_nomask_env-use-of-__set_errno.patch34
-rw-r--r--package/uclibc/0.9.32.1/uclibc-linuxthreads-errno-fix.patch68
-rw-r--r--package/uclibc/0.9.32.1/uclibc-sparc-errno-fix.patch11
-rw-r--r--package/uclibc/0.9.32.1/uclibc-unshare.patch82
5 files changed, 238 insertions, 0 deletions
diff --git a/package/uclibc/0.9.32.1/uclibc-Fix-__libc_epoll_pwait-compile-failure-on-x86.patch b/package/uclibc/0.9.32.1/uclibc-Fix-__libc_epoll_pwait-compile-failure-on-x86.patch
new file mode 100644
index 000000000..8cda4f902
--- /dev/null
+++ b/package/uclibc/0.9.32.1/uclibc-Fix-__libc_epoll_pwait-compile-failure-on-x86.patch
@@ -0,0 +1,43 @@
+From 8245f3b4638fdff2011c2657af1bb211def704bc Mon Sep 17 00:00:00 2001
+From: Phil Blundell <pb@pbcl.net>
+Date: Sat, 11 Jun 2011 01:10:46 -0400
+Subject: [PATCH] Fix __libc_epoll_pwait compile failure on x86
+
+This prevents "memory input 7 is not directly addressable" errors.
+
+| libc/sysdeps/linux/common/epoll.c: In function '__libc_epoll_pwait':
+| libc/sysdeps/linux/common/epoll.c:71:80: error: memory input 7 is not directly addressable
+| libc/sysdeps/linux/common/epoll.c:75:86: error: memory input 7 is not directly addressable
+| make: *** [libc/sysdeps/linux/common/epoll.o] Error 1
+| make: *** Waiting for unfinished jobs....
+
+Signed-off-by: Phil Blundell <pb@pbcl.net>
+Signed-off-by: Jason Woodward <jason.woodward@timesys.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libc/sysdeps/linux/common/epoll.c | 5 +++--
+ 1 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/libc/sysdeps/linux/common/epoll.c b/libc/sysdeps/linux/common/epoll.c
+index 85b0cfd..ab3e73b 100644
+--- a/libc/sysdeps/linux/common/epoll.c
++++ b/libc/sysdeps/linux/common/epoll.c
+@@ -67,12 +67,13 @@ extern __typeof(epoll_pwait) __libc_epoll_pwait;
+ int __libc_epoll_pwait(int epfd, struct epoll_event *events, int maxevents,
+ int timeout, const sigset_t *set)
+ {
++ int nsig = _NSIG / 8;
+ if (SINGLE_THREAD_P)
+- return INLINE_SYSCALL(epoll_pwait, 6, epfd, events, maxevents, timeout, set, _NSIG / 8);
++ return INLINE_SYSCALL(epoll_pwait, 6, epfd, events, maxevents, timeout, set, nsig);
+ # ifdef __UCLIBC_HAS_THREADS_NATIVE__
+ else {
+ int oldtype = LIBC_CANCEL_ASYNC ();
+- int result = INLINE_SYSCALL(epoll_pwait, 6, epfd, events, maxevents, timeout, set, _NSIG / 8);
++ int result = INLINE_SYSCALL(epoll_pwait, 6, epfd, events, maxevents, timeout, set, nsig);
+ LIBC_CANCEL_RESET (oldtype);
+ return result;
+ }
+--
+1.7.5.4
+
diff --git a/package/uclibc/0.9.32.1/uclibc-Fix-e500-__fe_nomask_env-use-of-__set_errno.patch b/package/uclibc/0.9.32.1/uclibc-Fix-e500-__fe_nomask_env-use-of-__set_errno.patch
new file mode 100644
index 000000000..1908925a3
--- /dev/null
+++ b/package/uclibc/0.9.32.1/uclibc-Fix-e500-__fe_nomask_env-use-of-__set_errno.patch
@@ -0,0 +1,34 @@
+>From 49f58308779cb0b798f5e7bc902bbc515c1ec394 Mon Sep 17 00:00:00 2001
+From: Jason Woodward <jason.woodward@timesys.com>
+Date: Sat, 11 Jun 2011 22:00:59 -0400
+Subject: [PATCH] Fix e500 __fe_nomask_env use of __set_errno w/o CFLAGS-libm
+
+Since the new _LIBC guard in 96c9a8f7d00cdf6bb7968a2390b9d87da8a45e2d we need
+to use CFLAGS-libm (-DNOT_IN_libc -DIS_IN_libm) or we end up with linker
+errors like:
+
+ lib/libm.a(fe_nomask.os): In function `__fe_nomask_env':
+ fe_nomask.c:(.text+0x26): undefined reference to `__libc_errno'
+ collect2: ld returned 1 exit status
+
+Signed-off-by: Jason Woodward <jason.woodward@timesys.com>
+---
+ libm/powerpc/e500/fpu/Makefile.arch | 2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/libm/powerpc/e500/fpu/Makefile.arch b/libm/powerpc/e500/fpu/Makefile.arch
+index 904561e..a64843f 100644
+--- a/libm/powerpc/e500/fpu/Makefile.arch
++++ b/libm/powerpc/e500/fpu/Makefile.arch
+@@ -11,6 +11,8 @@ libm_ARCH_SRC:=$(wildcard $(libm_ARCH_fpu_DIR)/*.c)
+ libm_ARCH_OBJ:=$(patsubst $(libm_ARCH_fpu_DIR)/%.c,$(libm_ARCH_fpu_OUT)/%.o,$(libm_ARCH_SRC))
+ endif
+
++CFLAGS-fe_nomask.c := $(CFLAGS-libm)
++
+ libm_ARCH_OBJS:=$(libm_ARCH_OBJ)
+
+ ifeq ($(DOPIC),y)
+--
+1.7.0.4
+
diff --git a/package/uclibc/0.9.32.1/uclibc-linuxthreads-errno-fix.patch b/package/uclibc/0.9.32.1/uclibc-linuxthreads-errno-fix.patch
new file mode 100644
index 000000000..c4d0d00df
--- /dev/null
+++ b/package/uclibc/0.9.32.1/uclibc-linuxthreads-errno-fix.patch
@@ -0,0 +1,68 @@
+From af8b2d71ce37b9d4d24ddbc755cdea68de02949a Mon Sep 17 00:00:00 2001
+From: Peter Korsgaard <jacmet@sunsite.dk>
+Date: Mon, 5 Jul 2010 14:08:17 +0200
+Subject: [PATCH] don't make __errno_location / __h_errno_location hidden
+
+Closes #2089 (https://bugs.busybox.net/show_bug.cgi?id=2089)
+
+__errno_location / __h_errno_location access has to go through the PLT
+like malloc/free, so the linuxthread variants gets used instead when
+compiling with -pthread.
+
+Based on http://github.com/mat-c/uClibc/commit/328d392c54aa5dc2b8e7f398a419087de497de2b
+
+Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
+---
+ include/netdb.h | 1 -
+ libc/misc/internals/__errno_location.c | 3 ---
+ libc/misc/internals/__h_errno_location.c | 1 -
+ libc/sysdeps/linux/common/bits/errno.h | 1 -
+ 6 files changed, 0 insertions(+), 11 deletions(-)
+
+diff --git a/include/netdb.h b/include/netdb.h
+index 9d3807d..ac411ab 100644
+--- a/include/netdb.h
++++ b/include/netdb.h
+@@ -59,7 +59,6 @@ __BEGIN_DECLS
+
+ /* Function to get address of global `h_errno' variable. */
+ extern int *__h_errno_location (void) __THROW __attribute__ ((__const__));
+-libc_hidden_proto(__h_errno_location)
+
+ /* Macros for accessing h_errno from inside libc. */
+ #ifdef _LIBC
+diff --git a/libc/misc/internals/__errno_location.c b/libc/misc/internals/__errno_location.c
+index 487a9c2..0620860 100644
+--- a/libc/misc/internals/__errno_location.c
++++ b/libc/misc/internals/__errno_location.c
+@@ -15,6 +15,3 @@ int * weak_const_function __errno_location (void)
+ {
+ return &errno;
+ }
+-#ifdef IS_IN_libc /* not really need, only to keep in sync w/ libc_hidden_proto */
+-libc_hidden_weak(__errno_location)
+-#endif
+diff --git a/libc/misc/internals/__h_errno_location.c b/libc/misc/internals/__h_errno_location.c
+index 213d398..235df4e 100644
+--- a/libc/misc/internals/__h_errno_location.c
++++ b/libc/misc/internals/__h_errno_location.c
+@@ -10,4 +10,3 @@ int * weak_const_function __h_errno_location (void)
+ {
+ return &h_errno;
+ }
+-libc_hidden_weak(__h_errno_location)
+diff --git a/libc/misc/internals/__uClibc_main.c b/libc/misc/internals/__uClibc_main.c
+index 6e520fa..f4a9ebb 100644
+--- a/libc/sysdeps/linux/common/bits/errno.h
++++ b/libc/sysdeps/linux/common/bits/errno.h
+@@ -43,7 +43,6 @@
+ # ifndef __ASSEMBLER__
+ /* Function to get address of global `errno' variable. */
+ extern int *__errno_location (void) __THROW __attribute__ ((__const__));
+-libc_hidden_proto(__errno_location)
+
+ # ifdef __UCLIBC_HAS_THREADS__
+ /* When using threads, errno is a per-thread value. */
+--
+1.7.1
+
diff --git a/package/uclibc/0.9.32.1/uclibc-sparc-errno-fix.patch b/package/uclibc/0.9.32.1/uclibc-sparc-errno-fix.patch
new file mode 100644
index 000000000..44d06cb62
--- /dev/null
+++ b/package/uclibc/0.9.32.1/uclibc-sparc-errno-fix.patch
@@ -0,0 +1,11 @@
+--- uClibc-0.9.32.ori/libc/sysdeps/linux/sparc/pipe.S 2011-06-08 21:35:20.000000000 +0200
++++ uClibc-0.9.32/libc/sysdeps/linux/sparc/pipe.S 2011-11-11 15:57:25.000000000 +0100
+@@ -52,7 +52,7 @@
+ restore %g0,%g0,%o0
+
+ .Lerror:
+- call HIDDEN_JUMPTARGET(__errno_location)
++ call __errno_location
+ or %g0,EINVAL,%i0
+ st %i0,[%o0]
+ ret
diff --git a/package/uclibc/0.9.32.1/uclibc-unshare.patch b/package/uclibc/0.9.32.1/uclibc-unshare.patch
new file mode 100644
index 000000000..5820e15bb
--- /dev/null
+++ b/package/uclibc/0.9.32.1/uclibc-unshare.patch
@@ -0,0 +1,82 @@
+Backport of unshare() syscall.
+From uClibc git 19dd090a0f68765db87990ef8eda9bf77bb29581
+
+Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
+
+---
+diff -Nura uClibc-0.9.32.orig/libc/sysdeps/linux/common/bits/sched.h uClibc-0.9.32/libc/sysdeps/linux/common/bits/sched.h
+--- uClibc-0.9.32.orig/libc/sysdeps/linux/common/bits/sched.h 2011-12-02 23:54:30.571841170 -0300
++++ uClibc-0.9.32/libc/sysdeps/linux/common/bits/sched.h 2011-12-02 23:57:45.874205079 -0300
+@@ -58,7 +58,13 @@
+ force CLONE_PTRACE on this clone. */
+ # define CLONE_CHILD_SETTID 0x01000000 /* Store TID in userlevel buffer in
+ the child. */
+-# define CLONE_STOPPED 0x02000000 /* Start in stopped state. */
++# define CLONE_STOPPED 0x02000000 /* Start in stopped state. */
++# define CLONE_NEWUTS 0x04000000 /* New utsname group. */
++# define CLONE_NEWIPC 0x08000000 /* New ipcs. */
++# define CLONE_NEWUSER 0x10000000 /* New user namespace. */
++# define CLONE_NEWPID 0x20000000 /* New pid namespace. */
++# define CLONE_NEWNET 0x40000000 /* New network namespace. */
++# define CLONE_IO 0x80000000 /* Clone I/O context. */
+ #endif
+
+ /* The official definition. */
+@@ -74,11 +80,9 @@
+ extern int clone (int (*__fn) (void *__arg), void *__child_stack,
+ int __flags, void *__arg, ...) __THROW;
+
+-#if 0
+ /* Unshare the specified resources. */
+ extern int unshare (int __flags) __THROW;
+ #endif
+-#endif
+
+ __END_DECLS
+
+diff -Nura uClibc-0.9.32.orig/libc/sysdeps/linux/common/Makefile.in uClibc-0.9.32/libc/sysdeps/linux/common/Makefile.in
+--- uClibc-0.9.32.orig/libc/sysdeps/linux/common/Makefile.in 2011-12-02 23:54:30.577841215 -0300
++++ uClibc-0.9.32/libc/sysdeps/linux/common/Makefile.in 2011-12-02 23:56:08.801527166 -0300
+@@ -24,7 +24,8 @@
+ remap_file_pages.c sched_getaffinity.c sched_setaffinity.c \
+ sendfile64.c sendfile.c setfsgid.c setfsuid.c setresuid.c \
+ splice.c vmsplice.c tee.c signalfd.c swapoff.c swapon.c \
+- sync_file_range.c sysctl.c sysinfo.c timerfd.c uselib.c vhangup.c
++ sync_file_range.c sysctl.c sysinfo.c timerfd.c unshare.c uselib.c \
++ vhangup.c
+ # NPTL needs these internally: madvise.c
+ CSRC-$(findstring y,$(UCLIBC_LINUX_SPECIFIC)$(UCLIBC_HAS_THREADS_NATIVE)) += madvise.c
+ ifeq ($(UCLIBC_HAS_THREADS_NATIVE),y)
+diff -Nura uClibc-0.9.32.orig/libc/sysdeps/linux/common/stubs.c uClibc-0.9.32/libc/sysdeps/linux/common/stubs.c
+--- uClibc-0.9.32.orig/libc/sysdeps/linux/common/stubs.c 2011-12-02 23:54:30.577841215 -0300
++++ uClibc-0.9.32/libc/sysdeps/linux/common/stubs.c 2011-12-02 23:58:18.803435042 -0300
+@@ -278,6 +278,10 @@
+ make_stub(umount2)
+ #endif
+
++#if !defined __NR_unshare && defined __UCLIBC_LINUX_SPECIFIC__
++make_stub(unshare)
++#endif
++
+ #ifndef __NR_utimensat
+ make_stub(futimens)
+ make_stub(utimensat)
+diff -Nura uClibc-0.9.32.orig/libc/sysdeps/linux/common/unshare.c uClibc-0.9.32/libc/sysdeps/linux/common/unshare.c
+--- uClibc-0.9.32.orig/libc/sysdeps/linux/common/unshare.c 1969-12-31 21:00:00.000000000 -0300
++++ uClibc-0.9.32/libc/sysdeps/linux/common/unshare.c 2011-12-02 23:58:42.693601880 -0300
+@@ -0,0 +1,15 @@
++/* vi: set sw=4 ts=4: */
++/*
++ * unshare() for uClibc
++ *
++ * Copyright (C) 2011 Henning Heinold <heinold@inf.fu-berlin.de>
++ *
++ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
++ */
++
++#include <sys/syscall.h>
++#include <sched.h>
++
++#if defined __NR_unshare
++_syscall1(int, unshare, int, flags)
++#endif