# SliTaz package receipt.

PACKAGE="openexr"
VERSION="1.7.0"
CATEGORY="x-window"
SHORT_DESC="openexr library for EXR images"
MAINTAINER="slaxemulator@gmail.com"
DEPENDS="zlib ilmbase"
BUILD_DEPENDS="zlib zlib-dev ilmbase-dev"
TARBALL="$PACKAGE-$VERSION.tar.gz"
WEB_SITE="http://www.openexr.org/"
WGET_URL="http://savannah.nongnu.org/download/$PACKAGE/$TARBALL"

# Rules to configure and make the package.
compile_rules()
{
	cd $src
	patch -p1 -i $stuff/gcc43.patch
	sed -i 's/.*ImathVec.*/#include "string.h"\n&/' \
		IlmImf/ImfChromaticities.h
	sed -i 's/.*Iex.*/#include "string.h"\n&/' \
		exrenvmap/blurImage.cpp
	./configure \
		$CONFIGURE_ARGS &&
	make && make install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
	mkdir -p $fs/usr/lib
	cp -a $_pkg/usr/bin $fs/usr
	cp -a $_pkg/usr/lib/*.so* $fs/usr/lib
}