# Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 IUSE="" DESCRIPTION="Firmwares, including documentation and scripts, for Hauppauge's WinTV-PVR-usb2" HOMEPAGE="http://www.isely.net/pvrusb2.html" SRC_URI=" http://www.isely.net/downloads/pvrusb2-mci-20060924.tar.bz2 http://www.eskimo.com/~roger/files/packages/pvrusb2-firmware/v4l-cx2341x-enc.fw.bz2 http://www.eskimo.com/~roger/files/packages/pvrusb2-firmware/v4l-cx25840.fw.bz2 http://www.eskimo.com/~roger/files/packages/pvrusb2-firmware/v4l-pvrusb2-24xxx-01.fw.bz2 http://www.eskimo.com/~roger/files/packages/pvrusb2-firmware/v4l-pvrusb2-29xxx-01.fw.bz2 " # Check for the above firmwares. # If not found, instruct installer to get them by using fwextract.pl # and copying them into /usr/portage/disfiles # NOTE: The two firmware* files are stripped from a proprietory win32 driver! LICENSE="Conexant-firmware" SLOT="0" KEYWORDS="x86" #RDEPEND="sys-apps/udev" DEPEND="" S=${WORKDIR}/pvrusb2-mci-20060924 pkg_setup() { if kernel_is 2 4; then "You need kernel-2.6 for this module to work" "(>=kernel-2.6.16 is recommended)" die fi echo einfo "24xxx is the older model of the PVRUSB2 device." einfo "29xxx is the newer model of the PVRUSB2 device." einfo "You can opt to extract your own firmwares using" einfo "fwextract.pl or fwfind.sh" echo CONFIG_CHECK="USB" CONFIG_CHECK="BT848" CONFIG_CHECK="VIDEO_DECODER" CONFIG_CHECK="VIDEO_TVEEPROM" CONFIG_CHECK="VIDEO_PVRUSB2" } src_unpack() { unpack ${A} # If you use Mythtv, enabling interlacing will significantly # reduce cpu usage. Enter PVRUSB2="interlace" to make it so. #if [[ $PVRUSB2 = "interlace" ]]; then # cd ${S}/driver # epatch ${FILESDIR}/interlace_enable.patch #fi cd ${S} } src_install() { insinto "/lib/firmware/" doins ${WORKDIR}/v4l-cx2341x-enc.fw doins ${WORKDIR}/v4l-cx25840.fw doins ${WORKDIR}/v4l-pvrusb2-24xxx-01.fw doins ${WORKDIR}/v4l-pvrusb2-29xxx-01.fw dodoc ${S}/LICENSE.TXT dodoc ${S}/README dohtml ${S}/doc/pvrusb2-eeprom.html dohtml ${S}/doc/pvrusb2-faq.html dohtml ${S}/doc/pvrusb2-utils.html dohtml ${S}/doc/pvrusb2.html dodir /usr/share/doc/${PF}/doc insinto /usr/share/doc/${PF}/doc dodoc ${S}/doc/README dodoc ${S}/doc/controls.txt dodoc ${S}/doc/notes.txt dodoc ${S}/doc/protocol-info.txt dodir /usr/share/doc/${PF}/misc insinto /usr/share/doc/${PF}/misc doins ${S}/misc/* dodir /usr/share/doc/${PF}/utils insinto /usr/share/doc/${PF}/utils doins ${S}/utils/* } pkg_postinst() { echo einfo "If /var/log/messages shows errors about no firmwares available," einfo "# insmod pvrusb2 debug=10" echo einfo "To extract firmwares manually:" einfo "http://www.isely.net/pvrusb2/pvrusb2.html" echo einfo "Mythtv works well with this device." echo echo }