Sunday, 15 September 2013

lua - Run Wax on 64-bit iOS with arm64 Architecture -



lua - Run Wax on 64-bit iOS with arm64 Architecture -

i stuck in problem many days.

wax(https://github.com/probablycorey/wax back upwards armv7 , armv7s architecture only, project uses arm64 architecture.

the error message "error opening wax scripts: loading wax stdlib: bad header in precompiled chunk".

so guess problem in wax_stdlib.h. file precompiled result of lua scripts in stdlib ducoment, , don't know how precompile lua scripts in 64-bit.

how can prepare it?

because project uses arm64 architecture,and wax_stdlib.h precompiled in 32bit...

so,you need precompile wax stdlib in 64bit.

first,you need download lua source code ,and cd src directory,and create in 64bit,and install

then should modifly luac.lua file

-- 64 b = string.sub(b, 1, x - 6 - 4).."\0"..string.sub(b, y + 2, y + 5) -- wtf do?

-- 32 -- b = string.sub(b, 1, x - 6).."\0"..string.sub(b, y + 2, y + 5) -- wtf do?

-- 64 assert(f:write(string.rep("\0", 3 * 8)))

-- 32 --assert(f:write(string.rep("\0", 12)))

and run compile-stdlib.sh...

if ,it can works,but suggest not utilize wax in 64bit,because don't back upwards 64bit..you find more problems

ios lua arm64 iphone-wax iphone-64bit

No comments:

Post a Comment