#! /bin/bash
boxName=$1
echo
echo "Init script for $boxName"
if [ "$boxName" == "lucid" ]
then
echo "Additional Python-Repository"
# needed for add-appt-repository
apt-get -y install python-software-properties
add-apt-repository ppa:mercurial-ppa/releases
fi
apt-get update -y
echo "Installing additional packages"
apt-get -y install mercurial
apt-get -y install bison
apt-get -y install flex
apt-get -y install g++
apt-get -y install make
#apt-get -y install python-dev
apt-get -y install ccache
# test scripts with different shells
apt-get -y install csh
apt-get -y install tcsh
apt-get -y install zsh
# this is needed for the packaging stuff
echo "Setting for postfix"
# Make sure that default-mta installs
debconf-set-selections <<< "postfix postfix/mailname string vagrant.test.machine.com"
debconf-set-selections <<< "postfix postfix/myhostname string vagrant.test.machine.com"
debconf-set-selections <<< "postfix postfix/main_mailer_type string 'Internet Site'"
debconf-set-selections <<< "postfix postfix/destinations string localhost"
# this workaround doesn't work for lucid
export DEBIAN_FRONTEND=noninteractive
echo "Tools for packaging"
# Needed for packaging
apt-get -y install default-mta
apt-get -y install dpkg-dev
apt-get -y install debhelper devscripts cdbs
# Not needed. Just to keep Bernhard happy
apt-get -y install emacs
echo "Ubuntu-specific ended. Now doing general stuff"
/vagrant/initGeneralScript.sh
echo "Ended"