|
Prerequisites
This is the third stage of three in the process of building ZCS for Solaris 10.
You MUST have gone through the first stage, Setup Build Environment. If you haven't go back and do it now!
You MUST have gone through the second stage, Build ThirdParty. If you haven't go back and do it now!
Insert Download files into Source tree
OK, so there a bunch of windows .exe/.msi files that are included with ZCS. NE has more, but OSS has several. It's far outside the scope of this tutorial, and any sane unix build to include building these windows binaries from scratch. It would be helpful/sensible/sane for Zimbra to include these in the source tree but they don't for now, so instead we download precompiled binaries from a running zimbra installation:
cd /opt/zimbra/jetty/webapps/zimbra/downloads; tar cf /tmp/downloads.tar *; cd -
scp /tmp/downloads.tar <our build server>:/tmp
Back on our build server:
cd /opt/build.server/source/FRANKLIN/ZimbraServer/src/windows
tar xf /tmp/downloads.tar
Preflight Checks
Environment:
Make sure you are picking up the correct versions of Java and Ant in your path, by doing:
java -version
ant -versionThe java version should be 1.5.x, the ant version should be 1.7.x.
Make sure that the ThirdParty binary packages produced in the ThirdParty phase are present:
ls -lR $BUILD_HOME/$RELEASE/ThirdPartyBuilds/<platform>
Start building main codebase
cd $BUILD_HOME/$RELEASE
./buildZimbra.sh That's it! This should produce an installer .tgz in ZimbraBuild/<arch>. If you get problems, you can build individual components seperately, detailed below.
General Tips
Rebuilding the entire codebase after a problem is time consuming. You can build invidual components and the final packing stage seperately which greatly reduces the time needed to fix/alter code and test.
./buildZimbra.sh <component>Where <component> is:
core
proxy
mta
store
ldap
snmp
logger
apache
spell
zcs_stage
zcs_stage is the final build stage that collects the built packages, forms the installer package framework and wraps it into a single compressed tarball.
If you find your changes aren't making it through to the end build, try clearing out the build directories. These are named ZimbraBuild/<component>build, ie. ZimbraBuild/corebuild.
This is particularly important for ZimbraServer, if ZimbraServer/build exists it is rarely updated from ZimbraServer/src. If you make any updates to ZimbraServer/src, be sure to mirror the change in ZimbraServer/build, or else remove this directory before rebuilding core.
|
|