wok diff libcap/receipt @ rev 16255

Up socat (2.0.0-b7)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Fri Apr 04 16:24:21 2014 +0000 (2014-04-04)
parents 6c3718ca17b6
children 132cb5109518
line diff
     1.1 --- a/libcap/receipt	Sat Nov 09 17:34:23 2013 +0000
     1.2 +++ b/libcap/receipt	Fri Apr 04 16:24:21 2014 +0000
     1.3 @@ -9,29 +9,25 @@
     1.4  TARBALL="$PACKAGE-$VERSION.tar.bz2"
     1.5  WEB_SITE="http://sites.google.com/site/fullycapable/"
     1.6  WGET_URL="http://ftp.df.lth.se/pub/linux/libs/security/linux-privs/libcap2/$TARBALL"
     1.7 +HOST_ARCH="i486 arm"
     1.8  
     1.9 -DEPENDS="linux glibc-base attr"
    1.10 -BUILD_DEPENDS="slitaz-toolchain gperf pam pam-dev attr-dev perl"
    1.11 +DEPENDS="attr"
    1.12 +BUILD_DEPENDS="gperf pam-dev attr-dev"
    1.13 +
    1.14 +# Handle cross compilation.
    1.15 +case "$ARCH" in
    1.16 +	i?86) BUILD_DEPENDS="$BUILD_DEPENDS perl"  ;;
    1.17 +	arm*) ARCH_ARGS="CC=$HOST_SYSTEM-gcc BUILD_CC=gcc" ;;
    1.18 +esac
    1.19  
    1.20  # Rules to configure and make the package.
    1.21  compile_rules()
    1.22  {
    1.23 -#	if [ ! -d $WOK/linux/taz ]; then
    1.24 -#		if [ -x /usr/bin/cook ]; then
    1.25 -#			cook linux
    1.26 -#		else
    1.27 -#			tazwok cook linux
    1.28 -#		fi
    1.29 -#	fi
    1.30 -	cd $src
    1.31 -#	sed -i -e s/'\\n'/"' -e '1i"/g -e 's/| indent -kr//' libcap/Makefile
    1.32 -#	mkdir -p libcap/include/attr
    1.33 -#	ln -s $WOK/linux/$(ls $WOK/linux/taz)/include/linux/xattr.h \
    1.34 -#		libcap/include/attr/
    1.35 -
    1.36 -	# Linux headers are now sanitized properly for userspace, so patch libcap
    1.37 -	# Based on http://bugs.gentoo.org/265304 and http://www.mail-archive.com/pld-cvs-commit@lists.pld-linux.org/msg183775.html
    1.38 -	[ $(grep -c "#define __user" < libcap/include/sys/capability.h) -eq 0 ] || patch -p1 << EOP
    1.39 +	# Linux headers are now sanitized properly for userspace, so patch 
    1.40 +	# libcap. Based on http://bugs.gentoo.org/265304 and 
    1.41 +	# http://www.mail-archive.com/pld-cvs-commit@lists.pld-linux.org/msg183775.html
    1.42 +	[ $(grep -c "#define __user" < libcap/include/sys/capability.h) -eq 0 ] \
    1.43 +		|| patch -p1 << EOP
    1.44  --- libcap-2.16/libcap/include/sys/capability.h.orig	2009-03-05 11:19:00.000000000 -0300
    1.45  +++ libcap-2.16/libcap/include/sys/capability.h	2009-03-05 11:19:38.000000000 -0300
    1.46  @@ -22,18 +22,6 @@ extern "C" {
    1.47 @@ -54,9 +50,9 @@
    1.48   
    1.49   /*
    1.50  EOP
    1.51 -
    1.52 -	sed -i -e 's/\} __user \*cap_user_/\} \*cap_user_/g' libcap/include/linux/capability.h
    1.53 -	make DYNAMIC=yes &&
    1.54 +	sed -i -e 's/\} __user \*cap_user_/\} \*cap_user_/g' \
    1.55 +		libcap/include/linux/capability.h
    1.56 +	make DYNAMIC=yes ${ARCH_ARGS} &&
    1.57  	make RAISE_SETCAP=no DESTDIR=$DESTDIR install
    1.58  }
    1.59