diff options
Diffstat (limited to 'package/rsyslog')
-rw-r--r-- | package/rsyslog/Config.in | 6 | ||||
-rw-r--r-- | package/rsyslog/S01rsyslog | 38 | ||||
-rw-r--r-- | package/rsyslog/rsyslog.mk | 26 |
3 files changed, 70 insertions, 0 deletions
diff --git a/package/rsyslog/Config.in b/package/rsyslog/Config.in new file mode 100644 index 000000000..2503f711f --- /dev/null +++ b/package/rsyslog/Config.in @@ -0,0 +1,6 @@ +config BR2_PACKAGE_RSYSLOG + bool "rsyslog" + help + Rsyslog is a powerful and flexible syslog implementation + + http://www.rsyslog.com diff --git a/package/rsyslog/S01rsyslog b/package/rsyslog/S01rsyslog new file mode 100644 index 000000000..8c28e02f5 --- /dev/null +++ b/package/rsyslog/S01rsyslog @@ -0,0 +1,38 @@ +#!/bin/sh +# +# Starts rsyslog. +# + +start() { + echo -n "Starting rsyslog daemon: " + umask 077 + start-stop-daemon -S -q -p /var/run/rsyslogd.pid --exec /usr/sbin/rsyslogd + echo "OK" +} +stop() { + echo -n "Stopping rsyslog daemon: " + start-stop-daemon -K -q -p /var/run/rsyslogd.pid + echo "OK" +} +restart() { + stop + start +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart|reload) + restart + ;; + *) + echo $"Usage: $0 {start|stop|restart}" + exit 1 +esac + +exit $? + diff --git a/package/rsyslog/rsyslog.mk b/package/rsyslog/rsyslog.mk new file mode 100644 index 000000000..af7ac2ed8 --- /dev/null +++ b/package/rsyslog/rsyslog.mk @@ -0,0 +1,26 @@ +############################################################# +# +# rsyslog +# +############################################################# +RSYSLOG_VERSION = 5.8.0 +RSYSLOG_SITE = http://rsyslog.com/files/download/rsyslog/ +RSYSLOG_DEPENDENCIES = zlib + +# Build after Busybox +ifeq ($(BR2_PACKAGE_BUSYBOX),y) + RSYSLOG_DEPENDENCIES += busybox +endif + +define RSYSLOG_INSTALL_CONF_SCRIPT + $(INSTALL) -m 0755 -D package/rsyslog/S01rsyslog \ + $(TARGET_DIR)/etc/init.d/S01rsyslog + [ -f $(TARGET_DIR)/etc/rsyslog.conf ] || \ + $(INSTALL) -m 0644 -D $(@D)/rsyslog.conf \ + $(TARGET_DIR)/etc/rsyslog.conf + mkdir -p $(TARGET_DIR)/etc/rsyslog.d +endef + +RSYSLOG_POST_INSTALL_TARGET_HOOKS += RSYSLOG_INSTALL_CONF_SCRIPT + +$(eval $(call AUTOTARGETS,package,rsyslog)) |