What are the alternatives to JNI


This Content is from Stack Overflow. Question asked by Tim Korelov

I am creating a Java project with Java OpenGL that I want to use a native library with.
The native library that I want to include is GNU MPFR https://mpfr.loria.fr (C library for multiple-precision floating-point computations).

One way to do this would be building JNI library with Maven, but as I’ve written in my other post on SO, Can’t build maven project, hawtjni-maven-plugin:1.18:build uses vcbuild (outdated, from VS 2008)
, this appears not viable.

Thus, as a person suggested in the comments, I could use some other tools to build native libraries into .JAR, and that I should post another question.

So here it is, and I ask you if you know some reliable tools, alternative to JNI, for this purpose (and, preferably, the ones you have experience with).


This question is not yet answered, be the first one who answer using the comment. Later the confirmed answer will be published as the solution.

This Question and Answer are collected from stackoverflow and tested by JTuto community, is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?