Build Environment Setup for Linux
Required Tools
The following is a list of tools that are required for building MariaDB on Linux. Most, if not all, of these will exist as packages in your distribution's package repositories, so check there first. See Building MariaDB on Ubuntu, Building MariaDB on CentOS, and Building MariaDB on Gentoo pages for specific requirements for those platforms.
- bzr 1.18.1 (version 2.0.1 has out-of-memory issues)
- gunzip
- GNU tar
- gcc 2.95.2 or later
- g++
- GNU make 3.75 or later
- libtool 1.5.24 or later
- bison
- libncurses
- zlib-dev
- GNU automake
- GNU autoconf
Shell Variables
To streamline later steps, we start by setting several shell variables. Set the values of the BZR and WORK_DIR variables to the appropriate values for your Linux distribution. The rest of the variables in this section should not need to be changed.
Binaries:
BZR="/usr/bin/bzr"
Directories:
WORK_DIR="${HOME}/work/monty_program" MARIA_DIR=${WORK_DIR}/mariadb MARIA_REPO="lp:maria" MARIA_MASTER="${MARIA_DIR}/maria-local-master" MARIA_WORK="${MARIA_DIR}/maria" PACKAGING_DIR=${WORK_DIR}/packaging PACKAGING_REPO="lp:~maria-captains/ourdelta/ourdelta-montyprogram-fixes" PACKAGING_MASTER="${PACKAGING_DIR}/ourdelta-montyprogram-fixes-local-master" PACKAGING_WORK="${PACKAGING_DIR}/ourdelta-montyprogram-fixes"
Source Checkout
Initialize your bzr working directories, if not done already:
$BZR init-repo $MARIA_DIR $BZR init-repo $PACKAGING_DIR
Check out MariaDB sources:
$BZR branch $MARIA_REPO $MARIA_MASTER $BZR branch $MARIA_MASTER $MARIA_WORK
Check out packaging sources:
$BZR branch $PACKAGING_REPO $PACKAGING_MASTER $BZR branch $PACKAGING_MASTER $PACKAGING_WORK
You should now have your build environment set up and can proceed to the next steps for your Linux distribution or for Creating the MariaDB Binary Tarball. See also: Getting the MariaDB Source Code.