wok-next annotate collectd/receipt @ rev 20349
Up gsmartcontrol (0.9.0)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Nov 18 19:01:01 2017 +0100 (2017-11-18) |
parents | 9600efd55009 |
children | d43bf7aae921 |
rev | line source |
---|---|
pascal@20188 | 1 # SliTaz package receipt v2. |
pascal@11218 | 2 |
pascal@11218 | 3 PACKAGE="collectd" |
pascal@13207 | 4 VERSION="5.1.0" |
pascal@11218 | 5 CATEGORY="network" |
pascal@11218 | 6 SHORT_DESC="System Stattistics Collection Daemon" |
pascal@11218 | 7 MAINTAINER="erjo@slitaz.org" |
pascal@15001 | 8 LICENSE="GPL2" |
pascal@11218 | 9 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@11218 | 10 WEB_SITE="http://collectd.org" |
pascal@11218 | 11 WGET_URL="http://collectd.org/files/$TARBALL" |
pascal@11218 | 12 CONFIG_FILES="/etc/collectd/collectd.conf" |
pascal@11218 | 13 |
pascal@20212 | 14 BUILD_DEPENDS="slitaz-toolchain rrdtool-dev perl" |
pascal@20188 | 15 SPLIT="collectd collectd-dev" |
pascal@13207 | 16 |
pascal@11218 | 17 # Rules to configure and make the package. |
pascal@11218 | 18 compile_rules() |
pascal@11218 | 19 { |
pascal@20212 | 20 sed -i 's|_BSD_SOURCE|_DEFAULT_SOURCE|' src/*.c configure* |
pascal@11218 | 21 ./configure \ |
pascal@11218 | 22 --prefix=/usr \ |
pascal@11218 | 23 --localstatedir=/var \ |
pascal@11218 | 24 --enable-interface \ |
pascal@11218 | 25 --enable-load \ |
pascal@11218 | 26 --enable-cpu \ |
pascal@11218 | 27 --enable-disk \ |
pascal@11218 | 28 --enable-logfile \ |
pascal@11218 | 29 --enable-syslog \ |
pascal@11218 | 30 --enable-csv\ |
pascal@11218 | 31 --enable-rrdtool \ |
pascal@11218 | 32 --with-librrdtool=/usr/include \ |
pascal@11218 | 33 --disable-all-plugins \ |
pascal@11218 | 34 --sysconfdir=/etc/collectd \ |
pascal@11218 | 35 --localstatedir=/var \ |
pascal@11218 | 36 $CONFIGURE_ARGS && |
pascal@13207 | 37 make && make DESTDIR=$DESTDIR install |
pascal@11218 | 38 } |
pascal@11218 | 39 |
pascal@11218 | 40 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@11218 | 41 genpkg_rules() |
pascal@11218 | 42 { |
pascal@20188 | 43 case $PACKAGE in |
pascal@20188 | 44 collectd) |
pascal@20188 | 45 DEPENDS="rrdtool perl" |
pascal@20188 | 46 mkdir -p $fs/usr/lib/collectd \ |
pascal@20188 | 47 $fs/usr/share \ |
pascal@20188 | 48 $fs/etc/init.d |
pascal@11218 | 49 |
pascal@20188 | 50 cp -a $install/etc $fs/ |
pascal@20188 | 51 cp -a $install/var $fs/ |
pascal@20188 | 52 cp -a $install/usr/share/collectd $fs/usr/share |
pascal@20188 | 53 cp -a $install/usr/bin $fs/usr |
pascal@20188 | 54 cp -a $install/usr/sbin $fs/usr |
pascal@20188 | 55 cp -a $install/usr/lib/*.so* $fs/usr/lib |
pascal@20188 | 56 cp -a $install/usr/lib/collectd/*.so $fs/usr/lib/collectd |
pascal@20188 | 57 cp -a $install/usr/lib/perl5 $fs/usr/lib |
pascal@11218 | 58 |
pascal@20188 | 59 # Add init script and fixes |
pascal@20188 | 60 install -g root -o root -m 0755 $stuff/collectd $fs/etc/init.d |
pascal@20188 | 61 chmod 0644 $fs/etc/collectd/* |
pascal@20188 | 62 ;; |
pascal@20188 | 63 collectd-dev) |
pascal@20188 | 64 CAT="network|System Stattistics Collection Daemon" |
pascal@20188 | 65 DEPENDS="pkg-config" |
pascal@20188 | 66 mkdir -p $fs/usr/lib |
pascal@20188 | 67 cp -a $install/usr/include $fs/usr |
pascal@20188 | 68 cp -a $install/usr/lib/*.*a $fs/usr/lib |
pascal@20188 | 69 cp -a $install/usr/lib/pkgconfig $fs/usr/lib |
pascal@20188 | 70 ;; |
pascal@20188 | 71 esac |
pascal@11218 | 72 } |