diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/reloc.h | 15 | ||||
-rw-r--r-- | arch/i386/reloc.h | 2 | ||||
-rw-r--r-- | arch/microblaze/reloc.h | 9 | ||||
-rw-r--r-- | arch/mips/reloc.h | 9 | ||||
-rw-r--r-- | arch/powerpc/reloc.h | 2 | ||||
-rw-r--r-- | arch/x86_64/reloc.h | 2 |
6 files changed, 33 insertions, 6 deletions
diff --git a/arch/arm/reloc.h b/arch/arm/reloc.h index b41314de..9ca0b48c 100644 --- a/arch/arm/reloc.h +++ b/arch/arm/reloc.h @@ -1,7 +1,20 @@ #include <string.h> #include <elf.h> +#include <endian.h> -#define ETC_LDSO_PATH "/etc/ld-musl-arm.path" +#if __BYTE_ORDER == __BIG_ENDIAN +#define ENDIAN_SUFFIX "eb" +#else +#define ENDIAN_SUFFIX "" +#endif + +#if __SOFTFP__ +#define FP_SUFFIX "" +#else +#define FP_SUFFIX "hf" +#endif + +#define LDSO_ARCH "arm" ENDIAN_SUFFIX FP_SUFFIX #define IS_COPY(x) ((x)==R_ARM_COPY) #define IS_PLT(x) ((x)==R_ARM_JUMP_SLOT) diff --git a/arch/i386/reloc.h b/arch/i386/reloc.h index da0bc05d..3923b54b 100644 --- a/arch/i386/reloc.h +++ b/arch/i386/reloc.h @@ -1,7 +1,7 @@ #include <string.h> #include <elf.h> -#define ETC_LDSO_PATH "/etc/ld-musl-i386.path" +#define LDSO_ARCH "i386" #define IS_COPY(x) ((x)==R_386_COPY) #define IS_PLT(x) ((x)==R_386_JMP_SLOT) diff --git a/arch/microblaze/reloc.h b/arch/microblaze/reloc.h index 81add5e9..60f74225 100644 --- a/arch/microblaze/reloc.h +++ b/arch/microblaze/reloc.h @@ -1,7 +1,14 @@ #include <string.h> #include <elf.h> +#include <endian.h> -#define ETC_LDSO_PATH "/etc/ld-musl-microblaze.path" +#if __BYTE_ORDER == __LITTLE_ENDIAN +#define ENDIAN_SUFFIX "el" +#else +#define ENDIAN_SUFFIX "" +#endif + +#define LDSO_ARCH "microblaze" ENDIAN_SUFFIX #define IS_COPY(x) ((x)==R_MICROBLAZE_COPY) #define IS_PLT(x) ((x)==R_MICROBLAZE_JUMP_SLOT) diff --git a/arch/mips/reloc.h b/arch/mips/reloc.h index f5e9c77b..4c035f32 100644 --- a/arch/mips/reloc.h +++ b/arch/mips/reloc.h @@ -1,7 +1,14 @@ #include <string.h> #include <elf.h> +#include <endian.h> -#define ETC_LDSO_PATH "/etc/ld-musl-mips.path" +#if __BYTE_ORDER == __LITTLE_ENDIAN +#define ENDIAN_SUFFIX "el" +#else +#define ENDIAN_SUFFIX "" +#endif + +#define LDSO_ARCH "mips" ENDIAN_SUFFIX #define IS_COPY(x) ((x)==R_MIPS_COPY) #define IS_PLT(x) 1 diff --git a/arch/powerpc/reloc.h b/arch/powerpc/reloc.h index 113dfa15..80b9ebc9 100644 --- a/arch/powerpc/reloc.h +++ b/arch/powerpc/reloc.h @@ -1,7 +1,7 @@ #include <string.h> #include <elf.h> -#define ETC_LDSO_PATH "/etc/ld-musl-powerpc.path" +#define LDSO_ARCH "powerpc" ENDIAN_SUFFIX #define IS_COPY(x) ((x)==R_PPC_COPY) #define IS_PLT(x) ((x)==R_PPC_JMP_SLOT) diff --git a/arch/x86_64/reloc.h b/arch/x86_64/reloc.h index 38a60735..28cf7cc1 100644 --- a/arch/x86_64/reloc.h +++ b/arch/x86_64/reloc.h @@ -2,7 +2,7 @@ #include <string.h> #include <elf.h> -#define ETC_LDSO_PATH "/etc/ld-musl-x86_64.path" +#define LDSO_ARCH "x86_64" #define IS_COPY(x) ((x)==R_X86_64_COPY) #define IS_PLT(x) ((x)==R_X86_64_JUMP_SLOT) |