wok-6.x rev 8102

Fixed usbip.
author Christopher Rogers <slaxemulator@gmail.com>
date Sat Jan 22 19:20:50 2011 +0000 (2011-01-22)
parents e747219ab3a8
children 493fad6b18aa
files usbip-module/receipt usbip/receipt
line diff
     1.1 --- a/usbip-module/receipt	Sat Jan 22 16:22:19 2011 +0000
     1.2 +++ b/usbip-module/receipt	Sat Jan 22 19:20:50 2011 +0000
     1.3 @@ -12,9 +12,8 @@
     1.4  # Rules to gen a SliTaz package suitable for Tazpkg.
     1.5  genpkg_rules()
     1.6  {
     1.7 -	kver=$(grep "kernel version" ../linux/$(ls ../linux/taz)/.config)
     1.8 -	kver=${kver##* }
     1.9 -	EXTRAVERSION=_$kver
    1.10 +	KERNEL_VERSION=`grep  ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
    1.11 +	EXTRAVERSION=_${KERNEL_VERSION}
    1.12  	cp -a $_pkg/lib $fs
    1.13  }
    1.14  
     2.1 --- a/usbip/receipt	Sat Jan 22 16:22:19 2011 +0000
     2.2 +++ b/usbip/receipt	Sat Jan 22 19:20:50 2011 +0000
     2.3 @@ -7,7 +7,7 @@
     2.4  MAINTAINER="pascal.bellard@slitaz.org"
     2.5  TARBALL="$PACKAGE-$VERSION.tar.gz"
     2.6  DEPENDS="sysfsutils glib libwrap"
     2.7 -BUILD_DEPENDS="sysfsutils-dev lzma libtool glib libwrap libwrap-dev"
     2.8 +BUILD_DEPENDS="sysfsutils-dev lzma libtool glib linux-module-headers libwrap libwrap-dev"
     2.9  WEB_SITE="http://usbip.sourceforge.net/"
    2.10  WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL"
    2.11  TAGS="usb"
    2.12 @@ -21,18 +21,17 @@
    2.13  		tazwok cook linux
    2.14  	fi
    2.15  	LINUX=$WOK/linux/$(ls $WOK/linux/taz)
    2.16 -	kver=$(grep "kernel version" $LINUX/.config)
    2.17 -	kver=${kver##* }
    2.18 +	KERNEL_VERSION=`grep  ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
    2.19  
    2.20 -	mkdir -p ../_pkg/lib/modules/$kver-slitaz/misc
    2.21 +	mkdir -p ../_pkg/lib/modules/$KERNEL_VERSION-slitaz/misc
    2.22  	if [ -d $LINUX/_pkg/lib/modules/*/kernel/drivers/staging/usbip ]; then
    2.23  		echo "Using linux-staging usbip modules."
    2.24  		cp $LINUX/_pkg/lib/modules/*/kernel/drivers/staging/usbip/* \
    2.25 -			../_pkg/lib/modules/$kver-slitaz/misc
    2.26 +			../_pkg/lib/modules/$KERNEL_VERSION-slitaz/misc
    2.27  	else
    2.28  		# Select patch according to kernel version
    2.29 -		patch_dir=${kver%.*}
    2.30 -		[ "$(echo $ker | sed 's/[0-9]//g')" = ".." ] && patch_dir=$kver
    2.31 +		patch_dir=${KERNEL_VERSION%.*}
    2.32 +		[ "$(echo $ker | sed 's/[0-9]//g')" = ".." ] && patch_dir=$KERNEL_VERSION
    2.33  		i=${patch_dir##*.}
    2.34  		while [ ! -e ${patch_dir%.*}.$i ]; do
    2.35  			[ "$i" = "0" ] && break
    2.36 @@ -40,9 +39,9 @@
    2.37  		done
    2.38  		patch_dir=${patch_dir%.*}.$i
    2.39  		cd $patch_dir
    2.40 -		make KSOURCE=$(ls -d $WOK/linux/linux-$kver) || return 1
    2.41 +		make KSOURCE=/usr/src/linux || return 1
    2.42  		for i in *.ko; do
    2.43 -			lzma e $i ../../_pkg/lib/modules/$kver-slitaz/misc/$i.gz
    2.44 +			lzma e $i ../../_pkg/lib/modules/${KERNEL_VERSION}-slitaz/misc/$i.gz
    2.45  		done
    2.46  	fi
    2.47