wok-undigest diff v4l-dvb/receipt @ rev 1201

palemoon : ac_add_options
author Xander Ziiryanoff <psychomaniak@xakep.ru>
date Fri Aug 19 22:41:17 2016 +0200 (2016-08-19)
parents
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/v4l-dvb/receipt	Fri Aug 19 22:41:17 2016 +0200
     1.3 @@ -0,0 +1,79 @@
     1.4 +# SliTaz package receipt.
     1.5 +
     1.6 +PACKAGE="v4l-dvb"
     1.7 +VERSION="development"
     1.8 +CATEGORY="multimedia"
     1.9 +MAINTAINER="jozee@slitaz.org"
    1.10 +LICENSE="GPL2"
    1.11 +SHORT_DESC="v4l-dvb development repository"
    1.12 +WEB_SITE="http://linuxtv.org/hg/v4l-dvb/"
    1.13 +TARBALL="$PACKAGE-$VERSION.tar.bz2"
    1.14 +TAGS="webcam"
    1.15 +WGET_URL="hg|$WEB_SITE"
    1.16 +
    1.17 +DEPENDS="linux"
    1.18 +BUILD_DEPENDS="python mercurial coreutils-operations module-init-tools xz"
    1.19 +
    1.20 +# Rules to configure and make the package.
    1.21 +compile_rules() {
    1.22 +	cd $src
    1.23 +	patch -p1 < $stuff/414e0bbd99bf
    1.24 +	patch -p1 < $stuff/d64b014c5253
    1.25 +	patch -p1 < $stuff/d0a2ff731670
    1.26 +	sed -i 's/0 | xargs -0n 255 ln -sf --target-directory=\./ | while read file; do ln -sf $file . ; done/' v4l/Makefile
    1.27 +	grep -rl /sbin/depmod * | xargs sed -i 's|/sbin/depmod|/bin/echo|'
    1.28 +	grep -rl i2c_new_probed_device * | xargs sed -i 's/i2c_new_probed_device([^)]*/&, NULL/'
    1.29 +	
    1.30 +	sed -i 's/\.ioctl/.unlocked_ioctl/' linux/drivers/media/dvb/dvb-core/dmxdev.c \
    1.31 +		linux/drivers/media/dvb/dvb-core/dvb_ca_en50221.c \
    1.32 +		linux/drivers/media/dvb/dvb-core/dvb_frontend.c \
    1.33 +		linux/drivers/media/dvb/dvb-core/dvb_net.c \
    1.34 +		linux/drivers/media/dvb/ttpci/av7110*.c \
    1.35 +		linux/drivers/media/dvb/firewire/firedtv-ci.c \
    1.36 +		linux/drivers/media/video/v4l2-dev.c \
    1.37 +		linux/drivers/media/IR/lirc_dev.c \
    1.38 +		linux/drivers/media/IR/ir-lirc-codec.c
    1.39 +	
    1.40 +	sed -i 's/>ioctl)/>unlocked_ioctl)/' linux/drivers/media/IR/lirc_dev.c
    1.41 +	sed -i -e 's|/sbin/lsmod|/bin/lsmod|' \
    1.42 +		-e 's/print | while.*/exec ln -s {} . \\;/' v4l/Makefile
    1.43 +	
    1.44 +	IFS="." ; set -- $kvers ; unset IFS
    1.45 +	cat > v4l/.version << EOF
    1.46 +VERSION=$1
    1.47 +PATCHLEVEL:=$2
    1.48 +SUBLEVEL:=$3
    1.49 +KERNELRELEASE:=$kvers-slitaz
    1.50 +EOF
    1.51 +	[ -x /usr/bin/cook ] && SRCDIR="$WOK/linux/source/linux-$kvers"
    1.52 +	[ -x /usr/bin/tazwok ] && SRCDIR="$WOK/linux/linux-$kvers"
    1.53 +	make SRCDIR=$SRCDIR CONFIG_MEDIA_TUNER_CUSTOMISE=n CONFIG_RADIO_ADAPTERS=n \
    1.54 +		CONFIG_RADIO_MIROPCM20=n CONFIG_MANTIS_CORE=n &&
    1.55 +	make DESTDIR=$DESTDIR install
    1.56 +}
    1.57 +	
    1.58 +# Rules to gen a SliTaz package suitable for Tazpkg.
    1.59 +genpkg_rules()
    1.60 +{
    1.61 +	EXTRAVERSION=_${kvers%.*}
    1.62 +	 
    1.63 +	mkdir -p $fs/lib/modules/$kvers-slitaz/kernel/ 
    1.64 +	
    1.65 +	find $install/lib/modules/$kvers-slitaz -name "*.ko" \
    1.66 +		-exec xz '{}' \; 2> /dev/null
    1.67 +	find $install/lib/modules/$kvers-slitaz -name "*.ko" -exec rm '{}' \;	
    1.68 +	cp -a $install/lib/modules/$kvers-slitaz/kernel/drivers \
    1.69 +		$fs/lib/modules/$kvers-slitaz/kernel/
    1.70 +}
    1.71 +
    1.72 +post_install()
    1.73 +{
    1.74 +	echo "Processing post-install commands..."
    1.75 +	chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz
    1.76 +}
    1.77 +
    1.78 +post_remove()
    1.79 +{
    1.80 +	echo "Processing post-remove commands..."
    1.81 +	depmod -a
    1.82 +}