summaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2011-07-20 07:13:18 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2011-07-20 07:14:34 +0000
commit880e46cd25d645f654f75468d2a2c9ed3fd489ad (patch)
tree9a0d8619b7a6173f2c57c820a15bba13c997bcb5 /main
parentff98019fb73e2dce4209fab94d46f4036a6189d7 (diff)
downloadaports-880e46cd25d645f654f75468d2a2c9ed3fd489ad.tar.bz2
aports-880e46cd25d645f654f75468d2a2c9ed3fd489ad.tar.xz
main/sysklogd: do not touch runlevels from install scripts
Diffstat (limited to 'main')
-rw-r--r--main/sysklogd/APKBUILD50
-rw-r--r--main/sysklogd/sysklogd.post-install7
-rw-r--r--main/sysklogd/sysklogd.pre-deinstall7
3 files changed, 29 insertions, 35 deletions
diff --git a/main/sysklogd/APKBUILD b/main/sysklogd/APKBUILD
index 233fd071e..17772c461 100644
--- a/main/sysklogd/APKBUILD
+++ b/main/sysklogd/APKBUILD
@@ -1,15 +1,15 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=sysklogd
pkgver=1.5
-pkgrel=13
+pkgrel=14
pkgdesc="System and kernel log daemons"
url="http://www.infodrom.org/projects/sysklogd/"
arch="all"
license="GPL BSD"
subpackages="$pkgname-doc"
depends=
-makedepends=""
-install="sysklogd.post-install sysklogd.pre-deinstall"
+makedepends=
+install=
source="http://www.infodrom.org/projects/$pkgname/download/$pkgname-$pkgver.tar.gz
sysklogd.logrotate
sysklogd.daily
@@ -23,29 +23,37 @@ source="http://www.infodrom.org/projects/$pkgname/download/$pkgname-$pkgver.tar.
syslog.conf
LICENSE"
-build ()
-{
+prepare() {
cd "$srcdir"/$pkgname-$pkgver
-
- for i in ../*.patch ../*.diff; do
- msg "Applying $i..."
- patch -p1 < $i || return 1
+ for i in $source; do
+ case "$i" in
+ *.patch|*.diff)
+ msg "Applying $i..."
+ patch -p1 -i "$srcdir"/$i || return 1
+ ;;
+ esac
done
+}
+
+build() {
+ cd "$srcdir"/$pkgname-$pkgver
+ make CFLAGS="$CFLAGS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE" \
+ || return 1
+}
+
+package() {
+ cd "$srcdir"/$pkgname-$pkgver
+ make INSTALL="install -D" prefix="$pkgdir" install || return 1
- export CFLAGS="$CFLAGS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE"
- make || return 1
- install -d "$pkgdir"/usr/sbin
- install -d "$pkgdir"/usr/share/man/man5
- install -d "$pkgdir"/usr/share/man/man8
- make INSTALL=install prefix="$pkgdir" install
- install -D -m644 ../sysklogd.logrotate \
+ install -D -m644 "$srcdir"/sysklogd.logrotate \
"$pkgdir"/etc/logrotate.d/sysklogd
- install -D -m755 ../sysklogd.daily \
+ install -D -m755 "$srcdir"/sysklogd.daily \
"$pkgdir"/etc/periodic/daily/sysklogd
- install -D -m755 ../sysklogd.initd "$pkgdir"/etc/init.d/sysklogd
- install -D -m644 ../sysklogd.confd "$pkgdir"/etc/conf.d/sysklogd
- install -D -m644 ../syslog.conf "$pkgdir"/etc/syslog.conf
- install -D -m644 ../LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+ install -D -m755 "$srcdir"/sysklogd.initd "$pkgdir"/etc/init.d/sysklogd
+ install -D -m644 "$srcdir"/sysklogd.confd "$pkgdir"/etc/conf.d/sysklogd
+ install -D -m644 "$srcdir"/syslog.conf "$pkgdir"/etc/syslog.conf
+ install -D -m644 "$srcdir"/LICENSE \
+ "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}
md5sums="e053094e8103165f98ddafe828f6ae4b sysklogd-1.5.tar.gz
6bc1d1c65076b104a8f78d0fb4f21db7 sysklogd.logrotate
diff --git a/main/sysklogd/sysklogd.post-install b/main/sysklogd/sysklogd.post-install
deleted file mode 100644
index b4eda2092..000000000
--- a/main/sysklogd/sysklogd.post-install
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-INIT=syslog
-RUNLEVEL=`rc-update show | grep $INIT | awk '{ print $3 }'`
-if [ -n "$RUNLEVEL" ]; then
- rc-update del $INIT $RUNLEVEL &>/dev/null
- rc-update add sysklogd $RUNLEVEL &>/dev/null
-fi
diff --git a/main/sysklogd/sysklogd.pre-deinstall b/main/sysklogd/sysklogd.pre-deinstall
deleted file mode 100644
index 0f985254e..000000000
--- a/main/sysklogd/sysklogd.pre-deinstall
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-INIT=sysklogd
-RUNLEVEL=`rc-update show | grep $INIT | awk '{ print $3 }'`
-if [ -n "$RUNLEVEL" ]; then
- rc-update del $INIT $RUNLEVEL &>/dev/null
- rc-update add syslog $RUNLEVEL &>/dev/null
-fi