wok-6.x annotate distcc/receipt @ rev 13832
distcc: fix compile_rules
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Jan 07 13:02:55 2013 +0100 (2013-01-07) |
parents | d40213305781 |
children | 999e4277a8ac |
rev | line source |
---|---|
erjo@4825 | 1 # SliTaz package receipt. |
erjo@4825 | 2 |
erjo@4825 | 3 PACKAGE="distcc" |
erjo@4825 | 4 VERSION="3.1" |
erjo@4825 | 5 CATEGORY="development" |
erjo@4825 | 6 SHORT_DESC="Distributed compilation for C/C++" |
erjo@4825 | 7 MAINTAINER="erjo@slitaz.org" |
erjo@4825 | 8 DEPENDS="popt lzo" |
pascal@11852 | 9 BUILD_DEPENDS="popt-dev lzo-dev python-dev" |
erjo@4825 | 10 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
erjo@4825 | 11 WEB_SITE="http://distcc.org" |
erjo@4825 | 12 WGET_URL="http://distcc.googlecode.com/files/$TARBALL" |
erjo@4825 | 13 |
erjo@4825 | 14 # Rules to configure and make the package. |
erjo@4825 | 15 compile_rules() |
erjo@4825 | 16 { |
pascal@13832 | 17 export CFLAGS="-Wno-error=unused-but-set-variable" |
erjo@4825 | 18 cd $src |
erjo@4825 | 19 ./configure \ |
erjo@4825 | 20 --prefix=/usr \ |
erjo@4825 | 21 --sysconfdir=/etc \ |
erjo@4825 | 22 --mandir=/usr/share/man \ |
erjo@4825 | 23 $CONFIGURE_ARGS && |
erjo@4825 | 24 make && make DESTDIR=$PWD/_pkg install |
erjo@4825 | 25 } |
erjo@4825 | 26 |
erjo@4825 | 27 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@4825 | 28 genpkg_rules() |
erjo@4825 | 29 { |
erjo@9468 | 30 mkdir -p $fs/usr \ |
erjo@9468 | 31 $fs/var/log/distccd \ |
erjo@9468 | 32 $fs/var/run/distccd \ |
erjo@9468 | 33 $fs/etc/init.d |
erjo@9468 | 34 |
erjo@4825 | 35 cp -a $_pkg/usr/bin $fs/usr |
erjo@9468 | 36 cp -a $_pkg/etc/distcc $fs/etc |
erjo@9468 | 37 |
erjo@9468 | 38 echo '127.0.0.1' >> $fs/etc/distcc/clients.allow |
erjo@9468 | 39 |
erjo@9468 | 40 install -o root -g root $stuff/distccd $fs/etc/init.d |
erjo@4825 | 41 } |
erjo@4825 | 42 |
erjo@9468 | 43 post_install() |
erjo@9468 | 44 { |
erjo@9468 | 45 if ! grep -q nagios $1/etc/passwd; then |
erjo@9468 | 46 echo -n "Adding user/group nagios..." |
erjo@9468 | 47 chroot $1/ addgroup -S distcc |
erjo@9468 | 48 chroot $1/ adduser -S -D -H -G distcc distcc |
erjo@9468 | 49 status |
erjo@9468 | 50 fi |
erjo@9468 | 51 |
erjo@9468 | 52 # Fix perms for files and directories |
erjo@9468 | 53 chroot $1/ chown -R distcc.distcc /var/log/distccd \ |
erjo@9468 | 54 /var/run/distccd |
erjo@9468 | 55 |
erjo@9468 | 56 cat <<EOF |
erjo@9468 | 57 ---- |
erjo@9468 | 58 Now you can: |
pascal@11694 | 59 * Just run '/etc/init.d/distccd start' to start daemon. |
pascal@11694 | 60 * Add distccd to RUN_DAEMONS in /etc/rcS.conf to run distccd àat boot time. |
erjo@9468 | 61 * Allow cliets in /etc/distcc/clients.allow |
erjo@9468 | 62 ---- |
erjo@9468 | 63 |
erjo@9468 | 64 EOF |
erjo@9468 | 65 } |