...
This guide is intended to cover how to build Geronimo 3.0 from the latest server/trunk
, though other newer branches should also follow similar instructions. Server trees that use the same basic build tooling include:
server/trunk
server/branches/1.2
server/branches/2.0
server/branches/2.1
server/branches/2.2
Prerequisites
and server/branches/3.0
. Refer to Building Apache Geronimo in the Development documents for more information on building Geronimo, including this and other branches.
Info |
---|
If you choose to build from |
Prerequisites
Build Machine
It is recommended that a dedicated computer used to build Geronimo 3.0 have a minimum of 2GB of real memory. The computer will also need a connection to the Internet to download artifact dependencies.
Java Developer Kit (JDK)
You will need a JDK 6.0+ (Java SE 1.6.0+) or compatible JDK to build Apache Geronimo. It is recommended you use SUN's implementation, or something compatible like Apples implementation. Other JDK vendors implementations may work, but use at your own risk.
Tip | ||
---|---|---|
| ||
Windows users should not double-quote JAVA_HOME (or MAVEN_HOME for the same reason), according to MAVEN-666. |
Apache Maven 2
To execute the build process you need to have Apache Maven version 2.2.1
(or newer) installed.
...
If you have an incompatible version the server build will probably fail with a message complaining
...
title | maven repository |
---|
...
...
...
<mirrors>
<mirror>
<id>java.net</id>
<name>Mirror of https://maven-repository.dev.java.net/nonav/repository/</name>
<url>http://download.java.net/maven/1/</url>
<mirrorOf>java.net</mirrorOf>
</mirror>
</mirrors>
...
Subversion
To fetch the source code for the server, you will need to have a Subversion client version 1.2 5 (or newer, 1.4 5 is recommended) installed.
Tip | |||||||
---|---|---|---|---|---|---|---|
| |||||||
Windows users are strongly encouraged to change the M2 local repository (the place where dependencies are downloaded) to a shorter path with no spaces, e.g. In order to change the m2 local repository go to
|
...
Tip | ||
---|---|---|
| ||
Windows users are strongly encouraged to checkout Geronimo into |
...
No Format |
---|
# Increase the heap and max permanent size for Maven if [ "x$MAVEN_OPTS" = "x" ]; then MAVEN_OPTS="-Xmx512mXmx1024m -XX:PermSize=256m -XX:MaxPermSize=128m=1024m -XX:ReservedCodeCacheSize=64m" fi |
Tip | ||
---|---|---|
| ||
Windows users should create Variables will need to use the batch set syntax:
|
...
In some cases you may need to build Geronimo in stages, such as when building OpenEJB from source to pick up local changes. Most users will not need to do this, but its documented here for clarity.
To build modules, testsupport configs and maven-plugins:
No Format |
---|
mvn install -Dstage=bootstrap |
To build appsplugins, configs, plugingroups and assemblies:
No Format |
---|
mvn install -Dstage=assemble |
...
No Format |
---|
mvn -Pdefault,makeeclipse |
Troubleshooting and Tips
- Use -DskipTests=true to turn off tests during server build.
- Use -o to avoid searching remote repository.
- Use -X to produce maven debug information.
- Build all Geronimo dependencies to avoid out-of-date code among projects such as openEJB, JSF and so on.