SUMMARY="Binary & source-level backwards compatibility checker"
DESCRIPTION="
ABI Compliance Checker (ACC) is a tool for checking backward binary and \
source-level compatibility of aC/C++ library.  The tool checks header files \
and shared libraries of old and new versions and analyzes changes in API and \
ABI (ABI=API+compiler ABI) that may break binary and/or source compatibility."
HOMEPAGE="https://lvc.github.io/abi-compliance-checker/"
COPYRIGHT="2009-2010 The Linux Foundation
	2009-2011 Institute for System Programming, RAS
	2011-2012 Nokia Corporation and/or its subsidiary(-ies)
	2011-2012 ROSA Laboratory"
LICENSE="GNU GPL v2"
REVISION="2"
SOURCE_URI="https://github.com/downloads/lvc/abi-compliance-checker/abi-compliance-checker-1.98.3.tar.gz"
CHECKSUM_SHA256="d397530027ec781d53d80287a77f18a872b35720fbb1e559e0bda7e715607013"
SOURCE_DIR="abi-compliance-checker-1.98.3"
ADDITIONAL_FILES="example-descriptors"

ARCHITECTURES="?all"

PROVIDES="
	abi_compliance_checker = $portVersion
	"
REQUIRES="
	haiku
	"

BUILD_REQUIRES="
	haiku_devel
	"
BUILD_PREREQUIRES="
	perl
	cmd:gcc
	cmd:make
	cmd:sed
	"

BUILD()
{
	sed -i 's/linux|freebsd|openbsd|netbsd/linux|freebsd|openbsd|netbsd|haiku/' Makefile.pl
	sed -i 's/$PREFIX\/share\/$TOOL_SNAME/$PREFIX\/data\/$TOOL_SNAME/' Makefile.pl
	sed -i 's/..\/share\/$TOOL_SNAME/..\/data\/$TOOL_SNAME/' Makefile.pl
}

INSTALL()
{
# TODO: Need to figure out what goes where, as this isn't working
#	mkdir -p $prefix
#	perl Makefile.pl -install $PREFIX=$prefix
#	cp -r $portDir/additional-files/example-descriptors \
#		$dataDir/abi-compliance-checker
	:
}
