SUMMARY="A library that defines common error values"
DESCRIPTION="
This is a library that defines common error values for all GnuPG components. \
Among these are GPG, GPGSM, GPGME, GPG-Agent, libgcrypt, Libksba, DirMngr, \
Pinentry, SmartCard Daemon and more.
"
LICENSE="GNU LGPL v2.1"
COPYRIGHT="2003-2013 g10 Code GmbH"
HOMEPAGE="http://www.gnupg.org/related_software/libraries.en.html#lib-libgpg-error"
SRC_URI="ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.12.tar.bz2"
REVISION="1"
CHECKSUM_MD5="8f0eb41a344d19ac2aa9bd101dfb9ce6"
ARCHITECTURES="x86"

PROVIDES="
	libgpg_error = $portVersion compat >= 1.12
	lib:libgpg_error = $portVersion compat >= 1.12
	cmd:gpg_error = $portVersion compat >= 1.12
	"

REQUIRES="
	haiku >= $haikuVersion
	"

BUILD_REQUIRES="
	haiku_devel >= $haikuVersion
	"

BUILD_PREREQUIRES="
	cmd:make
	cmd:gcc
	"

PROVIDES_devel="
	libgpg_error_devel = $portVersion compat >= 1.12
	cmd:gpg_error_config = $portVersion compat >= 1.12
	devel:libgpg_error = $portVersion compat >= 1.12
	"

REQUIRES_devel="
	libgpg_error == $portVersion
	"

SOURCE_DIR="libgpg-error-1.12"

PATCHES="libgpg_error-1.12.patch"

BUILD()
{
	runConfigure ./configure
	make
}

INSTALL()
{
	make install

	prepareInstalledDevelLibs libgpg-error

	packageEntries devel \
		$developDir $binDir/gpg-error-config
}
