Chapter 2. Set up

Table of Contents

1. Requirements
1.1. JDK 1.6.0, JDK 1.5.0 or JDK 1.4.2
1.2. Jikes 1.22 or Jikes 1.21
1.3. Ant 1.7.0
1.4. Subversion (optional)
2. Creating the Extension Environment
3. Configuring the Environment
3.1. Advanced customization of the environment
4. Installing the Application Server
5. Upgrading the Environment

1. Requirements

The following instructions will help you get your development environment ready for working with the source code. These instructions are specific to setting up for deployment to Orion server and Tomcat 5.5 developing with Java JDK 1.5. Liferay Portal is also compatible with Java 1.4 and a wide array of application servers and containers. You will need to adjust your development environment according to your platform.

Before we can get started, the following components must be installed on your machine.

1.1. JDK 1.6.0, JDK 1.5.0 or JDK 1.4.2

  1. Download and install JDK 1.6.0 or JDK 1.5.0. JDK 1.4 is also supported.

  2. Set an environment variable called JAVA_HOME to point to your JDK directory.

1.2. Jikes 1.22 or Jikes 1.21

Jikes is a Java compiler by IBM that is much faster than the original one provided by the JDK.

  1. Download and unzip Jikes 1.22. If using JDK 1.4 you have to use Jikes 1.21 instead.

  2. Set an environment variable called JIKES_HOME to point to your Jikes directory.

  3. Add JIKES_HOME\bin to your PATH environment variable.

1.3. Ant 1.7.0

  1. Download and unzip the latest version of Ant.

  2. Set an environment variable called ANT_HOME to point to your Ant directory.

  3. Add ANT_HOME\bin to your PATH environment variable.

  4. Learn how tasks work in Ant. Tasks can be run at the root of the project directory and inside each subproject directory.

1.4. Subversion (optional)

If you expect to base your extensions on top of the latest sources of Liferay Portal (instead of using an stable release) or you plan to use subversion to maintain your own code you will need a subversion client. Follow these instructions to set it up:

  1. Download and install Subversion and/or a subversion client such as SmartSVN, TortoiseSVN or those provided by IDE environments.

  2. If you want to browse the source tree, configure the client to use the https protocol to connect to svn.sourceforge.net. Authenticate as user anonymous with a blank password and specify /svnroot/lportal/portal as the UNIX path.

    If you are a developer with privileges to commit to the source tree, configure the svn client to use the https protocol to connect to svn.sourceforge.net. Authenticate with your private user and password and specify /svnroot/lportal/portal as the UNIX path.

  3. Check out the portal.