summaryrefslogtreecommitdiff
path: root/nonsystemd/sysvinit/PKGBUILD
blob: 22bc5e6e8f38379dfe87f1e33bd3152ab65f0d3b (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
# Maintainer: David P. <megver83@parabola.nu>
# Maintainer: Luke Shumaker <lukeshu@parabola.nu>
# Contributor: Omar Vega Ramos <ovruni@gnu.org.pe>

pkgname=sysvinit
pkgver=2.96
pkgrel=1
pkgdesc='Linux System V Init'
url='http://www.nongnu.org/sysvinit/'
arch=('i686' 'x86_64' 'armv7h')
license=('GPL')
depends=('glibc' 'initscripts')
provides=('init')
conflicts=(${provides[@]})
source=(#"https://download.savannah.gnu.org/releases/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig}
        "http://download.savannah.gnu.org/releases/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig})
sha256sums=('2a2e26b72aa235a23ab1c8471005f890309ce1196c83fbc9413c57b9ab62b587'
            'SKIP')
validpgpkeys=('146BF1D0D20B006B10299B4CFA3EC79A4C0C11CC') # Jesse Smith <jsmith@resonatingmedia.com>

build() {
    cd "$pkgname-$pkgver"
    make
}

package() {
    cd "$pkgname-$pkgver"

    install -d "$pkgdir/usr/bin"
    ln -s usr/bin "$pkgdir/bin"
    ln -s usr/bin "$pkgdir/sbin"
    make ROOT="$pkgdir" install
    rm "$pkgdir/bin" "$pkgdir/sbin"

    install -d "$pkgdir/usr/share/licenses/$pkgname"
    install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/LICENSE"

    local rmprogs=(
        # provided by e2fsprogs
        logsave
        # provided by util-linux
        last
        lastb
        mesg
        sulogin
        utmpdump
        wall
        # provided by procps-ng
        pidof
    )
    cd "$pkgdir"
    local prog
    for prog in "${rmprogs[@]}"; do
        rm usr/bin/"$prog" usr/share/man/man?/"$prog".?
    done

    # old Arch Linux sysvinit would have split out fstab-decode,
    # killall5, and bootlogd into a separate sysvinit-tools package.
    # Unfortunately, because sysvinit-tools provided pidof, procps-ng
    # still conflicts=(sysvinit-tools).
}