1SUMMARY="Selectively remove C preprocessor conditionals"
2DESCRIPTION="The unifdef utility selectively processes conditional C \
3preprocessor #if and #ifdef directives. It removes from a file both \
4the directives and the additional text that they delimit, while \
5otherwise leaving the file alone."
6HOMEPAGE="https://dotat.at/prog/unifdef/"
7COPYRIGHT="Tony Finch"
8LICENSE="BSD (3-clause)"
9REVISION="1"
10SOURCE_URI="https://github.com/fanf2/unifdef/archive/refs/tags/unifdef-$portVersion.tar.gz"
11CHECKSUM_SHA256="030369db9ff917acfae7fa4e90bcc1dff8a8dc534d82d1c72c12ef698d2f20e4"
12SOURCE_DIR="unifdef-unifdef-$portVersion"
13PATCHES="unifdef-$portVersion.patchset"
14
15ARCHITECTURES="all"
16
17PROVIDES="
18	unifdef = $portVersion
19	cmd:unifdef
20	"
21REQUIRES="
22	haiku
23	"
24
25BUILD_REQUIRES="
26	haiku_devel
27	"
28BUILD_PREREQUIRES="
29	cmd:gcc
30	cmd:make
31	"
32
33BUILD()
34{
35	chmod +x scripts/reversion.sh
36	scripts/reversion.sh
37
38	gcc -o unifdef unifdef.c FreeBSD/err.c -I.
39}
40
41INSTALL()
42{
43	mkdir -p $binDir
44	cp unifdef $binDir
45}
46