forked from ariadne/libucontext
ppc64: chase API changes related to freestanding stuff
freestanding is however NOT supported herearm_linker_fix
parent
131e825f50
commit
da736b6add
2
Makefile
2
Makefile
|
@ -42,7 +42,7 @@ ${LIBUCONTEXT_STATIC_NAME}: ${LIBUCONTEXT_OBJ}
|
|||
$(AR) rcs ${LIBUCONTEXT_STATIC_NAME} ${LIBUCONTEXT_OBJ}
|
||||
|
||||
${LIBUCONTEXT_NAME}: ${LIBUCONTEXT_HEADERS} ${LIBUCONTEXT_OBJ}
|
||||
$(CC) -o ${LIBUCONTEXT_NAME} -Wl,-soname,${LIBUCONTEXT_SONAME} \
|
||||
$(CC) -fPIC -o ${LIBUCONTEXT_NAME} -Wl,-soname,${LIBUCONTEXT_SONAME} \
|
||||
-shared ${LIBUCONTEXT_OBJ} ${LDFLAGS}
|
||||
|
||||
${LIBUCONTEXT_SONAME}: ${LIBUCONTEXT_NAME}
|
||||
|
|
|
@ -62,4 +62,6 @@
|
|||
/* lnk register is actually %r36 */
|
||||
#define REG_LNK REG_R36
|
||||
|
||||
#include "common-defs.h"
|
||||
|
||||
#endif
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
*/
|
||||
|
||||
.global libucontext_getcontext
|
||||
.hidden libucontext_swapcontext
|
||||
.hidden __libucontext_swapcontext
|
||||
libucontext_getcontext:
|
||||
addis 2, 12, .TOC.-libucontext_getcontext@ha
|
||||
addi 2, 12, .TOC.-libucontext_getcontext@l
|
||||
|
@ -19,7 +19,7 @@ libucontext_getcontext:
|
|||
.localentry libucontext_getcontext,.-libucontext_getcontext
|
||||
|
||||
li 4, 0
|
||||
b libucontext_swapcontext
|
||||
b __libucontext_swapcontext
|
||||
|
||||
.weak getcontext
|
||||
getcontext = libucontext_getcontext
|
||||
|
|
|
@ -23,7 +23,7 @@ extern void libucontext_trampoline(void);
|
|||
|
||||
|
||||
void
|
||||
libucontext_makecontext(ucontext_t *ucp, void (*func)(), int argc, ...)
|
||||
libucontext_makecontext(libucontext_ucontext_t *ucp, void (*func)(), int argc, ...)
|
||||
{
|
||||
libucontext_greg_t *sp;
|
||||
va_list va;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
*/
|
||||
|
||||
.global libucontext_setcontext
|
||||
.hidden libucontext_swapcontext
|
||||
.hidden __libucontext_swapcontext
|
||||
libucontext_setcontext:
|
||||
addis 2, 12, .TOC.-libucontext_setcontext@ha
|
||||
addi 2, 12, .TOC.-libucontext_setcontext@l
|
||||
|
@ -20,7 +20,7 @@ libucontext_setcontext:
|
|||
|
||||
mr 4, 3
|
||||
li 3, 0
|
||||
b libucontext_swapcontext
|
||||
b __libucontext_swapcontext
|
||||
|
||||
.weak setcontext
|
||||
setcontext = libucontext_setcontext
|
||||
|
|
|
@ -10,12 +10,12 @@
|
|||
* from the use of this software.
|
||||
*/
|
||||
|
||||
.global libucontext_swapcontext
|
||||
libucontext_swapcontext:
|
||||
addis 2, 12, .TOC.-libucontext_swapcontext@ha
|
||||
addi 2, 12, .TOC.-libucontext_swapcontext@l
|
||||
.global __libucontext_swapcontext
|
||||
__libucontext_swapcontext:
|
||||
addis 2, 12, .TOC.-__libucontext_swapcontext@ha
|
||||
addi 2, 12, .TOC.-__libucontext_swapcontext@l
|
||||
|
||||
.localentry libucontext_swapcontext,.-libucontext_swapcontext
|
||||
.localentry __libucontext_swapcontext,.-__libucontext_swapcontext
|
||||
|
||||
li 0, 249 # SYS_swapcontext
|
||||
li 5, 1696 # sizeof(ucontext_t)
|
||||
|
@ -25,4 +25,7 @@ libucontext_swapcontext:
|
|||
b __retfromsyscall
|
||||
|
||||
.weak swapcontext
|
||||
swapcontext = libucontext_swapcontext
|
||||
swapcontext = __libucontext_swapcontext
|
||||
|
||||
.weak libucontext_swapcontext
|
||||
libucontext_swapcontext = __libucontext_swapcontext
|
||||
|
|
Loading…
Reference in New Issue