Skip to content

Commit

Permalink
Add private fontconfig
Browse files Browse the repository at this point in the history
It seems cairo-perf-trace has problems with fontconfig >= 2.9.0, so to
work around this, build our own private fontconfig.
  • Loading branch information
robclark authored and ssvb committed Mar 27, 2014
1 parent f904e5b commit 7ee2c1d
Showing 1 changed file with 25 additions and 2 deletions.
27 changes: 25 additions & 2 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,30 @@
export CFLAGS="-O2 -g"
export CC=gcc
export CAIRO_VERSION=1.12.16
# NOTE: cairo-script stuff has problems with newer fontconfig:
export FONTCONFIG_VERSION=2.8.0
export MAKEOPTS=-j2

# setup build environment

export PREFIX=`pwd`/tmp
export LD_LIBRARY_PATH=$PREFIX/pixman/lib:$PREFIX/cairo/lib
export LD_RUN_PATH=$PREFIX/pixman/lib:$PREFIX/cairo/lib
export PKG_CONFIG_PATH=$PREFIX/pixman/lib/pkgconfig:$PREFIX/cairo/lib/pkgconfig
export PKG_CONFIG_PATH=$PREFIX/pixman/lib/pkgconfig:$PREFIX/cairo/lib/pkgconfig:$PREFIX/fontconfig/lib/pkgconfig

if [ ! -d "$PREFIX" ]; then
mkdir $PREFIX
fi

# clone repositories

if [ ! -d "fontconfig" ]; then
git clone git://anongit.freedesktop.org/fontconfig
pushd fontconfig
git checkout $FONTCONFIG_VERSION
popd
fi

if [ ! -d "pixman" ]; then
git clone git://anongit.freedesktop.org/pixman
fi
Expand All @@ -29,7 +38,21 @@ if [ ! -d "cairo" ]; then
popd
fi

# configure and build pixman and cairo
# configure and build fontconfig, pixman and cairo

if [ ! -f "fontconfig/configure" ]; then
echo "Configuring fontconfig..."
pushd fontconfig
./autogen.sh --prefix=$PREFIX/fontconfig || exit 1
popd
fi

if [ ! -d "tmp/fontconfig" ]; then
echo "Compiling fontconfig..."
pushd fontconfig
make $MAKEOPTS install || exit 1
popd
fi

if [ ! -f "pixman/configure" ]; then
echo "Configuring pixman..."
Expand Down

0 comments on commit 7ee2c1d

Please sign in to comment.