[mythtv-users] IVTV on Gentoo

Keith Gross grossk at mail.tds.net
Mon Oct 20 14:00:41 EDT 2003


I simply created a simple ebuild myself and then placed the tar ball from the 
IVTV web site in the distfiles directory of postage.  Make sure teh tarball 
and the ebuild files are named with the same dates. I've included the last 
one I used below.  I'm not sure it's the best but's it's served me well for 
the last 6 months.

# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: $

DESCRIPTION="The ivtv project develops kernel drivers and utilities for using 
a Hauppuage PVR 250/350 under linux"
HOMEPAGE="http://ivtv.sourceforge.net/"

SRC_URI="ftp://foo.bar.com/${P}.tar.gz"

#The only mention I've currently found about the license was in the source and 
simply said GPL
# so I hope this is correct.
LICENSE="GPL-2"

SLOT="0"

KEYWORDS="x86"

IUSE=""

# Build-time dependencies, such as
#    ssl? ( >=openssl-0.9.6b )
#    >=perl-5.6.1-r1
# It is advisable to use the >= syntax show above, to reflect what you
# had installed on your system when you tested the package.  Then
# other users hopefully won't be caught without the right version of
# a dependency.
DEPEND=""

# Source directory; the dir where the sources can be found (automatically
# unpacked) inside ${WORKDIR}.  S will get a default setting of 
${WORKDIR}/${P}
# if you omit this line.
S=${WORKDIR}/${P}

src_compile() {
	echo ${S}
	echo ${WORKDIR}
	pwd
	cp ${WORKDIR}/utils/videodev2.h ${WORKDIR}/driver
	cd ${WORKDIR}/driver
	emake || die
	cd ../utils
	emake || die
}

src_install() {
	MODDIR=${D}/lib/modules/`uname -r`/kernel/drivers/media/video
	OBJS="msp3400.o saa7115.o tveeprom.o ivtv.o saa7127.o"
	cd ${WORKDIR}/driver
	mkdir -p ${MODDIR}
	install -m 0644 ${OBJS} ${MODDIR}	
	cd ../utils
	mkdir -p ${D}/usr/share/ivtv
	install -m 0644 * ${D}/usr/share/ivtv
	install -m 0744 *.pl ${D}/usr/share/ivtv
	install -m 0744 test_ioctl ${D}/usr/share/ivtv
	mkdir -p ${D}/etc/modules.d
	echo options tuner type=2 > ${D}/etc/modules.d/ivtv
	echo options msp3400 once=1 simple=1  >> ${D}/etc/modules.d/ivtv
	echo add below ivtv msp3400 saa7115 tuner >> ${D}/etc/modules.d/ivtv
}

pkg_postinst() {
	/sbin/modules-update
	einfo "In order to make the tuner function properly you will"
	einfo "need to arrange for the ivtv module to be loaded. In"
	einfo "addition you'll need to configure the card and tune to "
	einfo "valid channel.  A couple utilities for this purpose have"
	einfo "also been installed."
}



On Monday 20 October 2003 12:39 pm, Reiter, John wrote:
> I'm not seeing a ebuild in the portage tree for IVTV, does this have to be
> compiled by hand on Gentoo?



More information about the mythtv-users mailing list