Android.mk is like this.
Local_path: = $ (call My-dir) include $ (clear_vars) local_module : = lualocal_src_files: = lua.cppmy_files: = $ ( Wildcard $ (Local_path)/lua/*.c) My_files: = $ (my_files:$ (Local_path)/%=%) Local_src_files + = $ (my_files) # includes local_c_includes: = $ (local_path) Local_c_includes + = $ (Local_path)/lua/include $ (build_shared_library)
The source of Lua is in the Jni/lua directory, deleting LUA.C and LUAC.C
Execute Ndk-build, will error:
Llex.c:237:18:error: ' struct Lconv ' has no member named ' Decimal_point '
Check the next, is to define the decimal character, the comment out, directly define it:
#if!defined (l_getlocaledecpoint)//#define L_GETLOCALEDECPOINT () (Localeconv ()->decimal_point[0])//# Endif#define l_getlocaledecpoint () '. '
There is a LIOLIB.C also changed, so that the compilation succeeded.
I'm using a lua5.3.
I'll learn about Lua.
Compiling LUA library with NDK