2011-11-30 20:01:00 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
2011-12-01 17:41:27 +01:00
|
|
|
. environment.sh
|
2011-11-30 20:01:00 +01:00
|
|
|
|
2011-12-06 11:42:37 +01:00
|
|
|
if [ ! -f $CACHEROOT/freetype-$FT_VERSION.tar.bz2 ]; then
|
|
|
|
curl -L http://download.savannah.gnu.org/releases/freetype/freetype-$FT_VERSION.tar.bz2 > $CACHEROOT/freetype-$FT_VERSION.tar.bz2
|
|
|
|
tar xjf $CACHEROOT/freetype-$FT_VERSION.tar.bz2
|
2011-11-30 20:01:00 +01:00
|
|
|
fi
|
|
|
|
|
|
|
|
if [ -f freetype-$FT_VERSION/libfreetype-arm7.a ]; then
|
|
|
|
exit 0;
|
|
|
|
fi
|
|
|
|
|
|
|
|
# lib not found, compile it
|
2011-12-06 11:42:37 +01:00
|
|
|
pushd freetype-$FT_VERSION
|
|
|
|
./configure --prefix=/usr/local/iphone \
|
|
|
|
--host=arm-apple-darwin \
|
|
|
|
--enable-static=yes \
|
|
|
|
--enable-shared=no \
|
2011-12-06 12:08:47 +01:00
|
|
|
CC="$ARM_CC" AR="$ARM_AR" \
|
|
|
|
LDFLAGS="$ARM_LDFLAGS" CFLAGS="$ARM_CFLAGS"
|
2011-11-30 20:01:00 +01:00
|
|
|
make clean
|
|
|
|
make
|
|
|
|
|
2011-12-01 17:41:27 +01:00
|
|
|
# copy to buildroot
|
|
|
|
cp objs/.libs/libfreetype.a $BUILDROOT/lib/libfreetype.a
|
|
|
|
cp -a include $BUILDROOT/include/freetype
|
2011-12-06 11:42:37 +01:00
|
|
|
|
|
|
|
popd
|