Skip to content

yappy/ajlua

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ajlua

Java and Android porting of native Lua

API reference

https://yappy.github.io/ajlua/

Lua reference manual

Official: https://www.lua.org/manual/5.3/

Unofficial Japanese: http://milkpot.sakura.ne.jp/lua/lua53_manual_ja.html

How to build

Java project

(Native part)

  1. Install CMake and C/C++ build tools. (make, gcc, g++, or clang, etc.)
  2. Create cmake build directory and cd to it. build/ will be ignored by git. e.g. $ mkdir build; cd build
  3. CMake configure the native/ dir in this repository. e.g. $ cmake ../native
  4. $ make install ($ make -j install to speed up)

(Native part test)

  1. $ ctest after make.
  2. $ ctest -V for more datailed results.

(Java part)

  1. Install JDK 8 or later.
  2. Build tool is Gradle but it will be automatically downloaded by gradlew command. Of course you can use your own Gradle installed.
  3. cd to /java dir in this repository.
  4. $ ./gradlew app to start a sample application. (GUI needed)

(Java part test)

  1. $ ./gradlew test to test the native and java library. If failed, check the native build and install results.

Android project

  1. Install Android Studio.
  2. Open SDK Manager and install CMake and NDK.
  3. Open an existing Android Studio project or File Open.
  4. Select /android dir in this repository.
  5. Make Make project.
  6. app dir is a sample application project. Run Run 'app' to run.