mirror of
https://github.com/LuaJIT/LuaJIT.git
synced 2025-02-08 15:34:09 +00:00
Fixed jit (bytecode save) elf header flags for mips when run on host with different endianness
This commit is contained in:
parent
fb61f7cbe3
commit
ec56a4b355
@ -239,7 +239,7 @@ typedef struct {
|
|||||||
hdr.type = f16(1)
|
hdr.type = f16(1)
|
||||||
hdr.machine = f16(({ x86=3, x64=62, arm=40, ppc=20, ppcspe=20, mips=8, mipsel=8 })[ctx.arch])
|
hdr.machine = f16(({ x86=3, x64=62, arm=40, ppc=20, ppcspe=20, mips=8, mipsel=8 })[ctx.arch])
|
||||||
if ctx.arch == "mips" or ctx.arch == "mipsel" then
|
if ctx.arch == "mips" or ctx.arch == "mipsel" then
|
||||||
hdr.flags = 0x50001006
|
hdr.flags = f32(0x50001006) -- EF_MIPS_ARCH_32|E_MIPS_ABI_O32|EF_MIPS_CPIC|EF_MIPS_PIC
|
||||||
end
|
end
|
||||||
hdr.version = f32(1)
|
hdr.version = f32(1)
|
||||||
hdr.shofs = fofs(ffi.offsetof(o, "sect"))
|
hdr.shofs = fofs(ffi.offsetof(o, "sect"))
|
||||||
|
Loading…
Reference in New Issue
Block a user