DESCRIPTION="Libnsbmp is a decoding library for BMP and ICO image file formats"
SUMMARY="A decoding library for BMP and ICO images" 
HOMEPAGE="http://www.netsurf-browser.org/projects/libnsbmp/"
COPYRIGHT="2006 Richard Wilson, 2008 - 2013 Sean Fox"
LICENSE="MIT"
SOURCE_URI="http://download.netsurf-browser.org/libs/releases/libnsbmp-$portVersion-src.tar.gz"
CHECKSUM_SHA256="969ba1c4f778b6ecee5fd834a6206c97b49885673389260fef1043dfca2968b1"
REVISION="1"
ARCHITECTURES="x86_gcc2 x86 x86_64"

PATCHES="libnsbmp-0.1.1.patchset"

PROVIDES="
	libnsbmp = $portVersion
	"
REQUIRES="
	haiku
	"
BUILD_REQUIRES="
	"
BUILD_PREREQUIRES="
	haiku_devel
	netsurf_buildsystem
	cmd:gcc
	cmd:make
	"

BUILD()
{
	make PREFIX=$prefix NSSHARED=/system/data/netsurf-buildsystem
}

INSTALL()
{
	make PREFIX=$prefix NSSHARED=/system/data/netsurf-buildsystem \
		INCLUDEDIR=$relativeIncludeDir install

	prepareInstalledDevelLib libnsbmp
	fixPkgconfig
	
	# devel package
	packageEntries devel \
		$developDir
}

# ----- devel package -------------------------------------------------------

PROVIDES_devel="
	libnsbmp_devel = $portVersion
	devel:libnsbmp = $portVersion
	"
REQUIRES_devel="
	libnsbmp$secondaryArchSuffix == $portVersion base
	"
