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/"
SOURCE_URI="http://ftp.gnu.org/gnu/groff/groff-1.20.1.tar.gz"
CHECKSUM_SHA256="b645878135cb620c6c417c5601bfe96172245af12045540d7344938b4c2cd805"
LICENSE="GNU GPL v3"
COPYRIGHT="2003-2009 Free Software Foundation, Inc."
REVISION="4"
ARCHITECTURES="all"

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: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: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: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="
	"
BUILD_PREREQUIRES="
	haiku_devel
	cmd:aclocal
	cmd:autoconf
	cmd:gcc
	cmd:ld
	cmd:libtoolize
	cmd:make
	cmd:sed
	"


DEPEND=""
BUILD()
{
	libtoolize --force --copy --install
	aclocal -I m4
	autoconf
	sed -i s@docdir='$(datadir)/doc/groff/'@docdir=$docDir/@g Ma*
	PERLPATH="/bin/env perl" \
	runConfigure ./configure
	make $jobArgs
}

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

TEST()
{
	make check
}
