summaryrefslogtreecommitdiff
path: root/mandos/PKGBUILD
blob: 38a88e7bd2d1df7ebd620a226395e57cfed73424 (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
# Maintainer: Erich Eckner <arch at eckner dot net>
arch=('x86_64')
pkgbase='mandos'
pkgname=('mandos-server' 'mandos-client-nokey')
pkgdesc='system for allowing servers with encrypted root file systems to reboot unattended and/or remotely'
pkgver='1.8.16'
pkgrel=5
url='https://www.recompile.se/mandos'
license=('GPL')

source=("https://ftp.recompile.se/pub/${pkgbase}/${pkgbase}_${pkgver}.orig.tar.gz"
        "https://ftp.recompile.se/pub/${pkgbase}/${pkgbase}_${pkgver}.orig.tar.gz.asc")

sha512sums=('5ca8a822e2562212f6f5ef6dea9af8c38ee3e53cb7162e45ba9de19eca394199000e39edd96224bb4be5a53c3627e4f4ca7bb0ccc7fe098869b239c3fc472ff5'
            'SKIP')

validpgpkeys=('153A37F10BBA0435987F2C4A72232973CA34C2C4')

depends=(avahi)
makedepends=(docbook-xsl)

prepare() {
  cd "$srcdir/$pkgbase-$pkgver"
  sed -i '
    s@^\s\+install\b@\0 -D@
    s@\bsbin\b@bin@g
    434 s@^\s\+@\0install -d $(MANDIR)/man8\n\0@
    440 s@^\s\+@\0install -d $(MANDIR)/man5\n\0@
    513 s@^\s\+@\0install -d $(MANDIR)/man8\n\0@
    /docbook\.xsl/ s@/stylesheet/nwalsh/@/'"$(
      ls /usr/share/xml/docbook/ \
      | grep -wF xsl-stylesheets \
      | grep -vwF nons \
      | sort -V \
      | tail -n1
    )"'/@
  ' Makefile
}

build() {
  cd "$srcdir/$pkgbase-$pkgver"
  make all doc
  find . -type f \( -name '*.8' -o -name '*.8mandos' -o -name '*.5' \) -exec sed -i 's@^\s\+@@' {} +
}

_package() {
  cd "$srcdir/$pkgbase-$pkgver"
  make install-$1 DESTDIR="$pkgdir"
}

package_mandos-server() {
  arch=(any)
  _pinned_dependencies=(
  )
  _package server
}

package_mandos-client-nokey() {
  _pinned_dependencies=(
    'gcc-libs=14.1.1+r1+g43b730b9134'
    'glibc>=2.38'
    'gnutls=3.8.5'
    'libavahi-common.so=3'
    'libavahi-core.so=7'
    'libglib-2.0.so=0'
    'libgpgme.so=11'
    'libnl-3.so=200'
    'libnl-route-3.so=200'
  )
  depends+=("${_pinned_dependencies[@]}")
  _package client-nokey
}