mirror of
git://git.musl-libc.org/musl
synced 2025-01-09 16:19:50 +00:00
4d3a162d00
building on commit 97d35a552e
,
__BYTE_ORDER is now available wherever alltypes.h is included. since
reloc.h is only used from src/internal/dynlink.h, it can be assumed
that __BYTE_ORDER is exposed. reloc.h is not permitted to be included
in other contexts, and generally, like most arch headers, lacks
inclusion guards that would allow such usage. the mips64 version
mistakenly included such guards; they are removed for consistency.
28 lines
796 B
C
28 lines
796 B
C
#if __BYTE_ORDER == __LITTLE_ENDIAN
|
|
#define ENDIAN_SUFFIX "el"
|
|
#else
|
|
#define ENDIAN_SUFFIX ""
|
|
#endif
|
|
|
|
#define LDSO_ARCH "microblaze" ENDIAN_SUFFIX
|
|
|
|
#define TPOFF_K 0
|
|
|
|
#define REL_SYMBOLIC R_MICROBLAZE_32
|
|
#define REL_GOT R_MICROBLAZE_GLOB_DAT
|
|
#define REL_PLT R_MICROBLAZE_JUMP_SLOT
|
|
#define REL_RELATIVE R_MICROBLAZE_REL
|
|
#define REL_COPY R_MICROBLAZE_COPY
|
|
#define REL_DTPMOD R_MICROBLAZE_TLSDTPMOD32
|
|
#define REL_DTPOFF R_MICROBLAZE_TLSDTPREL32
|
|
|
|
#define CRTJMP(pc,sp) __asm__ __volatile__( \
|
|
"addik r1,%1,0 ; bra %0" : : "r"(pc), "r"(sp) : "memory" )
|
|
|
|
#define GETFUNCSYM(fp, sym, got) __asm__ ( \
|
|
".hidden " #sym " \n" \
|
|
" mfs %0, rpc \n" \
|
|
" addik %0, %0, _GLOBAL_OFFSET_TABLE_+8 \n" \
|
|
" addik %0, %0, " #sym "@GOTOFF \n" \
|
|
: "=r"(*(fp)) : : "memory" )
|