SUMMARY="Extension to the data-stream translation kit"
DESCRIPTION="Translator Plus is an extension to the data-stream \
translation kit that is aimed at document file-types. For now, only HTML \
and plain text are supported."
HOMEPAGE="https://github.com/HaikuArchives/TransPlus"
COPYRIGHT="2000 Nathan Whitehorn"
LICENSE="GNU GPL v2"
REVISION="4"
SOURCE_URI="https://github.com/HaikuArchives/TransPlus/archive/7baba3a1da0699bfd2e6a5cd7d5e2f50725e5d4a.tar.gz"
CHECKSUM_SHA256="ce6b0dc55afb67b677f2b204ccfbb2fa811a5f5a457dd9b58013907ce6a44b02"
SOURCE_DIR="TransPlus-7baba3a1da0699bfd2e6a5cd7d5e2f50725e5d4a"

ARCHITECTURES="all ?x86"

PROVIDES="
	transplus = $portVersion
	lib:Transplus = $portVersion
	"
REQUIRES="
	haiku
	"

BUILD_REQUIRES="
	haiku_devel
	"
BUILD_PREREQUIRES="
	makefile_engine
	cmd:gcc
	cmd:make
	"

BUILD()
{
	cd src
	make OBJ_DIR=objects
	make OBJ_DIR=objects -f make2
	make OBJ_DIR=objects -f make3
}

INSTALL()
{
	mkdir -p $addOnsDir/Translators
	mkdir -p $libDir

	cp -r $sourceDir/src/objects/libtransplus $libDir
	cp -r $sourceDir/src/objects/HTML $addOnsDir/Translators/
}
