SUMMARY="GNU troff typesetting package"
DESCRIPTION="
The groff (GNU troff) software is a typesetting package which reads plain text \
mixed with formatting commands and produces formatted output.
"
HOMEPAGE="http://www.gnu.org/software/groff/"
COPYRIGHT="2003-2009 Free Software Foundation, Inc."
LICENSE="GNU GPL v3"
REVISION="1"
SOURCE_URI="https://ftp.gnu.org/gnu/groff/groff-$portVersion.tar.gz"
CHECKSUM_SHA256="e78e7b4cb7dec310849004fa88847c44701e8d133b5d4c13057d876c1bad0293"

ARCHITECTURES="all ?x86_gcc2 ?x86"

PROVIDES="
	groff = $portVersion compat >= 1.20
	cmd:addftinfo = $portVersion compat >= 1.20
	cmd:afmtodit = $portVersion compat >= 1.20
	cmd:chem = $portVersion compat >= 1.20
	cmd:eqn = $portVersion compat >= 1.20
	cmd:eqn2graph = $portVersion compat >= 1.20
	cmd:gdiffmk = $portVersion compat >= 1.20
	cmd:glilypond = $portVersion compat >= 1.22
	cmd:gperl = $portVersion compat >= 1.22
	cmd:gpinyin = $portVersion compat >= 1.22
	cmd:grap2graph = $portVersion compat >= 1.20
	cmd:grn = $portVersion compat >= 1.20
	cmd:grodvi = $portVersion compat >= 1.20
	cmd:groff = $portVersion compat >= 1.20
	cmd:groffer = $portVersion compat >= 1.20
	cmd:grog = $portVersion compat >= 1.20
	cmd:grolbp = $portVersion compat >= 1.20
	cmd:grolj4 = $portVersion compat >= 1.20
	cmd:gropdf = $portVersion compat >= 1.22
	cmd:grops = $portVersion compat >= 1.20
	cmd:grotty = $portVersion compat >= 1.20
	cmd:hpftodit = $portVersion compat >= 1.20
	cmd:indxbib = $portVersion compat >= 1.20
	cmd:lkbib = $portVersion compat >= 1.20
	cmd:lookbib = $portVersion compat >= 1.20
	cmd:mmroff = $portVersion compat >= 1.20
	cmd:neqn = $portVersion compat >= 1.20
	cmd:nroff = $portVersion compat >= 1.20
	cmd:pdfmom = $portVersion compat >= 1.22
	cmd:pdfroff = $portVersion compat >= 1.20
	cmd:pfbtops = $portVersion compat >= 1.20
	cmd:pic = $portVersion compat >= 1.20
	cmd:pic2graph = $portVersion compat >= 1.20
	cmd:post_grohtml = $portVersion compat >= 1.20
	cmd:pre_grohtml = $portVersion compat >= 1.20
	cmd:preconv = $portVersion compat >= 1.20
	cmd:refer = $portVersion compat >= 1.20
	cmd:roff2dvi = $portVersion compat >= 1.20
	cmd:roff2html = $portVersion compat >= 1.20
	cmd:roff2pdf = $portVersion compat >= 1.20
	cmd:roff2ps = $portVersion compat >= 1.20
	cmd:roff2text = $portVersion compat >= 1.20
	cmd:roff2x = $portVersion compat >= 1.20
	cmd:soelim = $portVersion compat >= 1.20
	cmd:tbl = $portVersion compat >= 1.20
	cmd:tfmtodit = $portVersion compat >= 1.20
	cmd:troff = $portVersion compat >= 1.20
	"
REQUIRES="
	haiku
	"

BUILD_REQUIRES="
	haiku_devel
	"
BUILD_PREREQUIRES="
	cmd:aclocal
	cmd:autoconf
	cmd:bison
	cmd:gcc
	cmd:ld
	cmd:libtoolize
	cmd:make
	cmd:makeinfo
	cmd:sed
	"

BUILD()
{
	runConfigure ./configure
	make $jobArgs
}

INSTALL()
{
	make install
	rm $prefix/lib/charset.alias
}

TEST()
{
	make check
}
