diff options
author | Tony Vroon <chainsaw@gentoo.org> | 2011-07-06 11:19:13 +0000 |
---|---|---|
committer | Tony Vroon <chainsaw@gentoo.org> | 2011-07-06 11:19:13 +0000 |
commit | b7454fc7129806b336243638575f03051d213eb7 (patch) | |
tree | 05d9ffe05bcb8b89908a400d3a21e283fe22f5c6 /net-misc/dahdi/dahdi-2.4.1-r1.ebuild | |
parent | LibreOffice 3.4.1. Still masked for further testing and bugfixing, see Changelog (diff) | |
download | gentoo-2-b7454fc7129806b336243638575f03051d213eb7.tar.gz gentoo-2-b7454fc7129806b336243638575f03051d213eb7.tar.bz2 gentoo-2-b7454fc7129806b336243638575f03051d213eb7.zip |
Patch from Stefan Knoblich fixes compilation against 2.6.39 kernels; closes bug #372819 by Philipp Kugle. As requested by Diego "Flameeyes" Petteno, udev rules are now installed in /lib as they are not intended for user modification/customisation. CONFIG_MODULES is now also checked as the eclass does not do it for us.
(Portage version: 2.1.10.4/cvs/Linux x86_64)
Diffstat (limited to 'net-misc/dahdi/dahdi-2.4.1-r1.ebuild')
-rw-r--r-- | net-misc/dahdi/dahdi-2.4.1-r1.ebuild | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/net-misc/dahdi/dahdi-2.4.1-r1.ebuild b/net-misc/dahdi/dahdi-2.4.1-r1.ebuild new file mode 100644 index 000000000000..71600fb129b0 --- /dev/null +++ b/net-misc/dahdi/dahdi-2.4.1-r1.ebuild @@ -0,0 +1,66 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/dahdi/dahdi-2.4.1-r1.ebuild,v 1.1 2011/07/06 11:19:13 chainsaw Exp $ + +EAPI=3 + +inherit base linux-mod eutils flag-o-matic + +MY_P="${P/dahdi/dahdi-linux}" +S="${WORKDIR}/${MY_P}" + +DESCRIPTION="Kernel modules for Digium compatible hardware (formerly known as Zaptel)." +HOMEPAGE="http://www.asterisk.org" +SRC_URI="http://downloads.asterisk.org/pub/telephony/dahdi-linux/releases/${MY_P}.tar.gz +http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fwload-vpmadt032-1.25.0.tar.gz +http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fw-oct6114-064-1.05.01.tar.gz +http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fw-oct6114-128-1.05.01.tar.gz +http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fw-tc400m-MR6.12.tar.gz +http://downloads.digium.com/pub/telephony/firmware/releases/dahdi-fw-hx8-2.06.tar.gz +mirror://gentoo/gentoo-dahdi-patchset-0.6.tar.bz2" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="flash" +RESTRICT="test" + +DEPEND="" +RDEPEND="" + +EPATCH_SUFFIX="diff" +PATCHES=( "${WORKDIR}/dahdi-patchset" ) + +CONFIG_CHECK="CONFIG_MODULES CRC_CCITT" + +src_unpack() { + unpack ${A} + # Copy the firmware tarballs over, the makefile will try and download them otherwise + for file in ${A} ; do + cp "${DISTDIR}"/${file} "${MY_P}"/drivers/dahdi/firmware/ + done + # But without the .bin's it'll still fall over and die, so copy those too. + cp *.bin "${MY_P}"/drivers/dahdi/firmware/ +} + +src_prepare() { + if use flash; then + sed -i -e "s:/\* #define FXSFLASH \*/:#define FXSFLASH:" include/dahdi/dahdi_config.h + sed -i -e "s:/\* #define SHORT_FLASH_TIME \*/:#define SHORT_FLASH_TIME:" include/dahdi/dahdi_config.h + fi + base_src_prepare +} + +src_compile() { + unset ARCH + emake KSRC="${KERNEL_DIR}" DESTDIR="${D}" all || die "Compilation failed" +} + +src_install() { + # setup directory structure so udev rules get installed + mkdir -p "${D}"/etc/udev/rules.d + + einfo "Installing kernel module" + emake KSRC="${KERNEL_DIR}" DESTDIR="${D}" install || die "Installation failed" + rm -rf "$D"/lib/modules/*/modules.* +} |