Re: Jogl Build Headache
Posted by
Wade Walker on
Dec 05, 2013; 8:47pm
URL: https://forum.jogamp.org/Jogl-Build-Headache-tp4030758p4030787.html
Penny wrote
So my goal is to get jogl to compile only using javac.
At the source code I will HACK and HACK and HACK and HACK until it compiles :)
I'm not sure this can work, because the source code for JOGL is more than just Java code. The build process invokes gluegen to convert the OpenGL header files to Java interfaces. Then it uses javah to convert those interfaces to C header and stub source files. Then those C files are compiled with gcc so JOGL can call OpenGL via JNI. Then finally the pure Java source can be compiled with javac at the end of the process.
This process could be reduced if we used JNA, but that didn't exist when JOGL started years ago, and I've heard it's slower than JNI (I don't have personal experience of this, though). But if you wanted, you could convert JOGL to use JNA and see how it performs :)
So as gouessej says, if there were an easier way, we would do it -- within current constraints, this is about as easy as it gets. Just about any large project has some non-trivial build process that's not so easy to just replace with an alternative.