summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobby Workman <rw@rlworkman.net>2010-05-12 17:46:10 +0200
committerMichiel van Wessem <michiel@slackbuilds.org>2010-05-12 17:46:10 +0200
commite55ae3829506211ac34dc526112080ac3fec2223 (patch)
tree1eb9ef21573f58fcbfee1d90785d444792589fe1
parent845f1d5f4ddbcc801ece016cbdcb1167c8958f64 (diff)
downloadslackbuilds-e55ae3829506211ac34dc526112080ac3fec2223.tar.gz
system/ulogd: Updated for version 1.24
-rw-r--r--system/ulogd/README7
-rw-r--r--system/ulogd/rc.ulogd8
-rw-r--r--system/ulogd/slack-desc14
-rw-r--r--system/ulogd/ulogd.SlackBuild41
4 files changed, 52 insertions, 18 deletions
diff --git a/system/ulogd/README b/system/ulogd/README
index f7f66caf54..4d0b38d032 100644
--- a/system/ulogd/README
+++ b/system/ulogd/README
@@ -1,11 +1,12 @@
ulogd is a handy add-on for netfilter/iptables which allows you to
have your firewall logs put somewhere besides the main system logs
-Be sure to check the documentation in /usr/doc/ulogd-$VERSION
+Be sure to check the documentation in /usr/doc/ulogd-1.24
You get an init script free of charge: /etc/rc.d/rc.ulogd --
You'll just have to make it executable and call it from one of your
init scripts. Also, be sure to have a look at /etc/ulogd.conf;
it works fine with the default, but you might want to customize it...
-You'll also need to make sure you have the ULOG target support in
-your kernel config.
+If you don't want to build with mysql and/or sqlite3 support, you can
+run the script with either or both of these specified:
+ WITH_MYSQL=no WITH_SQLITE=no
diff --git a/system/ulogd/rc.ulogd b/system/ulogd/rc.ulogd
index ba7bcc3568..52ba800d53 100644
--- a/system/ulogd/rc.ulogd
+++ b/system/ulogd/rc.ulogd
@@ -6,19 +6,19 @@
ulogd_start() {
if [ -x /usr/sbin/ulogd ]; then
- /bin/echo "Starting ulogd daemon: /usr/sbin/ulogd "
+ echo "Starting ulogd daemon: /usr/sbin/ulogd "
/usr/sbin/ulogd -d 2> /dev/null
- /bin/sleep 1
+ sleep 1
fi
}
ulogd_stop() {
- /bin/killall ulogd 2> /dev/null
+ killall ulogd 2> /dev/null
}
ulogd_restart() {
ulogd_stop
- /bin/sleep 1
+ sleep 1
ulogd_start
}
diff --git a/system/ulogd/slack-desc b/system/ulogd/slack-desc
index 680f95269b..85a4784991 100644
--- a/system/ulogd/slack-desc
+++ b/system/ulogd/slack-desc
@@ -6,14 +6,14 @@
# customary to leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
-ulogd: ulogd (Harald Welte's Userspace Logging Daemon)
+ulogd: ulogd (Userspace Logging Daemon)
ulogd:
ulogd: ulogd is a handy add-on for netfilter/iptables which allows you to
ulogd: have your firewall logs put somewhere besides the main system logs
-ulogd: Be sure to check the documentation in /usr/doc/ulogd-$VERSION
+ulogd: Be sure to check the documentation in /usr/doc/ulogd-*
+ulogd:
+ulogd:
+ulogd:
+ulogd:
+ulogd:
ulogd:
-ulogd: You get an init script free of charge: /etc/rc.d/rc.ulogd --
-ulogd: You'll just have to make it executable and call it from one of your
-ulogd: init scripts. Also, have a look at /etc/ulogd.conf - it works fine
-ulogd: with the default, but you might want to customize it.
-ulogd:
diff --git a/system/ulogd/ulogd.SlackBuild b/system/ulogd/ulogd.SlackBuild
index 8ba20de525..74f7582737 100644
--- a/system/ulogd/ulogd.SlackBuild
+++ b/system/ulogd/ulogd.SlackBuild
@@ -25,7 +25,7 @@
PRGNAM=ulogd
VERSION=1.24
ARCH=${ARCH:-i486}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
CWD=$(pwd)
@@ -33,10 +33,30 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
+WITH_MYSQL=${WITH_MYSQL:-yes}
+WITH_SQLITE=${WITH_SQLITE:-yes}
+
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+fi
+
+if [ "$WITH_MYSQL" != "yes" ]; then
+ do_mysql="--without-mysql"
+else
+ do_mysql="--with-mysql"
+fi
+
+if [ "$WITH_SQLITE" != "yes" ]; then
+ do_sqlite="--without-sqlite3"
+else
+ do_sqlite="--with-sqlite3"
fi
set -e
@@ -53,15 +73,28 @@ chmod -R a-s,u+w,go+r-w .
CFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \
- --localstatedir=/var
+ --localstatedir=/var \
+ --build=$ARCH-slackware-linux \
+ $do_mysql \
+ $do_sqlite
+
+# "mysql_config --libs" shows -rdynamic, but it causes the mysql plugin
+# to barf on compilation (and running too, according to bug reports in
+# other distributions), so we'll remove that flag
+if [ "$WITH_MYSQL" = "yes" ]; then
+ sed -i 's%-rdynamic %%' Rules.make
+fi
make
make install DESTDIR=$PKG
( cd $PKG
- find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
- find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
+ xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
+ xargs strip --strip-unneeded 2> /dev/null
)
install -D -m 0755 $CWD/rc.ulogd $PKG/etc/rc.d/rc.ulogd.new