# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils versionator # TODO: # * properly check for the kernel version, using the check-kernel.eclass # * get rid of the sed commands, with some help from 4Front # * better initscript # * bugfixing # New in this version (2007-11-14): # * version bump to build 1009 # * got rid of a couple of sed's # * removed the ossxmix patch, not needed anymore # * introduced the libsalsa patch from Jozsef Daniel, but didn't tested it # * the libsalsa patch was modified to be applied at unpack() # * made our initscript install as it should, by overwriting the default one DESCRIPTION="Open Sound System - portable, mixing-capable, high quality sound system for Unix." HOMEPAGE="http://developer.opensound.com/" LICENSE="GPL-2" SLOT="0" KEYWORDS="~amd64 ~x86" IUSE="" DEPEND="sys-apps/gawk >=x11-libs/gtk+-2 >=sys-kernel/linux-headers-2.6.11" RDEPEND="${DEPEND}" MY_PV=$(get_version_component_range 1-2) MY_BUILD=$(get_version_component_range 3) SRC_URI="http://www.4front-tech.com/developer/sources/stable/oss-v${MY_PV}-build${MY_BUILD}-src-gpl.tar.bz2 \ http://voimakentta.vpalvelin.com/sources/stable/oss-v${MY_PV}-build${MY_BUILD}-src-gpl.tar.bz2 \ http://developer.opensound.com/sources/stable/oss-v${MY_PV}-build${MY_BUILD}-src-gpl.tar.bz2 " S="${WORKDIR}/build" src_unpack() { unpack ${A} mkdir build cd "${S}" ${WORKDIR}/oss-v${MY_PV}-build${MY_BUILD}-src-gpl/configure || die "configure failed" cp ${WORKDIR}/build/cmd/ossxmix/Makefile \ ${WORKDIR}/build/cmd/ossxmix/Makefile.bak sed -i -e 's/$(CFLAGS) $(OSFLAGS)//;s/$(CFLAGS) $(LIBRARIES)//' \ ${WORKDIR}/build/cmd/*/Makefile \ ${WORKDIR}/build/os_cmd/Linux/ossvermagic/Makefile \ || die "sed failed" mv ${WORKDIR}/build/cmd/ossxmix/Makefile.bak \ ${WORKDIR}/build/cmd/ossxmix/Makefile epatch "${FILESDIR}"/soundon_no_libsalsa.patch \ || die "epatch failed" cp ${FILESDIR}/oss ${WORKDIR}/build/setup/Linux/oss/etc/S89oss } src_compile() { emake build || die "emake build failed" } src_install() { newinitd "${FILESDIR}"/oss oss cp -R prototype/* ${D} ewarn "In order to use OSSv4 you must run" ewarn "# /etc/init.d/oss start " ewarn "Enjoy OSSv4 !" }