wok-stable view usbip/receipt @ rev 2722
Add:dmenu
author | Rohit Joshi <jozee@slitaz.org> |
---|---|
date | Fri Apr 24 07:23:26 2009 +0000 (2009-04-24) |
parents | 0fcac9995347 |
children | 3115c291f303 |
line source
1 # SliTaz package receipt.
3 PACKAGE="usbip"
4 VERSION="0.1.7"
5 CATEGORY="system-tools"
6 SHORT_DESC="general USB device sharing system over IP network."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 TARBALL="$PACKAGE-$VERSION.tar.gz"
9 DEPENDS="sysfsutils glib libwrap"
10 BUILD_DEPENDS="sysfsutils-dev lzma libtool glib libwrap libwrap-dev"
11 WEB_SITE="http://usbip.sourceforge.net/"
12 WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
17 cd $src/drivers
18 # get kernel version
19 if [ ! -d $WOK/linux/taz ]; then
20 tazwok cook linux
21 fi
22 LINUX=$WOK/linux/$(ls $WOK/linux/taz)
23 kver=$(grep "kernel version" $LINUX/.config)
24 kver=${kver##* }
26 mkdir -p ../_pkg/lib/modules/$kver-slitaz/misc
27 if [ -d $LINUX/_pkg/lib/modules/*/kernel/drivers/staging/usbip ]; then
28 echo "Using linux-staging usbip modules."
29 cp $LINUX/_pkg/lib/modules/*/kernel/drivers/staging/usbip/* \
30 ../_pkg/lib/modules/$kver-slitaz/misc
31 else
32 # Select patch according to kernel version
33 patch_dir=${kver%.*}
34 [ "$(echo $ker | sed 's/[0-9]//g')" = ".." ] && patch_dir=$kver
35 i=${patch_dir##*.}
36 while [ ! -e ${patch_dir%.*}.$i ]; do
37 [ "$i" = "0" ] && break
38 i=$(($i - 1))
39 done
40 patch_dir=${patch_dir%.*}.$i
41 cd $patch_dir
42 make KSOURCE=$(ls -d $WOK/linux/linux-$kver) || return 1
43 for i in *.ko; do
44 lzma e $i ../../_pkg/lib/modules/$kver-slitaz/misc/$i.gz
45 done
46 fi
48 cd $src/src
49 ./autogen.sh
50 ./configure --prefix=/usr --infodir=/usr/share/info \
51 --mandir=/usr/share/man $CONFIGURE_ARGS &&
52 make &&
53 make DESTDIR=$PWD/../_pkg install
54 }
56 # Rules to gen a SliTaz package suitable for Tazpkg.
57 genpkg_rules()
58 {
59 mkdir -p $fs/usr/lib
60 cp -a $_pkg/usr/bin $fs/usr
61 cp -a $_pkg/usr/share $fs/usr
62 cp -a $_pkg/usr/lib/*.so* $fs/usr/lib
63 # Package all usbip pkgs
64 for i in $(cd $WOK; ls -d usbip-*)
65 do
66 tazwok genpkg $i
67 done
68 }