SUMMARY="A simple Tracker add-on that lets you search through text files"
DESCRIPTION="TrackerGrep is a simple Tracker add-on that lets you search \
through text files. Haiku already comes with a tool that lets you do that \
(grep) but you need to use it from a Terminal window. Gone are those days \
of command-line trouble, because from now on TrackerGrep lets you run grep \
directly from Tracker."
HOMEPAGE="https://github.com/HaikuArchives/TrackerGrep"
COPYRIGHT="1998-2006 Matthijs Hollemans
	2007 Jonas Sundström."
LICENSE="MIT"
REVISION="4"
srcGitRev="4b7b780c39eab07b316f6bb511b15919513b9324"
SOURCE_URI="https://github.com/HaikuArchives/TrackerGrep/archive/$srcGitRev.tar.gz"
CHECKSUM_SHA256="f17598bf340c6e0f5073f6ce5b21a2bea157ee5c72b65d94f3bf1530366e2cae"
SOURCE_DIR="TrackerGrep-$srcGitRev"

ARCHITECTURES="all"

PROVIDES="
	trackergrep = $portVersion
	add_on:TrackerGrep = $portVersion
	"
REQUIRES="
	haiku
	cmd:grep
	"

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

BUILD()
{
	cd source
	make $jobArgs OBJ_DIR=objects
}

INSTALL()
{
	cd source
	mkdir -p $addOnsDir/Tracker/

	cp objects/TrackerGrep-G $addOnsDir/Tracker/
}
