ReferencePlatforms/Linux

From MozillaWiki
Jump to navigation Jump to search

This is a procedure I'm using to create a potential VM for producing Linux nightlies for Gecko 1.9.

Install CentOS4.3 from CDs

For the moment, I'm using "bsmedberg" as the regular user. If we are going to provide a public download of the VM, we probably shouldn't use the standard cltbld account/password. I'm not sure how that should work security-wise.

Choose the development workstation installation set.

Update CentOS

preed needs to fill this in further: do we want to update to some particular set of packages? In any case, binutils needs to be updated to 2.15.92.0.2 or later. "yum update binutils" worked for me.

Fix some permissions, create /builds directory

Save the following file as ~/.bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
    . ~/.bashrc
fi

# User specific environment and startup programs
PATH=$PATH:$HOME/bin

export PATH
export CVS_RSH=ssh
export JAVA_HOME=/builds/jdk1.5.0_08

Fix some permissions, and create a /builds directory.

su -
chmod a+x /etc/bashrc
groupadd builders
usermod -a -G builders bsmedberg
mkdir /builds
chgrp builders /builds

Logout/login to pick up new group setting

Install Sun Java JDK

Note: we should archive this binary somewhere

cd /builds
./jdk-1_5_0_08-linux-i586.bin
# type 'yes' to accept the license

Make GCC 4.1 (redhat branch)

mkdir /builds/gcc-redhat
cd /builds/gcc-redhat
curl http://redhat.download.fedoraproject.org/pub/fedora/linux/core/6/source/SRPMS/gcc-4.1.1-30.src.rpm > gcc-4.1.1-30.src.rpm
rpm2cpio gcc-4.1.1-30.src.rpm | cpio -i gcc-4.1.1-20061011.tar.bz2
tar -xjf gcc-4.1.1-20061011.tar.bz2

mkdir obj-release
cd obj-release
../gcc-4.1.1-20061011/configure --prefix=/builds/gcc-redhat/installed-release --enable-__cxa_atexit --enable-languages=c,c++ --with-system-zlib
make
make install

To build mozilla

The mozconfig for building mozilla should contain the following settings:

CC=/builds/gcc-redhat/installed-release/bin/gcc
CXX=/builds/gcc-redhat/installed-release/bin/g++

Dependencies

All RPMs below are from CentOS repo.

For GCC :

  • binutils-2.15.92.0.2-21.i386.rpm
  • bison-1.875c-2.i386.rpm
  • cpp-3.4.6-3.i386.rpm
  • flex-2.5.4a-33.i386.rpm
  • gcc-3.4.6-3.i386.rpm
  • gcc4-4.1.0-18.EL4.i386.rpm
  • gcc4-c++-4.1.0-18.EL4.i386.rpm
  • gcc-c++-3.4.6-3.i386.rpm
  • glibc-2.3.4-2.25.i386.rpm
  • glibc-common-2.3.4-2.25.i386.rpm
  • glibc-devel-2.3.4-2.25.i386.rpm
  • glibc-headers-2.3.4-2.25.i386.rpm
  • glibc-kernheaders-2.4-9.1.98.EL.i386.rpm
  • libgcc-3.4.6-3.i386.rpm
  • libgomp-4.1.0-18.EL4.i386.rpm
  • libstdc++-3.4.6-3.i386.rpm
  • libstdc++-devel-3.4.6-3.i386.rpm

For Mozilla:

  • atk-devel-1.8.0-2.i386.rpm
  • cvs-1.11.17-9.RHEL4.i386.rpm
  • fontconfig-devel-2.2.3-7.centos4.i386.rpm
  • freetype-2.1.9-4.el4.i386.rpm
  • freetype-devel-2.1.9-4.el4.i386.rpm
  • glib2-devel-2.4.7-1.i386.rpm
  • gtk2-2.4.13-19.i386.rpm
  • gtk2-devel-2.4.13-19.i386.rpm
  • libIDL-0.8.4-1.i386.rpm
  • libIDL-devel-0.8.4-1.i386.rpm
  • pango-devel-1.6.0-9.i386.rpm
  • pkgconfig-0.15.0-3.i386.rpm
  • xorg-x11-6.8.2-1.EL.13.37.i386.rpm
  • xorg-x11-devel-6.8.2-1.EL.13.37.i386.rpm
  • xorg-x11-libs-6.8.2-1.EL.13.37.i386.rpm
  • xorg-x11-xfs-6.8.2-1.EL.13.37.i386.rpm
  • zlib-devel-1.2.1.2-1.2.i386.rpm