Building from Subversion

JGUIraffe uses Apache Maven as its build tool. When you check out the source code from Subversion using the command

svn co https://jguiraffe.svn.sourceforge.net/svnroot/jguiraffe/trunk jguiraffe
    

you get a maven aggregator project with the following modules:

  • core is the actual library. The jar file created when building this project is the one which needs to be present in the class path of your application.
  • examples contains some sample code and also the complete tutorial application.

For convenience the top-level directory contains a pom.xml for building the whole project including all its modules. Just execute the following command in this directory:

mvn clean install
    

This requires a JDK 1.6 because the examples module uses some 1.6 features. The core is compatible with JDK 1.5. It can be built with a 1.5 compiler by issuing the same command in the core subdirectory. The resulting jar file containing all classes of the JGUIraffe library can be found in the core/target folder.

Note: If you get an OutOfMemoryError, you have to increase the heap size for the Maven build. This can be achieved by setting the MAVEN_OPTS environment variable correspondingly, e.g. MAVEN_OPTS=-Xmx256m would increase the size of the heap space to 256 M.

The pom defines a profile named release which creates some additional artifacts. If it is activated, jars with Javadocs and the project's sources are produced. These jars can be integrated in typical IDEs. To activate this profile and generate the additional artifacts enter the following command (either in the top-level or in the core directory):

mvn clean install -P release