SUMMARY="Tool for creating Simutrans paksets"
DESCRIPTION="Makeobj is a tool for graphics/pakset developers \
and is not needed for playing the game.
Makeobj joins both the image and the data files in a single \
compressed pak-file that will then be read by the game engine."
HOMEPAGE="http://www.simutrans.com"
COPYRIGHT="1997-2004 Hj. Malthaner
	2005-2018 The Simutrans Team"
LICENSE="Artistic"
REVISION="1"
SOURCE_URI="svn://servers.simutrans.org/simutrans/trunk"
SOURCE_FILENAME="makeobj-$portVersion"
SOURCE_DIR=""

ARCHITECTURES="?all !x86_gcc2"
SECONDARY_ARCHITECTURES="?x86"

PROVIDES="
	makeobj$secondaryArchSuffix = $portVersion
	cmd:makeobj$secondaryArchSuffix = 60.2
	"
REQUIRES="
	haiku$secondaryArchSuffix
	lib:libbz2$secondaryArchSuffix
	lib:libpng16$secondaryArchSuffix
	lib:libz$secondaryArchSuffix
	"

BUILD_REQUIRES="
	haiku${secondaryArchSuffix}_devel
	devel:libbz2$secondaryArchSuffix
	devel:libpng16$secondaryArchSuffix
	devel:libSDL2_2.0$secondaryArchSuffix
	devel:libz$secondaryArchSuffix
	"
BUILD_PREREQUIRES="
	cmd:aclocal
	cmd:autoreconf
	cmd:g++$secondaryArchSuffix
	cmd:gcc$secondaryArchSuffix
	cmd:ld$secondaryArchSuffix
	cmd:make
	cmd:pkg_config$secondaryArchSuffix
	cmd:sdl2_config$secondaryArchSuffix
	cmd:strip$secondaryArchSuffix
	cmd:svn
	"

BUILD()
{
	autoreconf configure.ac
	runConfigure ./configure
	make makeobj $jobArgs
	strip makeobj/makeobj
}

INSTALL()
{
	mkdir -p $binDir
	cp -r makeobj/makeobj $binDir/
}
