|
Building
GWTCOMP From the Sources
Content:
Pre-Requisite
Software
You will need the following software for building GWTCOMP:
- Java 2 Standard Edition SDK version 1.5 or above. You can
download the SDK from http://java.sun.com/javase/downloads
.
- Google Web Toolkit Version 2.0 or higher. It will not work
with GWT versions lower than 2.0. If you are using an earlier version
of GWT, please download the previous version. You can download GWT from
http://code.google.com/webtoolkit/
.
- You will need Maven 2.0 or higher. You can download ant
from http://maven.apache.org/.
- Optionally, download the Eclipse IDE from http://www.eclipse.org
and other associated plugins. If you are planning to make extensive
modification to the source, consider downloading the GWT plugin for Eclipse
from Google.
- You will need a SVN client if you want to check out the
code from the GWTCOMP Subversion repository. You can either use
command-line Subversion
client, TortoiseSVN
or the Eclipse plugin for Subversion - Subclipse.
Downloading and
Installing the Source Code
You can download the source code in two ways:
- Download the source distribution and unpack the source code
as explained here.
- Check out the source code from the CafeSip Subversion
repository.
Checking out
the code from the Subversion Repository
The subversion repository root for the GWTCOMP project is:
To check-out the latest and greatest code, use the following URL. Note
that the code may not be stable.
To check out last-known stable version, use the following URL:
To check out a released version, use the following URL:
https://cafesip.svn.sourceforge.net/svnroot/cafesip/gwt-components/labels/releases/rX.Y.Z
[Replace X.Y.Z with the actual release number].
Check out the
Code
Follow the steps below:
- Create a directory called "cafesip" under your home
directory or anywhere you choose.
$ mkdir cafesip
$ cd cafesip
- If you are going to use command line Subversion or
TortoiseSVN to check out the code, create a sub-directory called
gwt-components. You don't need to
execute this step if you are going to use the Eclipse SVN plugin -
Subsclipse (see below).
$ mkdir
gwt-components
- Next, depending on your development environment, follow one
of the
paths explained below.
If
you are not using Eclipse:
Using the SVN command line tool, checkout the code by running the
command:
$ svn co URL gwt-components
[Replace the URL with one of the above-mentioned URLs]
If you are not using the SVN command line tool but use TortoiseSVN, you
will need to do something similar from the Subversion menu.
If you are using Eclipse:
- Make sure you have the latest subclipse plugin installed.
You can get the plugin from http://subclipse.tigris.org/ .
- From the Eclipse IDE, select menu options Window->Show
View->Other.
- From the Show View dialog box, select the SVN folder
and select SVN Repository. An empty SVN repository panel will be
created and docked into the Eclipse screen.
- Select the SVN Repository panel, right click on the panel
to bring up the popup menu. Select New->Repository Location.
- From the repository dialog box, enter the URL -
https://cafesip.svn.sourceforge.net/svnroot/cafesip.
- Once the above step is completed, you will see the entire
CafeSip source tree on the panel. First select the GWTCOMP project and
either choose the trunk or one of the labels as explained above.
- Right-click on the directory you selected, from the context
menu, select the
Checkout option. The Eclipse IDE will contact the repository to gather
project information. We have included all the Eclipse project files
with the GWTCOMP source code so that the project can be setup easily.
- From the Checkout dialog box, select Next. Uncheck the "Use
default workspace location". Instead enter the location of the
directory where you created the cafesip directory above
($CAFESIP_HOME). click on the Finish button.
- The Eclipse IDE will download the source code and create
the project. Depending on your connection speed, the download time will
vary. Once the download is completed,
you will see the project on the Package Explorer panel.
Building the
Source
The root directory of the GWTCOMP project
($CAFESIP_HOME/gwt-components) contains the Maven build script -
pom.xml.
To build the source code and create the packages run the ant command as
shown below:
$ cd $CAFESIP_HOME/gwt-components
$ mvn clean install assembly:assembly
[the mvn executable must be
in your PATH and must have the JAVA_HOME
environment variable set properly]
The source code is built, installed on your local Maven repository and
the output zip file is placed target director
under the project root directory.
There are two child projects under the main Maven project. You can run
Maven commands on these projects instead of the full build explained
above.
- gwtcomp-components:
contains the components library project.
- gwtcomp-examples:
contains the example project which demonstrates how to use the
components. The output artifact from this project is a war file that
you can deploy in a Servlet container.
|