APKBUILD 1.7 KB
Newer Older
Natanael Copa's avatar
Natanael Copa committed
1 2
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=openrc
3 4
pkgver=0.6.0
pkgrel=0
Natanael Copa's avatar
Natanael Copa committed
5 6 7
pkgdesc="OpenRC manages the services, startup and shutdown of a host"
url="http://roy.marples.name/openrc"
license='BSD-2'
8
depends=""
Natanael Copa's avatar
Natanael Copa committed
9
subpackages="$pkgname-doc $pkgname-dev"
10
install="$pkgname.post-install $pkgname.post-upgrade"
Natanael Copa's avatar
Natanael Copa committed
11
source="http://roy.marples.name/downloads/$pkgname/$pkgname-$pkgver.tar.bz2
12
	openrc-0.4.3-mkmntdirs.patch
13
	localmount.patch
14
	hostname.initd
15
	hwdrivers.initd
16 17
	keymaps.initd
	modules.initd
18
	modloop.initd
19
	networking.initd
20
	local.start
Natanael Copa's avatar
Natanael Copa committed
21 22
	"

23
prepare() {
Natanael Copa's avatar
Natanael Copa committed
24
	cd "$srcdir/$pkgname-$pkgver"
25 26 27 28
	for i in ../*.patch; do
		msg "Applying $i..."
		patch -p1 < $i || return 1
	done
29
}
30

31 32
build() {
	cd "$srcdir/$pkgname-$pkgver"
33
	make || return 1
34 35 36 37
}

package() {
	cd "$srcdir/$pkgname-$pkgver"
38 39 40 41 42
	make DESTDIR="$pkgdir/" install

	# we cannot have anything turned on by default
	rm -f "$pkgdir"/etc/runlevels/*/*

43
	# we still use our ifup/ifdown based net config
44
	rm -f "$pkgdir"/etc/conf.d/network "$pkgdir"/etc/init.d/network
45 46 47 48 49 50

	# we override some of the scripts
	for i in ../*.initd; do
		j=${i##*/}
		install -Dm755 $i "$pkgdir"/etc/init.d/${j%.initd}
	done
Natanael Copa's avatar
Natanael Copa committed
51

52
	install -Dm644 ../local.start "$pkgdir"/etc/conf.d/local.start
Natanael Copa's avatar
Natanael Copa committed
53 54
}

55
md5sums="2b30959bc68595cdf389cb9f62105ec6  openrc-0.6.0.tar.bz2
56
8c2c1c2ee0509b63966b7187a2079f4b  openrc-0.4.3-mkmntdirs.patch
57
fa1809cd59cc0559a163bc6adc7398f6  localmount.patch
58
c32e15b0858eef708497e7ee6355a055  hostname.initd
59
b1e64885f301166df30be3e3cf5338ff  hwdrivers.initd
60
33ca3e558c42cdd17adccbc7807298f7  keymaps.initd
61
098a1f16812f56fcb56eb6b6f0fa31f6  modules.initd
62
4c69d1c6a84cbe0195496c14a757579b  modloop.initd
63
c05fc2ea5d771ca68cbb8d91494c9a2b  networking.initd
64
0a615d93aab691364c03539c3b496dcc  local.start"