summaryrefslogtreecommitdiff
path: root/community/ndisc6/PKGBUILD
blob: 99bbe8325655eeb902dd50247e8c992c81b6d3ad (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
# $Id: PKGBUILD 90526 2013-05-13 00:18:50Z seblu $
# Maintainer: Sébastien Luttringer
# Contributor: Chris Brannon <chris@the-brannons.com>
# Contributor: Mark Smith <markzzzsmith@yahoo.com.au>

pkgname=ndisc6
pkgver=1.0.2
pkgrel=7
pkgdesc='Collection of IPv6 networking utilities'
arch=('i686' 'x86_64')
url='http://www.remlab.net/ndisc6/'
license=('GPL')
depends=('glibc' 'perl')
makedepends=('glibc' 'gcc')
options=(!emptydirs)
install=$pkgname.install
source=("http://www.remlab.net/files/ndisc6/$pkgname-$pkgver.tar.bz2"
	      'rdnssd.service')
md5sums=('50cb4c19606cf6ff2b7388e71832f579'
         '88a290cbcf51ac5e10ed5f995a8ba4b9')

prepare() {
  # patch invalid path
  sed -ri 's,PATH=/sbin:/bin,PATH=/sbin:/bin:/usr/sbin:/usr/bin,' \
    $pkgname-$pkgver/rdnssd/merge-hook.in
}

build() {
  cd $pkgname-$pkgver
  ./configure \
    --prefix=/usr \
    --sbindir=/usr/bin \
    --localstatedir=/var \
    --sysconfdir=/etc
  make
}

package() {
  cd $pkgname-$pkgver
  make DESTDIR="$pkgdir" install
  install -Dm644 "$srcdir/rdnssd.service" "$pkgdir/usr/lib/systemd/system/rdnssd.service"
  install -Dm644 /dev/null "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
  echo 'd /run/rdnssd 0755 nobody root' > "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
}

# vim:set ts=2 sw=2 et: