diff options
author | Felix Fietkau <nbd@openwrt.org> | 2015-07-12 18:54:30 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2015-07-12 18:54:30 +0000 |
commit | 0f81020b9798c3b82617b76fb7ab8ae2e35e6069 (patch) | |
tree | 621b712979ad7b7c3a35ee5bafffcd297b41477e /toolchain | |
parent | 29039f51b3c6707f903018b53785409bf97f5fe0 (diff) | |
download | mtk-20170518-0f81020b9798c3b82617b76fb7ab8ae2e35e6069.zip mtk-20170518-0f81020b9798c3b82617b76fb7ab8ae2e35e6069.tar.gz mtk-20170518-0f81020b9798c3b82617b76fb7ab8ae2e35e6069.tar.bz2 |
gcc: use the -sf suffix for musl ldso on powerpc
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 46313
Diffstat (limited to 'toolchain')
3 files changed, 19 insertions, 6 deletions
diff --git a/toolchain/gcc/patches/4.8-linaro/203-musl_powerpc.patch b/toolchain/gcc/patches/4.8-linaro/203-musl_powerpc.patch index 7a70148..61e94be 100644 --- a/toolchain/gcc/patches/4.8-linaro/203-musl_powerpc.patch +++ b/toolchain/gcc/patches/4.8-linaro/203-musl_powerpc.patch @@ -17,7 +17,7 @@ #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_LINKER32 "/lib/ld-musl-powerpc%{msoft-float:-sf}.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 "}" @@ -72,7 +72,7 @@ #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" ++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-powerpc%{msoft-float:-sf}.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 "}}" diff --git a/toolchain/gcc/patches/4.9-linaro/203-musl_powerpc.patch b/toolchain/gcc/patches/4.9-linaro/203-musl_powerpc.patch index 4340c5f..033f586 100644 --- a/toolchain/gcc/patches/4.9-linaro/203-musl_powerpc.patch +++ b/toolchain/gcc/patches/4.9-linaro/203-musl_powerpc.patch @@ -17,7 +17,7 @@ #endif #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_LINKER32 "/lib/ld-musl-powerpc%{msoft-float:-sf}.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 "}" @@ -72,7 +72,7 @@ #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" ++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-powerpc%{msoft-float:-sf}.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 "}}" diff --git a/toolchain/musl/patches/010-Add-PowerPC-soft-float-support.patch b/toolchain/musl/patches/010-Add-PowerPC-soft-float-support.patch index 7dfb7ed..4ed0ade 100644 --- a/toolchain/musl/patches/010-Add-PowerPC-soft-float-support.patch +++ b/toolchain/musl/patches/010-Add-PowerPC-soft-float-support.patch @@ -7,8 +7,7 @@ instruction set for floating point operations (SPE). Executing regular PowerPC floating point instructions results in "Illegal instruction" errors. -Until support for SPE FPU is added, make it possible to run these -devices in soft-float mode. +Make it possible to run these devices in soft-float mode. Signed-off-by: Felix Fietkau <nbd@openwrt.org> --- @@ -18,6 +17,20 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org> create mode 100644 src/setjmp/powerpc-sf/setjmp.s create mode 100644 src/setjmp/powerpc-sf/setjmp.sub +--- a/arch/powerpc/reloc.h ++++ b/arch/powerpc/reloc.h +@@ -1,4 +1,10 @@ +-#define LDSO_ARCH "powerpc" ++#ifdef _SOFT_FLOAT ++#define FP_SUFFIX "-sf" ++#else ++#define FP_SUFFIX "" ++#endif ++ ++#define LDSO_ARCH "powerpc" FP_SUFFIX + + #define TPOFF_K (-0x7000) + --- a/configure +++ b/configure @@ -498,6 +498,10 @@ trycppif "_MIPSEL || __MIPSEL || __MIPSE |