Files
haikuports/games-kids/tuxmath/tuxmath-1.7.2.recipe
Jerome Duval fc0936b040 Bump revisions for x86_64 rebuild after time_t change.
* a few apps needed build fix for time_t.
* disable compatibility packages for x86_64.
2017-06-27 15:46:25 +02:00

86 lines
2.3 KiB
Bash

SUMMARY="Tux4Kids' math tutor for kids"
DESCRIPTION="TuxMath is an educational math tutor for kids starring Tux, \
the Linux penguin. This educational game comes with two different games for \
practicing math, and having a great time doing it."
HOMEPAGE="https://tux4kids.alioth.debian.org/"
COPYRIGHT="2000-2009 Sam Hart"
LICENSE="GNU GPL v2"
REVISION="2"
SOURCE_URI="https://downloads.sf.net/tuxmath/tuxmath_w_fonts-$portVersion.tar.gz"
CHECKSUM_SHA256="7a3e39b17b88402a89780ac56368d8d92322c3b91f50ee4f9b747a8e2901b3a4"
SOURCE_DIR="tuxmath_w_fonts-$portVersion"
PATCHES="tuxmath-$portVersion.patchset"
ADDITIONAL_FILES="tuxmath.rdef"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
tuxmath$secondaryArchSuffix
app:TuxMath$secondaryArchSuffix
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libcrypto$secondaryArchSuffix
lib:libiconv$secondaryArchSuffix
lib:libintl$secondaryArchSuffix
lib:libsdl$secondaryArchSuffix
lib:libsdl_image$secondaryArchSuffix
lib:libsdl_mixer$secondaryArchSuffix
lib:libsdl_ttf$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libcrypto$secondaryArchSuffix
devel:libiconv$secondaryArchSuffix
devel:libintl$secondaryArchSuffix
devel:libsdl$secondaryArchSuffix
devel:libsdl_image$secondaryArchSuffix
devel:libsdl_mixer$secondaryArchSuffix
devel:libsdl_ttf$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:aclocal
cmd:autoconf
cmd:autopoint
cmd:cmake
cmd:gcc$secondaryArchSuffix
cmd:libtoolize$secondaryArchSuffix
cmd:make
cmd:pkg_config$secondaryArchSuffix
"
BUILD()
{
autoreconf -vfi
sed -i "s,-lm,," configure
./configure --prefix=$appsDir/TuxMath --without-sdlpango LDFLAGS="-liconv"
echo "#define ICONV_CONST const" >> config.h
make $jobArgs
}
INSTALL()
{
mkdir -p $appsDir/TuxMath
make install
local MAJOR="`echo "$portVersion" | cut -d. -f1`"
local MIDDLE="`echo "$portVersion" | cut -d. -f2`"
local MINOR="`echo "$portVersion" | cut -d. -f3`"
sed \
-e "s|@MAJOR@|$MAJOR|" \
-e "s|@MIDDLE@|$MIDDLE|" \
-e "s|@MINOR@|$MINOR|" \
$portDir/additional-files/tuxmath.rdef > tuxmath.rdef
addResourcesToBinaries tuxmath.rdef \
$appsDir/TuxMath/bin/tuxmath
mv $appsDir/TuxMath/bin/tuxmath $appsDir/TuxMath/TuxMath
rm -r $appsDir/TuxMath/bin
addAppDeskbarSymlink $appsDir/TuxMath/TuxMath
}