aboutsummaryrefslogtreecommitdiffstats
path: root/community/socklog
diff options
context:
space:
mode:
authorStuart Cardall <developer@it-offshore.co.uk>2016-08-18 20:46:53 +0000
committerCarlo Landmeter <clandmeter@gmail.com>2016-08-21 22:24:04 +0200
commit5c9f3ca3e307be53b45beeed2ce1626f38008625 (patch)
tree919836fe454e953f46685adf8228b0401280d4b6 /community/socklog
parent6a00a953ba02bab6440a2c784e7db37c6eaeace1 (diff)
downloadaports-5c9f3ca3e307be53b45beeed2ce1626f38008625.tar.bz2
aports-5c9f3ca3e307be53b45beeed2ce1626f38008625.tar.xz
testing/[various]: move to community
albatross-themes apk-post-messages autossh bitcoin btrbk entr ffmpegthumbnailer firejail firetools fwsnort gnome-colors imapsync inetutils-syslogd inotify-tools-inc isync junit ktsuss letsencrypt-nosudo libmbim libndp libqmi libteam mini-sendmail modemmanager namecoin networkmanager nginx-naxsi numix-themes nxapi opencl-headers opencl-icd-loader opus-tools perl-authen-ntlm perl-bit-vector perl-data-uniqid perl-file-copy-recursive perl-getopt-argvfile perl-io-tee perl-iptables-chainmgr perl-iptables-parse perl-module-scandeps perl-par-dist perl-par-packer perl-par perl-uri-escape psad py-crcmod py-graphviz py-lz4 py-opencl py-opengl-accelerate runit secpwgen secure-delete socklog spacefm tinyssh udevil virt-viewer virtualbricks whois wrk xpra zram-init
Diffstat (limited to 'community/socklog')
-rw-r--r--community/socklog/APKBUILD49
-rw-r--r--community/socklog/socklog.post-install22
2 files changed, 71 insertions, 0 deletions
diff --git a/community/socklog/APKBUILD b/community/socklog/APKBUILD
new file mode 100644
index 0000000000..bda6ad8fa3
--- /dev/null
+++ b/community/socklog/APKBUILD
@@ -0,0 +1,49 @@
+# Contributor: Stuart Cardall <developer@it-offshore.co.uk>
+# Maintainer: Stuart Cardall <developer@it-offshore.co.uk>
+pkgname=socklog
+pkgver=2.1.0
+pkgrel=2
+pkgdesc="System and kernel logging services for runit"
+url="http://smarden.org/socklog/"
+arch="all"
+license="BSD"
+install="$pkgname.post-install"
+subpackages="$pkgname-doc"
+source="http://smarden.org/$pkgname/$pkgname-$pkgver.tar.gz"
+
+_builddir="$srcdir"/admin/socklog-$pkgver/src
+
+prepare() {
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
+ echo "$CC $CFLAGS" > conf-cc
+ echo "$CC $LDFLAGS" > conf-ld
+}
+
+build() {
+ cd "$_builddir"
+ make
+}
+
+package() {
+ cd "$_builddir"
+ install -d "$pkgdir"/usr/bin
+ install -d "$pkgdir"/sbin
+ for i in socklog socklog-conf; do
+ install -m755 "$i" "$pkgdir"/sbin/$i || return 1
+ done
+ for i in socklog-check tryto uncat; do
+ install -m755 "$i" "$pkgdir"/usr/bin/$i || return 1
+ done
+ install -d "$pkgdir"/usr/share/man/man8
+ cd .. && cp -rf man/* "$pkgdir"/usr/share/man/man8/
+}
+
+md5sums="5d0e8e28c9329ad3af982c5241df9ff1 socklog-2.1.0.tar.gz"
+sha256sums="aa869a787ee004da4e5509b5a0031bcc17a4ab4ac650c2ce8d4e488123acb455 socklog-2.1.0.tar.gz"
+sha512sums="920ce5e661a6a3d970fa77ee3c228d48699ea03530be2b43b7517458b25e31a0a7f352ece2d076c715b6d34dbb26b424b48eb0f55b9bcd0355b74d3e34c77ac7 socklog-2.1.0.tar.gz"
diff --git a/community/socklog/socklog.post-install b/community/socklog/socklog.post-install
new file mode 100644
index 0000000000..de53f609d3
--- /dev/null
+++ b/community/socklog/socklog.post-install
@@ -0,0 +1,22 @@
+#!/bin/sh
+# Alpine Linux post-install script for socklog
+# Copyright 2015 Stuart Cardall (developer@it-offshore.co.uk)
+# Distributed under the terms of the GNU General Public License, v2 or later #
+
+adduser -S -D -H -h /var/empty -s /sbin/nologin -g log log 2>/dev/null
+if [ ! -d /etc/sv/socklog-unix ]; then
+ socklog-conf unix nobody log
+ mkdir -p /etc/service
+ ln -s /etc/sv/socklog-unix /etc/service/
+fi
+
+if [ ! -f /etc/sv/socklog-unix/run ]; then
+cat > /etc/sv/socklog-unix/run <<EOF
+#!/bin/sh
+/etc/init.d/syslog stop &>/dev/null
+exec 2>&1
+exec chpst -Unobody socklog unix /dev/log
+EOF
+fi
+
+exit 0