blob: 6929dc119e30545e7b623065c5dd5d35bc856da7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=pingu
pkgver=1.3
pkgrel=0
pkgdesc="Small daemon that pings hosts and executes a script when status change"
url="http://git.alpinelinux.org/cgit/pingu"
arch="all"
license="GPL"
makedepends="libev-dev lua-dev"
depends=
subpackages="$pkgname-doc lua-pingu:_lua mtu"
source="pingu-$pkgver.tar.gz::https://github.com/ncopa/pingu/archive/v$pkgver.tar.gz
pingu.initd
"
_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
}
build() {
cd "$_builddir"
./configure \
--prefix=/usr \
--localstatedir=/var \
--sysconfdir=/etc \
|| return 1
make || return 1
}
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
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install install-lua
install -m644 -D pingu.conf "$pkgdir"/etc/pingu/pingu.conf
install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
}
mtu() {
pkgdesc="Utility to detect MTU"
mkdir -p "$subpkgdir"/usr
mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}
_lua() {
pkgdesc="lua module for pingu client"
mkdir -p "$subpkgdir"/usr/lib
mv "$pkgdir"/usr/lib "$pkgdir"/usr/share "$subpkgdir"/usr/
}
md5sums="0d33bfe66a428ace44bdf968c825ab12 pingu-1.3.tar.gz
70f56b0f506e1c2e725d0ec062667c32 pingu.initd"
sha256sums="971f3a68d201b2217bb7b4918ad349b0ef5ff19b7015439a174d2bf2d201ad42 pingu-1.3.tar.gz
cf3197f457d7a5955662417da8a7908a01934bfb5e97cf46c14a1ceab93ad47c pingu.initd"
sha512sums="e2489720268ef7c2e3b1619fd7f1f968db8e546b49769c6f40b12d7db49d39445329df4a6a12d1b5319aee4a89e0665bb188609a85d4b7495f9d5719d37409de pingu-1.3.tar.gz
b14b4b1ae218c53abec94d4c177327a5a7ed1833cb0160a83c683766d638759c1ed12c73d4cee93a2c09b6296affea20cf15f4dd5a5f2e910ac6f8d7e896ceb4 pingu.initd"
|