wok-next view lxc/receipt @ rev 20390
Up cookutils (1018), evilvte
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Dec 01 16:24:18 2017 +0200 (2017-12-01) |
parents | c44a7d2a11ed |
children | d43bf7aae921 |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="lxc"
4 VERSION="2.1.1"
5 CATEGORY="system-tools"
6 SHORT_DESC="Userspace control package for Linux Containers."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="LGPL2.1"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://linuxcontainers.org/"
11 WGET_URL="${WEB_SITE}downloads/$TARBALL"
13 BUILD_DEPENDS="libcap-dev util-linux-getopt"
14 SPLIT="lxc-dev"
16 # Rules to configure and make the package.
17 compile_rules()
18 {
19 ./configure --prefix=/usr --mandir=/usr/share/man \
20 --sysconfdir=/etc \
21 --libexec=/usr/lib/$PACKAGE \
22 --localstatedir=/var \
23 $CONFIGURE_ARGS &&
24 make &&
25 make DESTDIR=$DESTDIR install
26 }
28 # Rules to gen a SliTaz package suitable for Tazpkg.
29 genpkg_rules()
30 {
31 case $PACKAGE in
32 lxc)
33 DEPENDS="libcap perl util-linux-getopt linux-netfilter \
34 linux-bridge iptables bridge-utils"
35 mkdir -p $fs/usr/share $fs/var/lib/lxc
36 cp -a $install/usr/share/lxc $fs/usr/share
37 cp -a $install/usr/bin $fs/usr
38 cp -a $install/usr/lib $fs/usr
39 rm -rf $fs/usr/lib/pkgconfig
40 cp -a $install/etc $fs
41 cp -a $install/var $fs
42 sed -i -e 's/^is_set(/zgrep() { zcat | grep "$@"; }\n\n&/' \
43 -e 's/\(.*\$GREP .*\)\(\$CONFIG.*\)/\1< \2/' \
44 $fs/usr/bin/lxc-checkconfig
45 chmod +x $fs/usr/bin/lxc-*
46 ;;
47 lxc-dev)
48 DEPENDS="lxc pkg-config"
49 mkdir -p $fs/usr/lib
50 cp -a $install/usr/include $fs/usr
51 cp -a $install/usr/lib/pkgconfig $fs/usr/lib
52 ;;
53 esac
54 }
56 post_install_lxc()
57 {
58 [ -n "$1" ] && return
59 lxc-checkconfig | tee /dev/stderr | grep -q required && cat <<EOT
61 You have to fix your kernel configuration first to use lxc !
63 EOT
64 }