Building Cayenne has been edited by Andrus Adamchik (Jan 17, 2007).

(View changes)

Content:

Prepare

  • Download Maven2.
  • Check out the repository trunk (or another appropriate location). E.g.:
    svn co https://svn.apache.org/repos/asf/incubator/cayenne/main/trunk/ cayenne


Build all modules

cd cayenne && mvn install

FirstTime Bootstrap

When building for the first time (with clean local repo), you must bootstrap the repository by executing the command above. On subsequent runs, you can use other maven commands like "clean", and/or build modules one by one.

Building Platform Specific Artifacts

To create CayenneModeler artifacts specific to Mac or Windows, use corresponding profiles (they only work on the machine that runs the target OS):

mvn -P mac install
mvn -P windows install

Windows Woes

Full tree build may fail on Windows if the Maven2 repository directory contains spaces, which it does by default ("C:\Documents and Settings\user\.m2"). This is a bug in Maven. Until it is fixed, the workaround is to relocate a repository to a directory with no spaces, e.g. "C:\.m2". This can be done by entering the new location in the settings.xml itself located in the default directory:

C:\Documents and Settings\user\.m2\settings.xml
<settings>
   <localRepository>c:\.m2</localRepository>
</settings>

Build assemblies

A generic assembly is built like this:

cd cayenne/assembly && mvn clean package

A Windows assembly is built like this:

cd cayenne/assembly && mvn -P windows clean package

A Mac assembly is built with a shell script as Maven does not have a plugin to create a .dmg:

cd cayenne/assembly && ./build-mac.sh

Refresh Documentation from Wiki

To rebuild the docs from Confluence Wiki, a build must be done with "wiki-docs" profile activated:

# cd cayenne/doc 
# mvn -P wiki-docs clean install -Dconfluence.userName=username -Dconfluence.password=password
# svn ci -m "docs updated"

Reply via email to