From 3665dcb944582406bb7bfb47b646c13aa410df58 Mon Sep 17 00:00:00 2001 From: Tibor Nagy Date: Sun, 9 Dec 2018 00:17:07 +0100 Subject: [PATCH] Add sdl_ttf recipe --- recipes/sdl_ttf/01_redox.patch | 12 ++++++++++ recipes/sdl_ttf/recipe.sh | 43 ++++++++++++++++++++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 recipes/sdl_ttf/01_redox.patch create mode 100644 recipes/sdl_ttf/recipe.sh diff --git a/recipes/sdl_ttf/01_redox.patch b/recipes/sdl_ttf/01_redox.patch new file mode 100644 index 000000000..9366f51c1 --- /dev/null +++ b/recipes/sdl_ttf/01_redox.patch @@ -0,0 +1,12 @@ +diff -rupNw source-original/config.sub source/config.sub +--- source-original/config.sub 2012-01-19 07:30:05.000000000 +0100 ++++ source/config.sub 2018-05-01 17:31:52.766229515 +0200 +@@ -1276,7 +1276,7 @@ case $os in + -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ +- | -kopensolaris* \ ++ | -kopensolaris* | -redox* \ + | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ + | -aos* | -aros* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ \ No newline at end of file diff --git a/recipes/sdl_ttf/recipe.sh b/recipes/sdl_ttf/recipe.sh new file mode 100644 index 000000000..14e082a8d --- /dev/null +++ b/recipes/sdl_ttf/recipe.sh @@ -0,0 +1,43 @@ +VERSION=2.0.11 +TAR=https://www.libsdl.org/projects/SDL_ttf/release/SDL_ttf-$VERSION.tar.gz +BUILD_DEPENDS=(sdl liborbital freetype libpng zlib) + +export CFLAGS="-I$PWD/sysroot/include/ -I$PWD/sysroot/include/freetype2/" +export LDFLAGS="-L$PWD/sysroot/lib/" + +function recipe_version { + echo "$VERSION" + skip=1 +} + +function recipe_update { + echo "skipping update" + skip=1 +} + +function recipe_build { + sysroot="${PWD}/../sysroot" + export SDL_CONFIG="$sysroot/bin/sdl-config" + export FREETYPE_CONFIG="$sysroot/bin/freetype-config" + + ./autogen.sh + ./configure --prefix=/ --host=${HOST} --disable-shared --disable-sdltest + make -j"$(nproc)" + skip=1 +} + +function recipe_test { + echo "skipping test" + skip=1 +} + +function recipe_clean { + make clean + skip=1 +} + +function recipe_stage { + dest="$(realpath $1)" + make DESTDIR="$dest" install + skip=1 +}