Building Myfaces
Myfaces is built using the Maven software project management tool. Follow these instructions to build Myfaces from source on your machine. If you just want a binary distribution, one can be downloaded from
http://myfaces.apache.org/download.html.
Prerequisites
To build Myfaces, you'll need the software listed below installed on your machine.
JDK 1.4
Maven 2.0.1 (or later) (
http://maven.apache.org/download.html), with the bin directory in your path. Make sure to set JAVA_HOME as an environment variable. Subversion client for your build environment (
http://subversion.tigris.org/)
Running a Myfaces build
svn co https://svn.apache.org/repos/asf/myfaces/current myfaces-current cd myfaces-current mvn install
You may need to run the 'mvn' command multiple times when you're first starting out, as it downloads plugins and the download process does not seem to be entirely reliable.
Use the setting -Dmaven.test.skip=true if you don't want tests to run.
Use the setting -Dmaven.test.failure.ignore=true if you don't want the build to stop if a test fails
The output will be put in the "target" folder of every subproject.
Building the documentation
To build the documentation site, execute:
cd myfaces-current/build mvn site
The documentation will be put in the target/site folder of every subproject.
For Tomahawk only
In most cases, it is best to build all the Tomahawk modules:
svn checkout http://svn.apache.org/repos/asf/myfaces/tomahawk/trunk tomahawk cd tomahawk mvn install
If you really want to build just Tomahawk core then you will need to manually add the apache snapshot repository to your settings file. The problem is that each tomahawk submodule needs access to its parent pom. That is no problem if the parent pom is in the parent directory (which happens if you check out the whole of tomahawk rather than just the core module). Otherwise maven can also retrieve it from the apache snapshot repository - except that the definition for the apache snapshot repository location is in an ancestor pom that is referenced only from the parent pom!
To enable the apache snapshot repostory, edit file ~/.m2/settings.xml and add the following:
<profiles>
<profile>
<id>mydefs</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>apache.snapshots</id>
<name>Apache Snapshot Repository</name>
<url>http://people.apache.org/repo/m2-snapshot-repository</url>
<releases>
<enabled>false</enabled>
</releases>
</repository>
</repositories>
</profile>
</profiles>
IDE support
See Building MyFaces in your IDE.