Perforce

Make sure that the p4 binary is in your path. You can download the Binary here for your platform. Knowledge of the Perforce development platform is strongly encouraged. You can find help documentation here

Settings

export P4EDITOR=vi
export P4PORT=codes.zimbra.com:2666
export BUILD_HOME="/home/public/p4/zcs" (Does not seem to work, all code will go in /opt/zimbra-src unless you create a view)

Getting the Source

Perforce uses relative paths to figure out what you want (unless specified). For example, the BUILD_HOME is /home/public/zcs. That location (zcs) is considered the root of the depot/public cache. To get the "main" sources, run:

Syncing updates all of your local source files to match the files on the server. These files update regularly. If, for some reason, P4 is telling you the source is up to date, but you know it's not, then you can force a sync by running:

Setting Up & Building Third Party

If this is a new platform, edit ZimbraBuild/rpmconf/Build/get_plat_tag.sh and add the appropriate function to add a new tag for your platform.

Edit the Makefiles in the ThirdParty/* directories as appropriate for build options for your new platform.
If your platform already includes pcre, popt, and expat, make sure to add the appropriate lines so that building those pieces of software gets skipped.

If you have added a platform tag to get_plat_tag.sh, update the buildThirdParty.sh script appropriately for setting the Perl library paths.

Configuring and Installing Java (JDK)

JDK 1.5 Is required to install and build/compile Zimbra Collaboration Suite. Zimbra will build 1.6 for ZCS 5.0, but it must be compiled with JDK 1.5. You can download the latest version of JDK free from Sun here: http://java.sun.com/javase/downloads/index_jdk5.jsp

Once you have downloaded and extracted JDK, move the java installation to the correct location and make a symlink:

Configuring Postfix

Create a user account "postfix" with a user id and group id that are not used by any other user account. Preferably, this is an account that no-one can log into. The account does not need an executable login shell, and needs no existing home directory. Password and group file entries look like this:

/etc/passwd:
postfix:*:12345:12345:postfix:/no/where:/no/shell

/etc/group:
postfix:*:12345:

Create a group "postdrop" with a group id that is not used by any other user account. Not even by the postfix user account. The group file entry should look like:

/etc/group:
postdrop:*:54321:

Setting up Perl

By default, the CPAN mirror that Zimbra will use to build is depot.zimbra.com. This is an internal server which is not accessible to the general public. If unchanged, Perl will fail to build during the build process, and must be corrected before continuing.