Skip to content
Brian Ferris edited this page Jul 19, 2011 · 34 revisions

Installation

Note: OpenTripPlanner is still very early in its development and is not yet ready for general use. These instructions are geared towards developers who want to check out the project.

Picking Your Development Environment

The OpenTripPlanner project uses Apache Maven to manage the project build environment. When it comes to working with the project and the code, you have a choice:

  • Most OTP developers use Eclipse for project development and we recommend you do the same. For setup instructions, see GettingStartedEclipse.

  • It's also possible to work with the project entirely from the Maven command line. For more details, see GettingStartedMaven.

While it's possible to work with the project entirely from the command-line (see GettingStartedMaven)

1. Project dependencies

OpenTripPlanner (OTP) is written in Java (version 1.6) and uses Maven for its build process and Subversion for version control. Before going forward, you should make sure you have both of these packages installed and working correctly. Instructions for installing Maven are available on its download page and for Subversion in the excellent Subversion Book.

OTP currently requires Processing, which is unfortunately not available in a public Maven repository. To get around this, you will need to manually add Processing's core.jar file to your local Maven repository and edit pom.xml, the Maven build configuration file. Specifically,

  1. Download Processing

  2. Locate core.jar (processing/lib/core.jar on Linux and Windows and Processing.app/Contents/Resources/Java/core.jar on Mac OS X) and install it into your local Maven repository:

mvn install:install-file -DgroupId=org.processing \

-DartifactId=processing-core \

-Dpackaging=jar \

-Dversion=1.0.7 \

-Dfile=core.jar

Note that the above is all one command. You may need to replace core.jar and/or the version number (in this example, 1.0.7) to reflect the correct path to core.jar and the version of Processing you downloaded.

After running the above, you should see many lines of output, one of which should say "BUILD SUCCESSFUL." If the build fails, you probably didn't supply the correct path for core.jar; double-check that it's correct and try again.

We'll edit pom.xml in the next section to use the version of Processing you just installed.

2. Getting the code and building

Check out the OTP source and change into the routing engine's directory:

svn co https://svn.opentripplanner.org/trunk opentripplanner

cd opentripplanner/jags

Next use your favorite text editor to edit pom.xml and add the following in the dependencies section (i.e., between <dependencies> and </dependencies>), modifying the version number as necessary:

org.processing

processing-core

1.0.7

Finally, run the tests to make sure everything builds correctly and all the tests pass:

mvn test

Clone this wiki locally