blob: dd3bfb97e882f3f73f4b748cd22cb56085d44f52 (
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
# Maintainer (Artix): artoo <artoo@manjaro.org>
# Contributor (Artix): williamh <williamh@gentoo.org>
# Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
_url="https://github.com/OpenRC/openrc/archive"
pkgname=openrc
pkgver=0.34.3
pkgrel=1.parabola1
pkgdesc="Gentoo's universal init system"
arch=('i686' 'x86_64' 'armv7h')
url="https://wiki.gentoo.org/wiki/Project:OpenRC"
license=('BSD2')
depends=('psmisc' 'pam')
optdepends=('netifrc: Network Interface Management Scripts'
'networkmanager-openrc: NetworkManager')
conflicts=('systemd-sysvcompat' 'sysvinit')
replaces=('sysvinit')
install=${pkgname}.install
backup=('etc/rc.conf'
'etc/conf.d/consolefont'
'etc/conf.d/keymaps'
'etc/conf.d/hostname'
'etc/conf.d/modules'
'etc/conf.d/hwclock')
options=('!emptydirs')
source=("${pkgname}-${pkgver}.tar.gz::${_url}/${pkgver}.tar.gz"
"${pkgname}.logrotate"
'openrc-install.hook'
'openrc-remove.hook')
sha256sums=('8e4c1f99727b7b91766fcd65e0a303240528bf0cb123a65e33adc904c67bf2bd'
'0b44210db9770588bd491cd6c0ac9412d99124c6be4c9d3f7d31ec8746072f5c'
'1d4d31a7275660e7b23778e6fceb0714cab8ed2793b04aa004b01d8e7bcd43bd'
'cbb4d00262a55a508114cb31e3903350be2cff748a4fb5e120dc745292e3987e')
_args=(
SYSCONFDIR=/etc
PREFIX=/usr
SBINDIR=/usr/bin
LIBEXECDIR=/usr/lib/rc
MKSELINUX=no
MKPAM=pam
MKTERMCAP=ncurses
MKNET=no
MKSYSVINIT=yes
BRANDING='Parabola'
)
prepare(){
cd "${srcdir}/${pkgname}-${pkgver}"
sed -e "s|/sbin|/usr/bin|g" -i support/sysvinit/inittab
sed -i 's:0444:0644:' mk/sys.mk
}
build(){
cd "${srcdir}/${pkgname}-${pkgver}"
make "${_args[@]}"
}
package() {
cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" "${_args[@]}" install
install -Dm644 "${srcdir}/${pkgname}.logrotate" "${pkgdir}/etc/logrotate.d/${pkgname}"
sed -e 's/#unicode="NO"/unicode="YES"/' \
-e 's/#rc_logger="NO"/rc_logger="YES"/' \
-i "${pkgdir}/etc/rc.conf"
install -d ${pkgdir}/usr/lib/rc/cache
# getty
sed -e 's|#baud=""|baud="38400"|' \
-e 's|#term_type="linux"|term_type="linux"|' \
-e 's|#agetty_options=""|agetty_options=""|' \
-i ${pkgdir}/etc/conf.d/agetty
for num in 1 2 3 4 5 6;do
cp -v ${pkgdir}/etc/conf.d/agetty ${pkgdir}/etc/conf.d/agetty.tty$num
ln -sf /etc/init.d/agetty ${pkgdir}/etc/init.d/agetty.tty$num
ln -sf /etc/init.d/agetty.tty$num ${pkgdir}/etc/runlevels/default/agetty.tty$num
done
# alpm hooks
for h in openrc-{install,remove}.hook;do
install -Dm644 ${srcdir}/$h ${pkgdir}/usr/share/libalpm/hooks/$h
done
# license
install -Dm644 ${srcdir}/${pkgname}-${pkgver}/LICENSE "$pkgdir/usr/share/licenses/${pkgname}/LICENSE"
}
|