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/SDL_ttf-$SDLTTF_VERSION.tar.gz ]; then
|
|
|
|
curl -L http://www.libsdl.org/projects/SDL_ttf/release/SDL_ttf-$SDLTTF_VERSION.tar.gz > $CACHEROOT/SDL_ttf-$SDLTTF_VERSION.tar.gz
|
|
|
|
tar xzf $CACHEROOT/SDL_ttf-$SDLTTF_VERSION.tar.gz
|
2011-11-30 20:01:00 +01:00
|
|
|
fi
|
|
|
|
|
|
|
|
if [ -f SDL_ttf-$SDLTTF_VERSION/libSDL_ttf-arm7.a ]; then
|
|
|
|
exit 0;
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
2011-12-06 11:42:37 +01:00
|
|
|
pushd SDL_ttf-$SDLTTF_VERSION
|
2011-11-30 20:01:00 +01:00
|
|
|
rm libSDL_ttf.la
|
2011-12-06 11:42:37 +01:00
|
|
|
./configure --prefix=/usr/local/iphone \
|
|
|
|
--host=arm-apple-darwin \
|
|
|
|
--enable-static=yes \
|
|
|
|
--enable-shared=no \
|
2011-11-30 20:01:00 +01:00
|
|
|
--without-x \
|
2011-12-06 11:42:37 +01:00
|
|
|
CC="$CCACHE $DEVROOT/usr/bin/arm-apple-darwin10-llvm-gcc-4.2" \
|
|
|
|
AR="$DEVROOT/usr/bin/ar" \
|
|
|
|
LDFLAGS="-isysroot $SDKROOT -miphoneos-version-min=$SDKVER" \
|
|
|
|
CFLAGS="-march=armv7 -mcpu=arm1176jzf -mcpu=cortex-a8 -O0 -g -miphoneos-version-min=$SDKVER -isysroot $SDKROOT"
|
2011-11-30 20:01:00 +01:00
|
|
|
make clean
|
|
|
|
make libSDL_ttf.la
|
2011-12-01 17:41:27 +01:00
|
|
|
|
|
|
|
# copy to buildroot
|
|
|
|
cp .libs/libSDL_ttf.a $BUILDROOT/lib/libSDL_ttf.a
|
|
|
|
cp -a SDL_ttf.h $BUILDROOT/include
|
2011-12-06 11:42:37 +01:00
|
|
|
|
|
|
|
popd
|