In linux
file1.s:
.text
.globl MyFunc
Func:
....
call my_jump
ret
file2.h:
extern "C" FUNC_NO_RETURN void my_jump();
file3.cpp:
extern "C" __attribute__((noinline)) void my_jump()
{
return;
}
when linking my module that calls "MyFunc", I get the following error: (earlier, before adding the call to my_jump inside the asm code, everything was fine)
"relocation R_X86_64_PC32 against 'longjmp_hack' can not be used when making a shared object; recompile with -fPIC"
any ideas?
source
share