Clearspace Source BuildThe Clearspace source code is available for licensees of the software. Clearspace is not Open Source software. Use of the source code is governed by the license you agreed to when you purchased the software. If you do not have a commercial or non-commercial license to the product, the Evaluation License applies. In no event can the source code be embedded into a separate application without an OEM license from Jive Software. Some of the source code in this package is Open Source software developed by third parties. Wherever this is the case, it is specifically noted in the source, and that source is governed by the license given to it by its author. The Clearspace source build can:
For additional developer resources, please visit: http://www.jivesoftware.com/developer/. The Jive Clearspace build process is based on Ant. There is no need to download and install Ant - a version of it is included in this distribution. This document includes the following sections:
Files in the Source DistributionYou'll find the following in your source distribution (sub-directories omitted for brevity): jive_clearspace_source_x_x_x/
|- build/
|- custom/
|- database/
|- jiveHome/
|- lib/
|- plugins/
|- resources/
|- README.html
|- source
|- target
|- webapp
Setting UpGetting your machine ready for Jive Clearspace development requires a few steps. Wherever possible, instructions are provided for both Unix/Linux and Windows users. Minimal Requirements
Pre-Compile TasksSet $JAVA_HOMEUNIX/Linux
WindowsNT/2000/XP
Set $ANT_OPTS
Testing Your Build Scripts
Additional Build TargetsThe list of ant targets is below. All build commands should be run from the "build" directory of your Clearspace distribution. You might also want to edit the build/build.xml file, where you can specify a number of build properties such as the directory that JAR files should be copied to after building. For a list of the commands and a brief description from the command line, type: ant -projecthelp To execute a build target, type ant options <targetname> where "targetname" is one of the targets listed below: Each task is documented with a syntax guide and description. Optional parameters for each task are also listed. If you would like to permanently set the value of a property, add it to build/build.xml file. allEquivalent of calling ant jar. Syntax ant all cleanCleans your Jive Clearspace distribution directory by deleting compiled class files, the clearspace-version.jar, clearspace.war files. If you specified alternate destination directories for any of those files, you'll need to delete them manually. Syntax ant clean compileCompiles all the Clearspace source code into <clearspace-distribution>/classes/ Syntax ant compile earCreates a deployable EAR from the clearspace.war file. Syntax ant ear initInitializes the build and creates the temp directory. Syntax ant init jar (default)Creates a JAR of Clearspace classes called clearspace-x.x.x.jar, where x.x.x is the distribution version number. Syntax ant jar jar-customCreates a JAR of custom code from the overlay/custom/ directory. This is a useful place to put your own integration code. By default the name of the JAR will be "custom.jar". To override this, pass in a "jarname" parameter. Syntax ant [-Djarname=<jar_name>] jar-custom Optional Parameters -Djarname=<jar_name> Example Creates foo.jar: ant \-Djarname=foo jar-custom libraries.prepareConverts a standard build of a library to one that can be bundled. Syntax ant libraries.prepare runnerBuilds a preconfigured Tomcat based Clearspace server in target folder, launch with 'target/start-clearspace'. Syntax ant runner warBundles the clearspace-1.0.0.jar, dependency jars, skins (FTL files) and config files into a single WAR for deployment. The WAR (clearspace.war, by default) is copied into the base directory of this distribution. You can specify a different name using the warname parameter. Syntax ant [-Dwarname=<war_name>] war Optional Parameters -Dwarname=<war_name> Example Creates foo.war: ant.sh \-Dwarname=foo war validateValidates a given XML file. The filename must be specified via the file parameter. Syntax ant -Dfile=file.xml validate |