wok-next rev 11427
Add: barnyard2
author | Eric Joseph-Alexandre <erjo@slitaz.org> |
---|---|
date | Thu Dec 15 09:43:10 2011 +0100 (2011-12-15) |
parents | 956ac96b4a1b |
children | eb21a2b317a2 |
files | barnyard2/receipt |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/barnyard2/receipt Thu Dec 15 09:43:10 2011 +0100 1.3 @@ -0,0 +1,52 @@ 1.4 +# SliTaz package receipt. 1.5 + 1.6 +PACKAGE="barnyard2" 1.7 +VERSION="1.9" 1.8 +CATEGORY="system" 1.9 +SHORT_DESC="Output spool reader for Snort" 1.10 +MAINTAINER="erjo@slitaz.org" 1.11 +WEB_SITE="http://www.securixlive.com/barnyard2/" 1.12 +TARBALL="$PACKAGE-$VERSION.tar.gz" 1.13 +WGET_URL="http://www.securixlive.com/download/barnyard2/$TARBALL" 1.14 + 1.15 +DEPENDS="libpcap" 1.16 +BUILD_DEPENDS="libpcap-dev" 1.17 + 1.18 +# Rules to configure and make the package. 1.19 +compile_rules() 1.20 +{ 1.21 + cd $src 1.22 + ./configure --sysconfdir=/etc/barnyard2 $CONFIGURE_ARGS && make && make install 1.23 +} 1.24 + 1.25 +# Rules to gen a SliTaz package suitable for Tazpkg. 1.26 +genpkg_rules() 1.27 +{ 1.28 + 1.29 + cp -a $install/* $fs 1.30 + 1.31 + mkdir -p /var/log/barnyard2 1.32 +} 1.33 + 1.34 +# Post install commands 1.35 +post_install() 1.36 +{ 1.37 + echo "Processing post install commands..." 1.38 + 1.39 + # addgroup snort if needed 1.40 + if ! grep -q 'snort:' $1/etc/group; then 1.41 + echo -n "Adding group Snort..." 1.42 + chroot $1/ /bin/addgroup snort 1.43 + status 1.44 + fi 1.45 + # adduser snort if needed 1.46 + if ! grep -q 'snort:' $1/etc/passwd; then 1.47 + echo -n "Adding user Snort..." 1.48 + chroot $1/ /bin/adduser -s /bin/false -h /dev/null \ 1.49 + -g "Snort Daemon user" -H -D -S -G snort snort 1.50 + status 1.51 + fi 1.52 + 1.53 + chroot $1/ chown snort.snort /var/log/barnyard2 1.54 +} 1.55 +