SUMMARY="SortSave screensaver"
DESCRIPTION="Just like the Borg, bringing order to chaos. SortSave is a re-creation of an \
old program for the Tandy 1000 computer. The original was programmed in BASIC and \
compiled to run on MS Dos."
HOMEPAGE="https://github.com/bbjimmy/Sort-Save"
SOURCE_URI="https://github.com/bbjimmy/Sort-Save/archive/1.1.tar.gz"
CHECKSUM_SHA256="cf86c6e650d6313d496a7dce49ebd99377d2b94d6835257881664a30a39ecac6"

LICENSE="SortSave"
COPYRIGHT="2013-2015 Jim Saxton, Fat Elk Software"

REVISION="1"

ARCHITECTURES="x86_gcc2 x86 ?x86_64"

PROVIDES="
	sortsave = $portVersion
	app:sortsave = $portVersion
	"
REQUIRES="
	haiku
	"
BUILD_REQUIRES="
	haiku_devel
	"
BUILD_PREREQUIRES="
	cmd:gcc
	cmd:make
	cmd:unzip
	makefile_engine
	"
SOURCE_DIR=Sort-Save-1.1

BUILD()
{
	make $jobArgs BUILDHOME=`finddir B_SYSTEM_DEVELOP_DIRECTORY`
}

INSTALL()
{	
	mkdir -p $addOnsDir/Screen\ Savers
	cd objects*
	cp sort-save $addOnsDir/Screen\ Savers/SortSave
	mkdir -p $dataDir/FatElk
	cd ..
	cd FatElk
	unzip -o fatelk.zip
	cp "FAT ELK" $dataDir/FatElk/
	cp "Fat Elk " $dataDir/FatElk/
}
