...
Java: Create a nativ method
C++: Create a matching implementation
Store the C++ implementation inside a shared library
Compile the shared library with CMake
Load the shared library with System.LoadLibrary()
Call the JNI method
Note: When a Java native method is called before the implementation is loaded it leads to a crash!
...