SUMMARY="Fast console MPEG Audio Player and decoder library"
DESCRIPTION="
mpg123 is the fast and Free console based real time MPEG Audio Player for \
Layer 1, 2 and 3.
"
HOMEPAGE="http://www.mpg123.org/" 
SRC_URI="http://sourceforge.net/projects/mpg123/files/mpg123/1.12.1/mpg123-1.12.1.tar.bz2/download"
CHECKSUM_SHA256="f3cfe305832c4a6a56d105ec1b47e7963d5d809cb17447ee93ae2330f2365a72"
REVISION="1"
ARCHITECTURES="x86_gcc2 x86"
SECONDARY_ARCHITECTURES="x86"
#DEPEND="media-libs/libsdl >= 1.2"

PROVIDES="
	mpg123$secondaryArchSuffix = $portVersion
	lib:libmpg123$secondaryArchSuffix
	cmd:mpg123$secondaryArchSuffix
	"

REQUIRES="
	haiku$secondaryArchSuffix >= $haikuVersion
	"

BUILD_PREREQUIRES="
	haiku${secondaryArchSuffix}_devel >= $haikuVersion
	cmd:gcc$secondaryArchSuffix
	cmd:ld$secondaryArchSuffix
	cmd:make
	cmd:awk
	"

PATCHES="mpg123-1.12.1.patch"
BUILD()
{
#libtoolize --force --copy --install
#	aclocal
#	autoconf
	LDFLAGS="-lnetwork" runConfigure ./configure --disable-aligncheck
	make $jobArgs
}

INSTALL()
{
	make install
	prepareInstalledDevelLib libmpg123
	packageEntries devel $developDir
}

PROVIDES_devel="
	mpg123$secondaryArchSuffix = $portVersion
	devel:libmpg123$secondaryArchSuffix
	"

REQUIRES_devel="
	haiku$secondaryArchSuffix >= $haikuVersion
	mpg123$secondaryArchSuffix == $portVersion base
	"


LICENSE="GNU LGPL v2.1"
COPYRIGHT="1995-2009 Michael Hipp and others"
