This is the short instructions to show you how to build the entire exo portal with maven2 1. For simplicity, we suggest you to have the following directory structure ${exo.directory.base}/ eclipse/ projects/ v2.x exo-dependencies/ tomcat-5.0.28 jboss-4.0.3SP1 JONAS_4_7_4 maven2/ 2. The thirdparty tools and dependencies Download the maven 2 and install it in the $exo.directory.base as shown above. Make sure you add the $M2_HOME dir to your executable $PATH so you can run the command mvn or m2 from any directory. (YOU NEED TO USER MAVEN VERSION 2.0.1 OR HIGHER). If you deploy eXo in Tomcat, then download version 5.0.28 and install in $exo.directory.base/exo-dependencies/tomcat-$version. You need to remove all jar files from tomcat/common/endorsed as those xml jar files contain older code than the code in jdk1.5. You can remove the unused webapp such jsp-servlets, servlet-examples ... in tomcat/webapps so your tomcat will launch faster and consume less memory. If you deploy eXo in jboss, then download version 4.0.3SP1 and install it in $exo.directory.base/exo-dependencies/jboss-$version. You need to remove all jar files from jboss/lib/endorsed dir as those xml jar files contain older code than the code in jdk1.5. If you deploy eXo in JOnAS, then download version 4.7.4 (http://jonas.objectweb.org) and install it in $exo.directory.base/exo-dependencies/JONAS_$version. You need to remove xml-apis.jar file from JONAS_$version/lib/endorsed/ as this xml jar file contains older code than the code in jdk1.5. 3. Check out or download exo src Download exo src and extract it into $exo.directory.base/projects/v2.x OR Checkout code from the svn with the command svn checkout svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x or at $exo.directory.base/projects/v2.x do following commands: svn checkout exo-tools svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-tools svn checkout exo-platform svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-platform svn checkout exo-portal svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-portlet-container svn checkout exo-portal svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-portal svn checkout exo-test svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-test svn checkout exo-test svn://svn.forge.objectweb.org/svnroot/exoplatform/v2.x/exo-sso Make sure you run the command in $exo.directory.base/projects/ in order to have the above directory structure. 4. Install and configure maven and maven exo plugin Copy the v2.x/exo-tools/build/config/settings.xml to your $HOME/.m2/settings.xml. Open it and adjust the $exo.directory.base and tomcat version according to your environment. Go to exo-tools/maven2/plugins/exo and run the command mvn install, this command will add the exo plugin to maven plugin repository 5. Compile and install the projects In each exo-module run mvn clean install to compile and install the sub projects to your local maven repository If you build one module before building the dependant modules. The missing exo modules will be downloaded from maven.objectweb.org/maven2 For example ----- cd v2.x/exo-platform mvn clean install ----- If you want to build all the modules in one shot , you need to copy the exo-tools/build/config/modules.xml to v2.x , open modules.xml file and include the modules that you want to build and run the command mvn -f modules.xml clean install This command will compile, package and copy all the module package to the $M2_REPO. If you want to build the exo portal product only, you can open the modules.xml file and remove some modules such exo-jcr, exo-ecm... 6. Build the product You need to compile and install the projects before doing the following instructions. To build a product with the default server , tomcat in this case, you need to have an product-exo-*.xml. You can find those file in exo-portal/, exo-ecm, ..... mvn -f product-exo-portal.xml -Dclean deploy OR mvn -f product-exo-ecm.xml -Dclean deploy To build the product with jboss mvn -Pjboss-server -f product-exo-portal.xml -Dclean deploy OR mvn -Pjboss-server -f product-exo-ecm.xml -Dclean deploy To build the product with JOnAS mvn -Pjonas-server -f product-exo-portal.xml -Dclean deploy OR mvn -Pjonas-server -f product-exo-ecm.xml -Dclean deploy The available options are : -f The maven configuration file that specify which modules should be deployed to the application server. For example: -f product-exo-portal.xml, -f product-exo-ecm.xml -Dclean Delete the server in the working directory and copy a clean server from exo-dependencies directory -P The profile environment. By default the maven exo plugin will use the tomcat server for deployment. If you want to deploy the exo product to jboss or JOnAS, add -Pjboss-server or -Pjonas-server eXo Maven Plugin design and configuration Design: To faciliate the build and deploy process, exo team has developed a maven plugin to package and deploy the exo-war, exo-portlet , exo-portal, and exo-product module type. The plugin use the chain command pattern so the new developer or the third party can easily reconfigure or add more command to the execution chain. The maven exo plugin also support the groovy script so you can insert some groovy script into the command chain Configure: Currently all the packaging and deploying configuration are in the parent v2.x/pom.xml. All the exo modules that extend from the v2.x/pom.xml will inherit the configuration of this pom. For the particular module you can reconfigure the maven-exo-plugin and override the default configuration in the parent pom. To change the packaging configration, open v2.x/pom.xml and look for the maven-exo-plugin configuration. Here is a sample of the packaging configuration for the exo-portal module that you should find in the v2.x/pom.xml ${exo.directory.base}/...../share-portal ${project.build.finalName} ${basedir}/target To change the deploy configration, open v2.x/pom.xml and look for the maven-exo-plugin configuration. Here is a sample of tomcat server deploy configuration that you should find in the v2.x/pom.xml tomcat-server ${exo.directory.base}/projects/v2.x/exo-tools/server/tomcat ${exo.directory.working}/exo-tomcat ${exo.directory.working}/exo-tomcat/common/lib ${exo.directory.working}/exo-tomcat/webapps ${exo.directory.dependencies}/${exo.server.tomcat} ${dep} ${clean} ${resource} ${exclude.projects}, commons-collections If you want to define a new module type and use the exo packaging or deploying plugin. You need to open exo-tools/maven2/plugin/exo/src/java/META-INF/plexus/components.xml and define a new lifecycle configuration for your new module type. For Developers In short , To build and deploy portal successfully , you need to intall maven plugin, build all the exo modules and install them in the M2_REPO directory. Then deploy the portal modules to a server, the server can be tomcat or jboss or JOnAS. You can build a single module or a set of modules by going to the module directory and run the command mvn clean install. cd $EXO_SRC_CODE/exo-platform && mvn clean install && cd $EXO_SRC_CODE/exo-portal && mvn clean install && cd $EXO_SRC_CODE/exo-test && mvn clean install && cd $EXO_SRC_CODE/ && mvn -Ptomcat-server -Dclean -f exo-portal-product.xml deploy If you are developing a module and using the exo maven build framework, you can run: mvn clean install exo:deploy The available options are: -Ddep=scope This option tell which dependencies of the module should be copied to the server Examplpe: -Ddep=all , -Ddep=compile, -Ddep=runtime