Building Apache Directory Studio (Maven)

Warning: Work in progress

This page is not complete yet.

All projects use maven as default build tool. As of ??? we use Maven 2.0.7 on JDK 1.5.

First you have to download the source code from the repository. Subversion is used for version control, so you can use the subversion client to download up to date source code. Here are the steps to have a running Apache Directory Studio from scratch:

To check out the active development branch of Apache Directory Studio and all co-projects run the following command:

svn co https://svn.apache.org/repos/asf/directory/studio/trunk studio

Now, change to studio:

cd studio

Run the following command to build all of the projects:

mvn clean install

If the build hangs or you get an out of memory exception please increase the heap space:

  • For Linux:
    MAVEN_OPTS="-Xmx256m" mvn clean install
    
  • For Windows:
    SET MAVEN_OPTS="-Xmx256m"
    mvn clean install
    

By default a distribution for your current working OS is build. You can add additional distributions by adding the corresponding profile of it:

OS

os.family

os.arch

maven profile to use

Mac OSX (Mac/Carbon)

mac

i386

-Pmacosx

Windows

windows

x86

-Pwin32

Linux (PPC/GTK 2)

unix

ppc

-Plinux-ppc

Linux (x86/GTK 2)

unix

i386

-Plinux-x86

Linux (x86_64/GTK 2)

unix

amd64

-Plinux-x86_64

 

Warning: Work in progress

  • Windows amd64 (e.g. Vista) is only supported for SDK/RCP >= 3.4
  • Any other combinations of OS/Platform supported?

After the command ends running successfully you'll have all the projects compiled and the distribution(s) of Apache Directory Studio application generated in the directory target/distributions.
To run the application, double-click on it.

To build the user documentation in HTML and PDF, run the following command:

mvn install -Puserguides

Generating PDF requires much memory. If you get an out of memory exception please increase the heap memory:

  • For Linux:
    MAVEN_OPTS="-Xmx256M" mvn install -Puserguides
    
  • For Windows:
    SET MAVEN_OPTS="-Xmx256M"
    mvn install -Puserguides
    

After the command ends running successfully you'll have all the user documentation generated in the directory target/userguides.

To clean the project's directory, run the following command:

mvn clean

If you have problems building the projects please try to clean your local maven2 repository:

  • For Linux:
    rm -rf ~/.m2/repository
    
  • For Windows: Delete the folder C:\Documents and Settings\<your username>\.m2\repository

Note: Each sub-project can also be built separately. To do so, enter the project directory and run the mvn install command. This will compile and generate the plugin in the target directory
Note 2: Apache Directory Studio can be built on Linux, Mac OS X and Windows. It has been run successfully on Linux Ubuntu Dapper Drake, Gentoo Linux (i386/amd64), Mac OS X 10.4.9 and Windows XP Pro.

  • No labels