summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2013-09-04 15:58:51 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2013-09-04 15:58:51 +0200
commit29df7026088c973b5ba99b48f93b10006e5c0e4c (patch)
treebb69240c53349e5d4f37ce81036b3404acd2a6c6
parent3c20e7545c11200a09e8a37bf1929e1786a59c8b (diff)
parent3102de1e866e5f716baad9c6ead4162a5b393ceb (diff)
Merge branch 'master' of git+ssh://openadk.org/git/openadk
-rw-r--r--package/Makefile2
-rw-r--r--package/binutils/patches/musl.patch20
-rw-r--r--package/gcc/patches/musl.patch360
-rw-r--r--package/gdb/patches/patch-gdb_amd64-linux-nat_c73
-rw-r--r--package/gdb/patches/patch-gdb_config_i386_linux64_mh11
-rw-r--r--package/gdb/patches/patch-gdb_config_i386_linux_mh12
-rw-r--r--package/gdb/patches/patch-gdb_i386-linux-nat_c73
-rw-r--r--package/libxml2/Makefile4
-rw-r--r--package/libxml2/patches/patch-configure8
-rw-r--r--package/libxml2/patches/patch-ltmain_sh11
-rw-r--r--package/libxml2/patches/patch-threads_c53
-rw-r--r--package/libxslt/Makefile6
-rw-r--r--package/libxslt/patches/patch-configure241
-rw-r--r--package/libxslt/patches/patch-libexslt_Makefile_in11
-rw-r--r--package/libxslt/patches/patch-ltmain_sh11
-rw-r--r--package/libxslt/patches/patch-xsltproc_Makefile_in11
-rw-r--r--package/m4/patches/musl.patch109879
-rw-r--r--package/m4/patches/patch-lib_freadahead_c15
-rw-r--r--package/m4/patches/patch-lib_freadahead_h38
-rw-r--r--package/m4/patches/patch-lib_stdio_in_h4
-rwxr-xr-xscripts/makeinfo2
-rw-r--r--target/packages/pkg-available/development2
22 files changed, 110550 insertions, 297 deletions
diff --git a/package/Makefile b/package/Makefile
index 85321f9ee..112fe66c0 100644
--- a/package/Makefile
+++ b/package/Makefile
@@ -26,6 +26,7 @@ endif
ifneq (${ADK_TARGET_LIB_GLIBC},y)
ifneq (${ADK_TARGET_LIB_EGLIBC},y)
+ifneq (${ADK_TARGET_LIB_MUSL},y)
ifneq (${ADK_NATIVE},y)
package-$(ADK_PACKAGE_UCLIBC) += uclibc
gcc-compile: uclibc-compile
@@ -33,6 +34,7 @@ endif
package-$(ADK_PACKAGE_UCLIBCXX) += uclibc++
endif
endif
+endif
include $(TOPDIR)/package/Depends.mk
diff --git a/package/binutils/patches/musl.patch b/package/binutils/patches/musl.patch
new file mode 100644
index 000000000..4ea53c18f
--- /dev/null
+++ b/package/binutils/patches/musl.patch
@@ -0,0 +1,20 @@
+diff -Nur binutils-2.22.orig/config.sub binutils-2.22/config.sub
+--- binutils-2.22.orig/config.sub 2011-06-06 12:36:06.000000000 +0200
++++ binutils-2.22/config.sub 2013-08-11 14:40:22.308115171 +0200
+@@ -126,6 +126,7 @@
+ case $maybe_os in
+ nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
+ linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
++ linux-musl* | \
+ knetbsd*-gnu* | netbsd*-gnu* | \
+ kopensolaris*-gnu* | \
+ storm-chaos* | os2-emx* | rtmk-nova*)
+@@ -1334,7 +1335,7 @@
+ | -chorusos* | -chorusrdb* | -cegcc* \
+ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
+ | -mingw32* | -linux-gnu* | -linux-android* \
+- | -linux-newlib* | -linux-uclibc* \
++ | -linux-newlib* | -linux-uclibc* | -linux-musl* \
+ | -uxpv* | -beos* | -mpeix* | -udk* \
+ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
+ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
diff --git a/package/gcc/patches/musl.patch b/package/gcc/patches/musl.patch
new file mode 100644
index 000000000..4da8ce564
--- /dev/null
+++ b/package/gcc/patches/musl.patch
@@ -0,0 +1,360 @@
+diff -Nur gcc-4.7.3.orig/config.sub gcc-4.7.3/config.sub
+--- gcc-4.7.3.orig/config.sub 2012-08-06 16:34:27.000000000 +0200
++++ gcc-4.7.3/config.sub 2013-08-11 14:20:23.979180205 +0200
+@@ -125,6 +125,7 @@
+ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
+ case $maybe_os in
+ nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
++ linux-musl* | \
+ linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
+ knetbsd*-gnu* | netbsd*-gnu* | \
+ kopensolaris*-gnu* | \
+diff -Nur gcc-4.7.3.orig/fixincludes/mkfixinc.sh gcc-4.7.3/fixincludes/mkfixinc.sh
+--- gcc-4.7.3.orig/fixincludes/mkfixinc.sh 2011-09-22 16:00:17.000000000 +0200
++++ gcc-4.7.3/fixincludes/mkfixinc.sh 2013-08-11 14:17:48.905129751 +0200
+@@ -20,7 +20,8 @@
+ powerpc-*-eabi* | \
+ powerpc-*-rtems* | \
+ powerpcle-*-eabisim* | \
+- powerpcle-*-eabi* )
++ powerpcle-*-eabi* | \
++ *-musl* )
+ # IF there is no include fixing,
+ # THEN create a no-op fixer and exit
+ (echo "#! /bin/sh" ; echo "exit 0" ) > ${target}
+diff -Nur gcc-4.7.3.orig/gcc/config/arm/linux-eabi.h gcc-4.7.3/gcc/config/arm/linux-eabi.h
+--- gcc-4.7.3.orig/gcc/config/arm/linux-eabi.h 2011-11-02 16:03:19.000000000 +0100
++++ gcc-4.7.3/gcc/config/arm/linux-eabi.h 2013-08-11 14:17:15.153554066 +0200
+@@ -64,6 +64,10 @@
+ #undef GLIBC_DYNAMIC_LINKER
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.3"
+
++/* musl has no "classic" (i.e. broken) mode */
++#undef MUSL_DYNAMIC_LINKER
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-arm.so.1"
++
+ /* At this point, bpabi.h will have clobbered LINK_SPEC. We want to
+ use the GNU/Linux version, not the generic BPABI version. */
+ #undef LINK_SPEC
+diff -Nur gcc-4.7.3.orig/gcc/config/i386/linux64.h gcc-4.7.3/gcc/config/i386/linux64.h
+--- gcc-4.7.3.orig/gcc/config/i386/linux64.h 2011-07-07 17:38:34.000000000 +0200
++++ gcc-4.7.3/gcc/config/i386/linux64.h 2013-08-11 14:17:15.157554016 +0200
+@@ -31,3 +31,7 @@
+ #define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
+ #define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2"
+ #define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2"
++
++#define MUSL_DYNAMIC_LINKER32 "/lib/ld-musl-i386.so.1"
++#define MUSL_DYNAMIC_LINKER64 "/lib/ld-musl-x86_64.so.1"
++#define MUSL_DYNAMIC_LINKERX32 "/lib/ld-musl-x32.so.1"
+diff -Nur gcc-4.7.3.orig/gcc/config/i386/linux.h gcc-4.7.3/gcc/config/i386/linux.h
+--- gcc-4.7.3.orig/gcc/config/i386/linux.h 2011-06-03 20:30:39.000000000 +0200
++++ gcc-4.7.3/gcc/config/i386/linux.h 2013-08-11 14:17:15.153554066 +0200
+@@ -22,3 +22,4 @@
+
+ #define GNU_USER_LINK_EMULATION "elf_i386"
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-i386.so.1"
+diff -Nur gcc-4.7.3.orig/gcc/config/linux.h gcc-4.7.3/gcc/config/linux.h
+--- gcc-4.7.3.orig/gcc/config/linux.h 2012-08-14 15:59:04.000000000 +0200
++++ gcc-4.7.3/gcc/config/linux.h 2013-08-11 14:17:15.169553864 +0200
+@@ -33,10 +33,12 @@
+ #define OPTION_GLIBC (DEFAULT_LIBC == LIBC_GLIBC)
+ #define OPTION_UCLIBC (DEFAULT_LIBC == LIBC_UCLIBC)
+ #define OPTION_BIONIC (DEFAULT_LIBC == LIBC_BIONIC)
++#define OPTION_MUSL (DEFAULT_LIBC == LIBC_MUSL)
+ #else
+ #define OPTION_GLIBC (linux_libc == LIBC_GLIBC)
+ #define OPTION_UCLIBC (linux_libc == LIBC_UCLIBC)
+ #define OPTION_BIONIC (linux_libc == LIBC_BIONIC)
++#define OPTION_MUSL (linux_libc == LIBC_MUSL)
+ #endif
+
+ #define GNU_USER_TARGET_OS_CPP_BUILTINS() \
+@@ -54,18 +56,21 @@
+ uClibc or Bionic is the default C library and whether
+ -muclibc or -mglibc or -mbionic has been passed to change the default. */
+
+-#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LD1, LD2, LD3) \
+- "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:" LD1 "}}"
++#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LIBC4, LD1, LD2, LD3, LD4) \
++ "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:%{" LIBC4 ":" LD4 ";:" LD1 "}}}"
+
+ #if DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+- CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", G, U, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++ CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", "mmusl", G, U, B, M)
+ #elif DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+- CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", U, G, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++ CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", "mmusl", U, G, B, M)
+ #elif DEFAULT_LIBC == LIBC_BIONIC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+- CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", B, G, U)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++ CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", "mmusl", B, G, U, M)
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++ CHOOSE_DYNAMIC_LINKER1 ("mmusl", "mglibc", "muclibc", "mbionic", M, G, U, B)
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif /* DEFAULT_LIBC */
+@@ -85,16 +90,16 @@
+
+ #define GNU_USER_DYNAMIC_LINKER \
+ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER, \
+- BIONIC_DYNAMIC_LINKER)
++ BIONIC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+ #define GNU_USER_DYNAMIC_LINKER32 \
+ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, \
+- BIONIC_DYNAMIC_LINKER32)
++ BIONIC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64 \
+ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, \
+- BIONIC_DYNAMIC_LINKER64)
++ BIONIC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+ #define GNU_USER_DYNAMIC_LINKERX32 \
+ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERX32, UCLIBC_DYNAMIC_LINKERX32, \
+- BIONIC_DYNAMIC_LINKERX32)
++ BIONIC_DYNAMIC_LINKERX32, MUSL_DYNAMIC_LINKERX32)
+
+ /* Determine whether the entire c99 runtime
+ is present in the runtime library. */
+diff -Nur gcc-4.7.3.orig/gcc/config/linux.opt gcc-4.7.3/gcc/config/linux.opt
+--- gcc-4.7.3.orig/gcc/config/linux.opt 2010-09-29 16:51:52.000000000 +0200
++++ gcc-4.7.3/gcc/config/linux.opt 2013-08-11 14:17:15.169553864 +0200
+@@ -30,3 +30,7 @@
+ muclibc
+ Target Report RejectNegative Var(linux_libc,LIBC_UCLIBC) Negative(mbionic)
+ Use uClibc C library
++
++mmusl
++Target Report RejectNegative Var(linux_libc,LIBC_MUSL) Negative(mglibc)
++Use musl C library
+diff -Nur gcc-4.7.3.orig/gcc/config/mips/linux64.h gcc-4.7.3/gcc/config/mips/linux64.h
+--- gcc-4.7.3.orig/gcc/config/mips/linux64.h 2011-07-19 20:00:27.000000000 +0200
++++ gcc-4.7.3/gcc/config/mips/linux64.h 2013-08-11 14:17:15.357551501 +0200
+@@ -28,6 +28,9 @@
+ #define GLIBC_DYNAMIC_LINKERN32 "/lib32/ld.so.1"
+ #define UCLIBC_DYNAMIC_LINKERN32 "/lib32/ld-uClibc.so.0"
+ #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
++#define MUSL_DYNAMIC_LINKERN32 "/lib/ld-musl-mips.so.1"
++#define MUSL_DYNAMIC_LINKER32 "/lib/ld-musl-mips.so.1"
++#define MUSL_DYNAMIC_LINKER64 "/lib/ld-musl-mips.so.1"
+ #define GNU_USER_DYNAMIC_LINKERN32 \
+ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32, \
+- BIONIC_DYNAMIC_LINKERN32)
++ BIONIC_DYNAMIC_LINKERN32, MUSL_DYNAMIC_LINKERN32)
+diff -Nur gcc-4.7.3.orig/gcc/config/mips/linux.h gcc-4.7.3/gcc/config/mips/linux.h
+--- gcc-4.7.3.orig/gcc/config/mips/linux.h 2011-07-19 20:00:27.000000000 +0200
++++ gcc-4.7.3/gcc/config/mips/linux.h 2013-08-11 14:17:15.169553864 +0200
+@@ -19,3 +19,5 @@
+ <http://www.gnu.org/licenses/>. */
+
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
++
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-mips.so.1"
+diff -Nur gcc-4.7.3.orig/gcc/config/rs6000/linux64.h gcc-4.7.3/gcc/config/rs6000/linux64.h
+--- gcc-4.7.3.orig/gcc/config/rs6000/linux64.h 2012-03-12 17:16:51.000000000 +0100
++++ gcc-4.7.3/gcc/config/rs6000/linux64.h 2013-08-11 14:17:15.169553864 +0200
+@@ -362,17 +362,21 @@
+ #define GLIBC_DYNAMIC_LINKER64 "/lib64/ld64.so.1"
+ #define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0"
+ #define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER32 "/lib/ld-musl-powerpc.so.1"
++#define MUSL_DYNAMIC_LINKER64 "/lib/ld-musl-powerpc64.so.1"
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
+ #elif DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER32 \
+- CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32)
++ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64 \
+- CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64)
++ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+
+
+ #define LINK_OS_LINUX_SPEC32 "-m elf32ppclinux %{!shared: %{!static: \
+diff -Nur gcc-4.7.3.orig/gcc/config/rs6000/sysv4.h gcc-4.7.3/gcc/config/rs6000/sysv4.h
+--- gcc-4.7.3.orig/gcc/config/rs6000/sysv4.h 2012-04-30 19:39:01.000000000 +0200
++++ gcc-4.7.3/gcc/config/rs6000/sysv4.h 2013-08-11 14:17:15.173553814 +0200
+@@ -804,15 +804,18 @@
+
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+ #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-powerpc.so.1"
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #elif !defined (DEFAULT_LIBC) || DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER \
+- CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER)
++ CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+
+ #define LINK_OS_LINUX_SPEC "-m elf32ppclinux %{!shared: %{!static: \
+ %{rdynamic:-export-dynamic} \
+diff -Nur gcc-4.7.3.orig/gcc/config.gcc gcc-4.7.3/gcc/config.gcc
+--- gcc-4.7.3.orig/gcc/config.gcc 2013-03-06 23:54:11.000000000 +0100
++++ gcc-4.7.3/gcc/config.gcc 2013-08-11 14:17:15.141554216 +0200
+@@ -522,7 +522,7 @@
+ esac
+
+ # Common C libraries.
+-tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
++tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3 LIBC_MUSL=4"
+
+ # Common parts for widely ported systems.
+ case ${target} in
+@@ -625,6 +625,9 @@
+ *-*-*uclibc*)
+ tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC"
+ ;;
++ *-*-*musl*)
++ tm_defines="$tm_defines DEFAULT_LIBC=LIBC_MUSL"
++ ;;
+ *)
+ tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC"
+ ;;
+diff -Nur gcc-4.7.3.orig/gcc/configure gcc-4.7.3/gcc/configure
+--- gcc-4.7.3.orig/gcc/configure 2013-02-06 16:23:55.000000000 +0100
++++ gcc-4.7.3/gcc/configure 2013-08-11 14:17:42.205213980 +0200
+@@ -26902,6 +26902,9 @@
+ gcc_cv_target_dl_iterate_phdr=no
+ fi
+ ;;
++ *-linux-musl*)
++ gcc_cv_target_dl_iterate_phdr=yes
++ ;;
+ esac
+
+ if test x$gcc_cv_target_dl_iterate_phdr = xyes; then
+diff -Nur gcc-4.7.3.orig/gcc/ginclude/stddef.h gcc-4.7.3/gcc/ginclude/stddef.h
+--- gcc-4.7.3.orig/gcc/ginclude/stddef.h 2012-02-12 02:06:04.000000000 +0100
++++ gcc-4.7.3/gcc/ginclude/stddef.h 2013-08-11 14:17:15.349551601 +0200
+@@ -184,6 +184,7 @@
+ #ifndef _GCC_SIZE_T
+ #ifndef _SIZET_
+ #ifndef __size_t
++#ifndef __DEFINED_size_t /* musl */
+ #define __size_t__ /* BeOS */
+ #define __SIZE_T__ /* Cray Unicos/Mk */
+ #define _SIZE_T
+@@ -200,6 +201,7 @@
+ #define ___int_size_t_h
+ #define _GCC_SIZE_T
+ #define _SIZET_
++#define __DEFINED_size_t /* musl */
+ #if (defined (__FreeBSD__) && (__FreeBSD__ >= 5)) \
+ || defined(__FreeBSD_kernel__)
+ /* __size_t is a typedef on FreeBSD 5, must not trash it. */
+@@ -215,6 +217,7 @@
+ typedef long ssize_t;
+ #endif /* __BEOS__ */
+ #endif /* !(defined (__GNUG__) && defined (size_t)) */
++#endif /* __DEFINED_size_t */
+ #endif /* __size_t */
+ #endif /* _SIZET_ */
+ #endif /* _GCC_SIZE_T */
+diff -Nur gcc-4.7.3.orig/libgomp/config/posix/time.c gcc-4.7.3/libgomp/config/posix/time.c
+--- gcc-4.7.3.orig/libgomp/config/posix/time.c 2009-04-09 17:00:19.000000000 +0200
++++ gcc-4.7.3/libgomp/config/posix/time.c 2013-08-11 14:17:15.349551601 +0200
+@@ -28,6 +28,8 @@
+ The following implementation uses the most simple POSIX routines.
+ If present, POSIX 4 clocks should be used instead. */
+
++#define _POSIX_C_SOURCE 199309L /* for clocks */
++
+ #include "libgomp.h"
+ #include <unistd.h>
+ #if TIME_WITH_SYS_TIME
+diff -Nur gcc-4.7.3.orig/libitm/config/arm/hwcap.cc gcc-4.7.3/libitm/config/arm/hwcap.cc
+--- gcc-4.7.3.orig/libitm/config/arm/hwcap.cc 2011-12-15 04:24:05.000000000 +0100
++++ gcc-4.7.3/libitm/config/arm/hwcap.cc 2013-08-11 14:17:15.353551551 +0200
+@@ -40,7 +40,11 @@
+
+ #ifdef __linux__
+ #include <unistd.h>
++#ifdef __GLIBC__
+ #include <sys/fcntl.h>
++#else
++#include <fcntl.h>
++#endif
+ #include <elf.h>
+
+ static void __attribute__((constructor))
+diff -Nur gcc-4.7.3.orig/libitm/config/linux/x86/tls.h gcc-4.7.3/libitm/config/linux/x86/tls.h
+--- gcc-4.7.3.orig/libitm/config/linux/x86/tls.h 2011-11-08 12:13:41.000000000 +0100
++++ gcc-4.7.3/libitm/config/linux/x86/tls.h 2013-08-11 14:17:15.353551551 +0200
+@@ -25,16 +25,19 @@
+ #ifndef LIBITM_X86_TLS_H
+ #define LIBITM_X86_TLS_H 1
+
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ /* Use slots in the TCB head rather than __thread lookups.
+ GLIBC has reserved words 10 through 13 for TM. */
+ #define HAVE_ARCH_GTM_THREAD 1
+ #define HAVE_ARCH_GTM_THREAD_DISP 1
+ #endif
++#endif
+
+ #include "config/generic/tls.h"
+
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ namespace GTM HIDDEN {
+
+ #ifdef __x86_64__
+@@ -101,5 +104,6 @@
+
+ } // namespace GTM
+ #endif /* >= GLIBC 2.10 */
++#endif
+
+ #endif // LIBITM_X86_TLS_H
+diff -Nur gcc-4.7.3.orig/libstdc++-v3/configure.host gcc-4.7.3/libstdc++-v3/configure.host
+--- gcc-4.7.3.orig/libstdc++-v3/configure.host 2012-12-18 15:27:14.000000000 +0100
++++ gcc-4.7.3/libstdc++-v3/configure.host 2013-08-11 14:17:15.357551501 +0200
+@@ -243,6 +243,13 @@
+ os_include_dir="os/bsd/freebsd"
+ ;;
+ gnu* | linux* | kfreebsd*-gnu | knetbsd*-gnu)
++ # check for musl by target
++ case "${host_os}" in
++ *-musl*)
++ os_include_dir="os/generic"
++ ;;
++ *)
++
+ if [ "$uclibc" = "yes" ]; then
+ os_include_dir="os/uclibc"
+ elif [ "$bionic" = "yes" ]; then
+@@ -251,6 +258,9 @@
+ os_include_dir="os/gnu-linux"
+ fi
+ ;;
++
++ esac
++ ;;
+ hpux*)
+ os_include_dir="os/hpux"
+ ;;
diff --git a/package/gdb/patches/patch-gdb_amd64-linux-nat_c b/package/gdb/patches/patch-gdb_amd64-linux-nat_c
new file mode 100644
index 000000000..ac612d711
--- /dev/null
+++ b/package/gdb/patches/patch-gdb_amd64-linux-nat_c
@@ -0,0 +1,73 @@
+--- gdb-7.6.orig/gdb/amd64-linux-nat.c 2013-03-11 09:25:57.000000000 +0100
++++ gdb-7.6/gdb/amd64-linux-nat.c 2013-09-04 13:29:05.000000000 +0200
+@@ -25,8 +25,6 @@
+ #include "regset.h"
+ #include "linux-nat.h"
+ #include "amd64-linux-tdep.h"
+-#include "linux-btrace.h"
+-#include "btrace.h"
+
+ #include "gdb_assert.h"
+ #include "gdb_string.h"
+@@ -1121,47 +1119,6 @@ amd64_linux_read_description (struct tar
+ }
+ }
+
+-/* Enable branch tracing. */
+-
+-static struct btrace_target_info *
+-amd64_linux_enable_btrace (ptid_t ptid)
+-{
+- struct btrace_target_info *tinfo;
+- struct gdbarch *gdbarch;
+-
+- errno = 0;
+- tinfo = linux_enable_btrace (ptid);
+-
+- if (tinfo == NULL)
+- error (_("Could not enable branch tracing for %s: %s."),
+- target_pid_to_str (ptid), safe_strerror (errno));
+-
+- /* Fill in the size of a pointer in bits. */
+- gdbarch = target_thread_architecture (ptid);
+- tinfo->ptr_bits = gdbarch_ptr_bit (gdbarch);
+-
+- return tinfo;
+-}
+-
+-/* Disable branch tracing. */
+-
+-static void
+-amd64_linux_disable_btrace (struct btrace_target_info *tinfo)
+-{
+- int errcode = linux_disable_btrace (tinfo);
+-
+- if (errcode != 0)
+- error (_("Could not disable branch tracing: %s."), safe_strerror (errcode));
+-}
+-
+-/* Teardown branch tracing. */
+-
+-static void
+-amd64_linux_teardown_btrace (struct btrace_target_info *tinfo)
+-{
+- /* Ignore errors. */
+- linux_disable_btrace (tinfo);
+-}
+
+ /* Provide a prototype to silence -Wmissing-prototypes. */
+ void _initialize_amd64_linux_nat (void);
+@@ -1201,13 +1158,6 @@ _initialize_amd64_linux_nat (void)
+
+ t->to_read_description = amd64_linux_read_description;
+
+- /* Add btrace methods. */
+- t->to_supports_btrace = linux_supports_btrace;
+- t->to_enable_btrace = amd64_linux_enable_btrace;
+- t->to_disable_btrace = amd64_linux_disable_btrace;
+- t->to_teardown_btrace = amd64_linux_teardown_btrace;
+- t->to_read_btrace = linux_read_btrace;
+-
+ /* Register the target. */
+ linux_nat_add_target (t);
+ linux_nat_set_new_thread (t, amd64_linux_new_thread);
diff --git a/package/gdb/patches/patch-gdb_config_i386_linux64_mh b/package/gdb/patches/patch-gdb_config_i386_linux64_mh
new file mode 100644
index 000000000..4db9c518b
--- /dev/null
+++ b/package/gdb/patches/patch-gdb_config_i386_linux64_mh
@@ -0,0 +1,11 @@
+--- gdb-7.6.orig/gdb/config/i386/linux64.mh 2013-03-11 09:25:58.000000000 +0100
++++ gdb-7.6/gdb/config/i386/linux64.mh 2013-09-04 13:19:59.000000000 +0200
+@@ -3,7 +3,7 @@ NATDEPFILES= inf-ptrace.o fork-child.o \
+ i386-nat.o amd64-nat.o amd64-linux-nat.o \
+ linux-nat.o linux-osdata.o \
+ proc-service.o linux-thread-db.o linux-fork.o \
+- linux-procfs.o linux-ptrace.o linux-btrace.o
++ linux-procfs.o linux-ptrace.o
+ NAT_FILE= config/nm-linux.h
+ NAT_CDEPS = $(srcdir)/proc-service.list
+
diff --git a/package/gdb/patches/patch-gdb_config_i386_linux_mh b/package/gdb/patches/patch-gdb_config_i386_linux_mh
new file mode 100644
index 000000000..c137b8a0a
--- /dev/null
+++ b/package/gdb/patches/patch-gdb_config_i386_linux_mh
@@ -0,0 +1,12 @@
+--- gdb-7.6.orig/gdb/config/i386/linux.mh 2013-03-11 09:25:58.000000000 +0100
++++ gdb-7.6/gdb/config/i386/linux.mh 2013-09-04 13:19:46.000000000 +0200
+@@ -4,8 +4,7 @@ NAT_FILE= config/nm-linux.h
+ NATDEPFILES= inf-ptrace.o fork-child.o \
+ i386-nat.o i386-linux-nat.o \
+ proc-service.o linux-thread-db.o \
+- linux-nat.o linux-osdata.o linux-fork.o linux-procfs.o linux-ptrace.o \
+- linux-btrace.o
++ linux-nat.o linux-osdata.o linux-fork.o linux-procfs.o linux-ptrace.o
+ NAT_CDEPS = $(srcdir)/proc-service.list
+
+ # The dynamically loaded libthread_db needs access to symbols in the
diff --git a/package/gdb/patches/patch-gdb_i386-linux-nat_c b/package/gdb/patches/patch-gdb_i386-linux-nat_c
new file mode 100644
index 000000000..ab916efc8
--- /dev/null
+++ b/package/gdb/patches/patch-gdb_i386-linux-nat_c
@@ -0,0 +1,73 @@
+--- gdb-7.6.orig/gdb/i386-linux-nat.c 2013-03-11 09:25:57.000000000 +0100
++++ gdb-7.6/gdb/i386-linux-nat.c 2013-09-04 13:28:35.000000000 +0200
+@@ -25,8 +25,6 @@
+ #include "regset.h"
+ #include "target.h"
+ #include "linux-nat.h"
+-#include "linux-btrace.h"
+-#include "btrace.h"
+
+ #include "gdb_assert.h"
+ #include "gdb_string.h"
+@@ -1048,47 +1046,6 @@ i386_linux_read_description (struct targ
+ return tdesc_i386_linux;
+ }
+
+-/* Enable branch tracing. */
+-
+-static struct btrace_target_info *
+-i386_linux_enable_btrace (ptid_t ptid)
+-{
+- struct btrace_target_info *tinfo;
+- struct gdbarch *gdbarch;
+-
+- errno = 0;
+- tinfo = linux_enable_btrace (ptid);
+-
+- if (tinfo == NULL)
+- error (_("Could not enable branch tracing for %s: %s."),
+- target_pid_to_str (ptid), safe_strerror (errno));
+-
+- /* Fill in the size of a pointer in bits. */
+- gdbarch = target_thread_architecture (ptid);
+- tinfo->ptr_bits = gdbarch_ptr_bit (gdbarch);
+-
+- return tinfo;
+-}
+-
+-/* Disable branch tracing. */
+-
+-static void
+-i386_linux_disable_btrace (struct btrace_target_info *tinfo)
+-{
+- int errcode = linux_disable_btrace (tinfo);
+-
+- if (errcode != 0)
+- error (_("Could not disable branch tracing: %s."), safe_strerror (errcode));
+-}
+-
+-/* Teardown branch tracing. */
+-
+-static void
+-i386_linux_teardown_btrace (struct btrace_target_info *tinfo)
+-{
+- /* Ignore errors. */
+- linux_disable_btrace (tinfo);
+-}
+
+ /* -Wmissing-prototypes */
+ extern initialize_file_ftype _initialize_i386_linux_nat;
+@@ -1123,13 +1080,6 @@ _initialize_i386_linux_nat (void)
+
+ t->to_read_description = i386_linux_read_description;
+
+- /* Add btrace methods. */
+- t->to_supports_btrace = linux_supports_btrace;
+- t->to_enable_btrace = i386_linux_enable_btrace;
+- t->to_disable_btrace = i386_linux_disable_btrace;
+- t->to_teardown_btrace = i386_linux_teardown_btrace;
+- t->to_read_btrace = linux_read_btrace;
+-
+ /* Register the target. */
+ linux_nat_add_target (t);
+ linux_nat_set_new_thread (t, i386_linux_new_thread);
diff --git a/package/libxml2/Makefile b/package/libxml2/Makefile
index d6cbb4ffb..d8b994ab1 100644
--- a/package/libxml2/Makefile
+++ b/package/libxml2/Makefile
@@ -4,9 +4,9 @@
include ${TOPDIR}/rules.mk
PKG_NAME:= libxml2
-PKG_VERSION:= 2.7.8
+PKG_VERSION:= 2.9.1
PKG_RELEASE:= 1
-PKG_MD5SUM:= 8127a65e8c3b08856093099b52599c86
+PKG_MD5SUM:= 9c0cfef285d5c4a5c80d00904ddab380
PKG_DESCR:= XML C parser and toolkit
PKG_SECTION:= libs
PKG_DEPENDS:= zlib
diff --git a/package/libxml2/patches/patch-configure b/package/libxml2/patches/patch-configure
index f5a2ba355..13406bc62 100644
--- a/package/libxml2/patches/patch-configure
+++ b/package/libxml2/patches/patch-configure
@@ -1,6 +1,6 @@
---- libxml2-2.7.8.orig/configure 2010-11-04 18:28:14.000000000 +0100
-+++ libxml2-2.7.8/configure 2011-10-15 15:07:16.000000000 +0200
-@@ -13423,17 +13423,17 @@ case ${host} in
+--- libxml2-2.9.1.orig/configure 2013-04-19 09:36:11.000000000 +0200
++++ libxml2-2.9.1/configure 2013-09-04 15:16:48.000000000 +0200
+@@ -14010,17 +14010,17 @@ case ${host} in
esac
@@ -22,7 +22,7 @@
else
if test -x "$with_python/python.exe"
then
-@@ -13558,7 +13558,7 @@ else
+@@ -14148,7 +14148,7 @@ else
PYTHON_SUBDIR=
fi
diff --git a/package/libxml2/patches/patch-ltmain_sh b/package/libxml2/patches/patch-ltmain_sh
deleted file mode 100644
index e5746506c..000000000
--- a/package/libxml2/patches/patch-ltmain_sh
+++ /dev/null
@@ -1,11 +0,0 @@
---- libxml2-2.7.8.orig/ltmain.sh 2010-11-04 18:28:10.000000000 +0100
-+++ libxml2-2.7.8/ltmain.sh 2011-04-25 06:55:46.857662605 +0200
-@@ -5091,7 +5091,7 @@ func_mode_link ()
- # @file GCC response files
- # -tp=* Portland pgcc target processor selection
- -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
-- -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*)
-+ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|-fstack-protector*|-flto*)
- func_quote_for_eval "$arg"
- arg="$func_quote_for_eval_result"
- func_append compile_command " $arg"
diff --git a/package/libxml2/patches/patch-threads_c b/package/libxml2/patches/patch-threads_c
new file mode 100644
index 000000000..11b29ac6a
--- /dev/null
+++ b/package/libxml2/patches/patch-threads_c
@@ -0,0 +1,53 @@
+--- libxml2-2.9.1.orig/threads.c 2013-04-05 17:08:04.000000000 +0200
++++ libxml2-2.9.1/threads.c 2013-09-04 15:17:52.000000000 +0200
+@@ -47,49 +47,7 @@
+ #ifdef HAVE_PTHREAD_H
+
+ static int libxml_is_threaded = -1;
+-#ifdef __GNUC__
+-#ifdef linux
+-#if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3)
+-extern int pthread_once (pthread_once_t *__once_control,
+- void (*__init_routine) (void))
+- __attribute((weak));
+-extern void *pthread_getspecific (pthread_key_t __key)
+- __attribute((weak));
+-extern int pthread_setspecific (pthread_key_t __key,
+- __const void *__pointer)
+- __attribute((weak));
+-extern int pthread_key_create (pthread_key_t *__key,
+- void (*__destr_function) (void *))
+- __attribute((weak));
+-extern int pthread_key_delete (pthread_key_t __key)
+- __attribute((weak));
+-extern int pthread_mutex_init ()
+- __attribute((weak));
+-extern int pthread_mutex_destroy ()
+- __attribute((weak));
+-extern int pthread_mutex_lock ()
+- __attribute((weak));
+-extern int pthread_mutex_unlock ()
+- __attribute((weak));
+-extern int pthread_cond_init ()
+- __attribute((weak));
+-extern int pthread_cond_destroy ()
+- __attribute((weak));
+-extern int pthread_cond_wait ()
+- __attribute((weak));
+-extern int pthread_equal ()
+- __attribute((weak));
+-extern pthread_t pthread_self ()
+- __attribute((weak));
+-extern int pthread_key_create ()
+- __attribute((weak));
+-extern int pthread_key_delete ()
+- __attribute((weak));
+-extern int pthread_cond_signal ()
+- __attribute((weak));
+-#endif
+-#endif /* linux */
+-#endif /* __GNUC__ */
++
+ #endif /* HAVE_PTHREAD_H */
+
+ /*
diff --git a/package/libxslt/Makefile b/package/libxslt/Makefile
index b4306c66d..91424ca9c 100644
--- a/package/libxslt/Makefile
+++ b/package/libxslt/Makefile
@@ -4,9 +4,9 @@
include ${TOPDIR}/rules.mk
PKG_NAME:= libxslt
-PKG_VERSION:= 1.1.24
-PKG_RELEASE:= 2
-PKG_MD5SUM:= e83ec5d27fc4c10c6f612879bea9a153
+PKG_VERSION:= 1.1.28
+PKG_RELEASE:= 1
+PKG_MD5SUM:= 9667bf6f9310b957254fdcf6596600b7
PKG_DESCR:= XSLT Library
PKG_SECTION:= libs
PKG_DEPENDS:= libxml2
diff --git a/package/libxslt/patches/patch-configure b/package/libxslt/patches/patch-configure
deleted file mode 100644
index ea6b0cf6d..000000000
--- a/package/libxslt/patches/patch-configure
+++ /dev/null
@@ -1,241 +0,0 @@
---- libxslt-1.1.24.orig/configure 2008-05-13 17:40:54.000000000 +0200
-+++ libxslt-1.1.24/configure 2011-02-15 18:11:46.000000000 +0100
-@@ -6799,238 +6799,6 @@ fi
-
-
-
--if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
-- ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
-- (test "X$CXX" != "Xg++"))) ; then
-- ac_ext=cpp
--ac_cpp='$CXXCPP $CPPFLAGS'
--ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
--ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
--ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
--{ echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
--echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; }
--if test -z "$CXXCPP"; then
-- if test "${ac_cv_prog_CXXCPP+set}" = set; then
-- echo $ECHO_N "(cached) $ECHO_C" >&6
--else
-- # Double quotes because CXXCPP needs to be expanded
-- for CXXCPP in "$CXX -E" "/lib/cpp"
-- do
-- ac_preproc_ok=false
--for ac_cxx_preproc_warn_flag in '' yes
--do
-- # Use a header file that comes with gcc, so configuring glibc
-- # with a fresh cross-compiler works.
-- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-- # <limits.h> exists even on freestanding compilers.
-- # On the NeXT, cc -E runs the code through the compiler's parser,
-- # not just through cpp. "Syntax error" is here to catch this case.
-- cat >conftest.$ac_ext <<_ACEOF
--/* confdefs.h. */
--_ACEOF
--cat confdefs.h >>conftest.$ac_ext
--cat >>conftest.$ac_ext <<_ACEOF
--/* end confdefs.h. */
--#ifdef __STDC__
--# include <limits.h>
--#else
--# include <assert.h>
--#endif
-- Syntax error
--_ACEOF
--if { (ac_try="$ac_cpp conftest.$ac_ext"
--case "(($ac_try" in
-- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-- *) ac_try_echo=$ac_try;;
--esac
--eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-- ac_status=$?
-- grep -v '^ *+' conftest.er1 >conftest.err
-- rm -f conftest.er1
-- cat conftest.err >&5
-- echo "$as_me:$LINENO: \$? = $ac_status" >&5
-- (exit $ac_status); } >/dev/null && {
-- test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
-- test ! -s conftest.err
-- }; then
-- :
--else
-- echo "$as_me: failed program was:" >&5
--sed 's/^/| /' conftest.$ac_ext >&5
--
--