Documentation

##### WSO2 WSAS 2.2-RC1

- Release Notes
- Contents
- Home

##### Downloads

- Releases

##### Documentation

- User Guide
- FAQs
- Installation Guide
- Source
- Running Behind a Proxy
- Data Services Guide
  - RDBMS Data Source
  - CSV Data Source
  - Excel Data Source
  - JNDI Data Source
- EJB Guide
- Clustering Guide
- JMX Guide
- XKMS Guide
- Changing Keys

##### Samples

- Chad
- Commodity Quote
- Data Services
- Flickr
- Javascript
- Jaxws
- JiBX
- Mtom
- STS
- Trader
- Tiny URL
- Metadata Exchange
- WS-Transfer
- XML Key Managment Specification
- Cluster Management

##### API Documentation

- Java Docs

##### Tools

- Code Generation
- Change Password
- Eclipse IDE Integration
- TCP Monitor
- WSDL2Code
- WSDL View
- Try It
- AAR Validation
- MAR Validation

##### Resources

- News

##### Get Involved

- Mailing Lists
- Integration

##### Project Information

- Project Team
- Issue Tracking
- License

[Download] | [Documentation Home] | [Release Note]

# Source Distribution

This page of the installation guide explains how to build the WSO2 WSAS using the source distribution of the release.

## Introduction

WSO2 WSAS is available as a extractable binary or an installable package. The Installation Guide contain instructions on the installation of these distributions.)

For the more adventurous user, this release provides a source distribution so that they can build the WSO2 WSAS from the source.

Download WSO2 WSAS Source Distribution: wso2wsas-2.2-RC1-src.zip

## System Requirements

Java Runtime Environment | 1.4 or 1.5 (For instructions on setting up the JRE in different operating systems, visit http://java.sun.com)
Maven | 2.0.6 or higher (2.0.7 recommended) in Maven 2.x series (download). Please download maven 2.x version.
Operating System | Tested on Windows XP, Linux(Fedora core, Ubuntu and Gentoo), Mac OS X & Sun Solaris

## Setting Up the Environment and Tools

### Maven:

The WSO2 WSAS build is based on Maven. Hence, a prerequisite to build WSO2 WSAS from the source distribution is to have Maven and JDK installed. Extensive instructions are available on the Maven site.

This guide however contains the easiest path for quick environment setting. Advanced users can learn more about Maven.

- MS Windows

1. Download and run the Windows installer package
2. Set the 'Environment Variables' (create the system variable M2_HOME and edit the path. e.g., "set M2_HOME=C:\Program Files\Apache Software Foundation\maven-2.0.x"; set path=%path%;%M2_HOME%\bin)
3. Make sure that the system variable JAVA_HOME is set to the location of your JDK, e.g., C:\Program Files\Java\jdk1.5.0_02
4. Run 'mvn --version' to verify that it is correctly installed.

- Unix based OS (Linux etc)

The tar ball or the zip archive is the best option. Once the archive is downloaded, expand it to a directory of choice and set the environment variable M2_HOME and add M2_HOME/bin to the path as well. You can also refer to more instructions on how to install Maven in Unix based operating systems. Once Maven is properly installed, you can start building the WSO2 WSAS for Java.

## Building WSO2 WSAS from the Source Distribution

The source distribution is available as a zipped archive. All the necessary build scripts are included with the source distribution. Expand the source archive to a directory of your choice. You can run the following commands inside that directory to build the WSO2 WSAS. The list of commands that can be run are as follows: Note: The first time you run Maven, it will automatically download the dependent .jars. Therefore, the first run will take more time. The third party libraries required by WSO2 WSAS will be downloaded from the Maven2 repositories specified in the main pom.xml file.

mvn clean install | To create the complete release artifacts including the binary and source distributions.
mvn clean install -Dtest=false | To create the complete release artifacts including the binary and source distributions, without running any of the unit tests.
mvn clean install -Dtest=false -o | To create the complete release artifacts including the binary and source distributions, without running any of the unit tests, in offline mode.
mvn clean install site | Will also generate the project site and all the reports of the analysis tools integrated with WSAS such as Findbugs, Checkstyle etc. The index file will be generated in the target/site directory.

All the sources of the major 3rd party components included in WSO2 WSAS can be found in the third-party folder included in the source distribution. For the purpose of debugging applications, you could attach these sources.