wok diff linux-libre/receipt @ rev 19010

busybox/fbvnc: wheelmouse support (again)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon Mar 28 18:51:16 2016 +0200 (2016-03-28)
parents 9e01bc6321ea
children e129640c4d69
line diff
     1.1 --- a/linux-libre/receipt	Sun Dec 20 15:13:45 2015 +0100
     1.2 +++ b/linux-libre/receipt	Mon Mar 28 18:51:16 2016 +0200
     1.3 @@ -18,7 +18,6 @@
     1.4  # Rules to configure and make the package.
     1.5  compile_rules()
     1.6  {
     1.7 -	cd $src
     1.8  	# this is code to help update the kernel version faster
     1.9  	#for i in $(grep -l 'WANTED="linux-libre"' $WOK/*/receipt)
    1.10  	#do
    1.11 @@ -42,7 +41,7 @@
    1.12  		[ -d "$AUFSDIR" ] && rm -rf $AUFSDIR
    1.13  		tazwok get-src aufs --target=$AUFSDIR || { report close-bloc; return 1; }
    1.14  	fi
    1.15 -	
    1.16 +
    1.17  	echo "Copying Aufs files and patches..."
    1.18  	cp -a $AUFSDIR/Documentation $AUFSDIR/fs $AUFSDIR/include $src
    1.19  	cp -a $AUFSDIR/*.patch $stuff
    1.20 @@ -90,11 +89,11 @@
    1.21  	# Build bzImage without modules first
    1.22  	cp -f $stuff/$PACKAGE-$VERSION-slitaz.config .config
    1.23  	sed -i 's/CONFIG_MODULES=y/# CONFIG_MODULES is not set/' .config
    1.24 -	
    1.25 +
    1.26  	# We can't keep every driver in staging 
    1.27  	sed -i -e 's/^CONFIG_RTL8192/#&/' \
    1.28 -	       -e 's/^CONFIG_R8187SE/#&/' \
    1.29 -	       -e 's/^CONFIG_RT2870/#&/' .config
    1.30 +		-e 's/^CONFIG_R8187SE/#&/' \
    1.31 +		-e 's/^CONFIG_RT2870/#&/' .config
    1.32  	yes '' | make oldconfig
    1.33  	make $MAKEFLAGS bzImage || { report close-bloc; return 1; }
    1.34  	[ -d $DESTDIR ] || mkdir -p $DESTDIR
    1.35 @@ -114,14 +113,14 @@
    1.36  	[ -s arch/x86/boot/bzImage ] || { report close-bloc; return 1; }
    1.37  	mkdir -p $DESTDIR/boot 2> /dev/null
    1.38  	mv arch/x86/boot/bzImage $DESTDIR/boot/vmlinuz-$VERSION-slitaz
    1.39 -	
    1.40 +
    1.41  	[ ! -x /usr/bin/cook ] && report step "Compressing all modules"
    1.42 -	
    1.43 +
    1.44  	# Compress all modules.
    1.45  	$stuff/gztazmod.sh $DESTDIR/lib/modules/$VERSION-slitaz
    1.46  	ln System.map System.map-modules
    1.47  	ln Module.symvers Module.symvers-modules
    1.48 -	
    1.49 +
    1.50  	if [ ! -x /usr/bin/cook ]; then
    1.51  		report close-bloc
    1.52  	fi
    1.53 @@ -130,54 +129,52 @@
    1.54  # Rules to gen a SliTaz package suitable for Tazpkg.
    1.55  genpkg_rules()
    1.56  {
    1.57 -    local path
    1.58 -    cp -a $install/boot $fs
    1.59 -    # Compress all modules.
    1.60 -    #$stuff/gztazmod.sh $install/lib/modules/$VERSION-slitaz
    1.61 -    path=$fs/lib/modules/$VERSION-slitaz/kernel
    1.62 -    mkdir -p $path
    1.63 -    cp -a $install/lib/modules/$VERSION-slitaz/mo* \
    1.64 +	local path
    1.65 +	cp -a $install/boot $fs
    1.66 +	# Compress all modules.
    1.67 +	#$stuff/gztazmod.sh $install/lib/modules/$VERSION-slitaz
    1.68 +	path=$fs/lib/modules/$VERSION-slitaz/kernel
    1.69 +	mkdir -p $path
    1.70 +	cp -a $install/lib/modules/$VERSION-slitaz/mo* \
    1.71  		$fs/lib/modules/$VERSION-slitaz
    1.72 -    # Get the base modules
    1.73 -    export src
    1.74 -    export _pkg
    1.75 -    mkdir $WOK/$PACKAGE/tmp
    1.76 -    $stuff/list_modules.sh \
    1.77 +	# Get the base modules
    1.78 +	export src
    1.79 +	export _pkg
    1.80 +	mkdir $WOK/$PACKAGE/tmp
    1.81 +	$stuff/list_modules.sh \
    1.82  	$(cat stuff/modules-$VERSION.list) > $WOK/$PACKAGE/tmp/modules.list
    1.83 -    while read module; do
    1.84 -    	dir=$(dirname $module)
    1.85 -    	[ -d $path/$dir ] || mkdir -p $path/$dir
    1.86 -        cp -a $install/lib/modules/$VERSION-slitaz/kernel/$module $path/$dir
    1.87 -    done < $WOK/$PACKAGE/tmp/modules.list
    1.88 -    # Remove unresolved links
    1.89 -    rm -f $fs/lib/modules/$VERSION-slitaz/build
    1.90 -    rm -f $fs/lib/modules/$VERSION-slitaz/source
    1.91 +	while read module; do
    1.92 +		dir=$(dirname $module)
    1.93 +		[ -d $path/$dir ] || mkdir -p $path/$dir
    1.94 +		cp -a $install/lib/modules/$VERSION-slitaz/kernel/$module $path/$dir
    1.95 +	done < $WOK/$PACKAGE/tmp/modules.list
    1.96 +	# Remove unresolved links
    1.97 +	rm -f $fs/lib/modules/$VERSION-slitaz/build
    1.98 +	rm -f $fs/lib/modules/$VERSION-slitaz/source
    1.99  
   1.100 -    # Pack all packages with a kernel module
   1.101 -    for i in $(cd $WOK; grep -l '^WANTED="linux-libre"' */receipt)
   1.102 -    do
   1.103 -	[ ! -d "$install/lib/modules/$VERSION-slitaz" ] && return 1
   1.104 -	cook ${i%/receipt}
   1.105 -    done
   1.106 -    
   1.107 -    # Check and echo any module in kernel .config that's not added to 
   1.108 -    # one of linux-* pkgs
   1.109 -    export PACKAGE
   1.110 -	$stuff/check_modules.sh 
   1.111 +	# Pack all packages with a kernel module
   1.112 +	for i in $(cd $WOK; grep -l '^WANTED="linux-libre"' */receipt); do
   1.113 +		[ ! -d "$install/lib/modules/$VERSION-slitaz" ] && return 1
   1.114 +		cook ${i%/receipt}
   1.115 +	done
   1.116 +
   1.117 +	# Check and echo any module in kernel .config that's not added to
   1.118 +	# one of linux-* pkgs
   1.119 +	export PACKAGE
   1.120 +	$stuff/check_modules.sh
   1.121  }
   1.122  
   1.123  # Pre and post install commands for Tazpkg.
   1.124  post_install()
   1.125  {
   1.126 -    echo "Processing post-install commands..."
   1.127 -    chroot "$1/" depmod -a $VERSION-slitaz
   1.128 -    # GRUB stuff.
   1.129 -    if [ -f "$1/boot/grub/menu.lst" ]; then
   1.130 -    	root_dev=`cat "$1/boot/grub/menu.lst" | grep root= | sed 's/.*root=\([^ ]*\).*/\1/' | head -n 1`
   1.131 -		grub_dev=`cat "$1/boot/grub/menu.lst" | grep "root (" | head -n 1`
   1.132 +	chroot "$1/" depmod -a $VERSION-slitaz
   1.133 +	# GRUB stuff.
   1.134 +	if [ -f "$1/boot/grub/menu.lst" ]; then
   1.135 +		root_dev=$(cat "$1/boot/grub/menu.lst" | grep root= | sed 's/.*root=\([^ ]*\).*/\1/' | head -n 1)
   1.136 +		grub_dev=$(cat "$1/boot/grub/menu.lst" | grep "root (" | head -n 1)
   1.137  		# Add new kernel entry in case of upgrade for installed system.
   1.138  		if ! grep -q $PACKAGE-$VERSION-slitaz "$1/boot/grub/menu.lst"; then
   1.139 -    		cat >> "$1/boot/grub/menu.lst" << EOT
   1.140 +			cat >> "$1/boot/grub/menu.lst" <<EOT
   1.141  
   1.142  title SliTaz GNU/Linux (Kernel $VERSION-slitaz)
   1.143  $grub_dev
   1.144 @@ -185,7 +182,7 @@
   1.145  EOT
   1.146  		fi
   1.147  		# Display information message.
   1.148 -    	cat <<EOT
   1.149 +		cat <<EOT
   1.150  ----
   1.151  GRUB is installed, these tree lines must be in your /boot/grub/menu.lst:
   1.152  
   1.153 @@ -194,6 +191,6 @@
   1.154  kernel /boot/vmlinuz-$VERSION-slitaz root=$root_dev
   1.155  ----
   1.156  EOT
   1.157 -    fi
   1.158 -    true
   1.159 +	fi
   1.160 +	true
   1.161  }