Here are the steps that are required in order to build the Jogl
OpenGL binding from a fresh copy of the source distribution:
Install Ant: Download and unpack Ant 1.6.1 or later from http://ant.apache.org and add the bin/ subdirectory to your PATH environment variable. (Later versions of Ant should work; 1.6.2 has been tested successfully.)
Install ANTLR: Download and unpack ANTLR 2.7.2 from http://www.antlr.org. (Later versions of ANTLR should work; ANTLR 2.7.3 has been tested successfully.)
Unset your CLASSPATH environment variable: The Ant build requires that the Jogl jars not be visible on the classpath. On Unix, type unsetenv CLASSPATH into a csh or tcsh shell, or unset CLASSPATH into a Bourne shell. On Windows, type set CLASSPATH= into a command prompt.
Copy and edit jogl.properties:
On Windows and X11 platforms: Copy make/jogl.properties into your home directory (pointed to by the Java system property user.home).
On Mac OS X: Copy make/jogl.properties into the Library/Java subdirectory of your home directory (pointed to by the Java system property user.home).
Edit the copy to change any settings that are necessary, in particular the location of the ANTLR jar file (typically $HOME/antlr-2.7.2/antlr.jar).
Build the source tree: Open a command shell in the "make" directory of the source tree and type "ant [target]", where [target] is one of linux, macosx, solaris, win32.vc6, win32.vc7, or win32.mingw.
The win32 targets require one of Microsoft Visual C++ 6, 7 (Visual Studio .NET) or the free MinGW (http://www.mingw.org/) compilers to be installed. Choose the appropriate target for the compiler desired.
An experimental binding to the high-level Cg language by NVidia corporation can be generated by specifying -Djogl.cg=1 to ant; e.g. ant -Djogl.cg=1 win32.vc6. The Cg binding has been tested on Windows, Linux, and Mac OS X.
Add Jogl to your CLASSPATH: To be able to use Jogl once built, you must add the build process' resulting jogl.jar (
Note that there are a lot of warnings produced by ANTLR about the
C grammar and our modifications to some of the signatures of the
productions; the C grammar warnings have been documented by the
author of the grammar as having been investigated completely and
harmless, and the warnings about our modifications are also
harmless.
- Christopher Kline and Kenneth Russell, June 2003