Main steps
Install GNU C compiler:
Compile JNIClass.java file considering classpath and target location:
Generate jtm_extra12_JNIClass.h file in lib folder:
This file will be located in lib folder of the project.
Implement generated interfaces from lib/jtm_extra12_JNIClass.h file in /src/main/c/jnifunctions.c file:
Compile jnifunctions.c file including JNI libraries for 64-bit Linux:
Make shared library for Linux:
Test application by calling its main() method:
You can compile jnifunctions.c as independent executable with following parameters:
Then execute created binary by: