# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header$ inherit eutils DESCRIPTION="OpenAL Soft is a cross-platform software implementation of the OpenAL 3D audio API. The Open Audio Library is an open, vendor-neutral, cross-platform API for interactive, primarily spatialized audio" HOMEPAGE="http://kcat.strangesoft.net/openal.html" SRC_URI="http://kcat.strangesoft.net/openal-releases/${PN}-${PV}.tar.bz2" LICENSE="LGPL-2" SLOT="0" KEYWORDS="~amd64 ~ia64 ~ppc ~ppc64 ~x86 ~x86-fbsd" IUSE="alsa oss debug" RDEPEND="alsa? ( >=media-libs/alsa-lib-1.0.2 ) !media-libs/openal" DEPEND="${RDEPEND} >=dev-util/cmake-2.4.0" src_unpack() { unpack ${A} cd "${S}" } src_compile() { local myconf="" cd "${S}/CMakeConf" use alsa || myconf="${myconf} -DALSA=OFF" use oss || myconf="${myconf} -DOSS=OFF" use debug && myconf="${myconf} -DCMAKE_BUILD_TYPE=Debug" cmake -DCMAKE_INSTALL_PREFIX=/usr ${myconf} .. \ || die "cmake failed" emake || die "emake failed" cd "${S}" } src_install() { cd "${S}/CMakeConf" emake install DESTDIR="${D}" || die "emake install failed" cd "${S}" dodoc alsoftrc.sample }