summaryrefslogtreecommitdiff
path: root/community/nsd/PKGBUILD
blob: 994a2591d48176e8ff909620a7c1f0bb062267f0 (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
# $Id: PKGBUILD 74075 2012-07-19 14:27:58Z bisson $
# Maintainer: Kaiting Chen <kaitocracy@gmail.com>
# Maintainer: Gaetan Bisson <bisson@archlinux.org>
# Contributor: Roberto Alsina <ralsina@kde.org>

pkgname=nsd
pkgver=3.2.12
pkgrel=1
pkgdesc='Authoritative only, high performance and simple DNS server'
url='http://www.nlnetlabs.nl/nsd/'
license=('BSD')
depends=('openssl')
makedepends=('flex')
arch=('i686' 'x86_64' 'mips64el')
source=("http://www.nlnetlabs.nl/downloads/${pkgname}/${pkgname}-${pkgver}.tar.gz"
        'service')
sha1sums=('dd8606a05525f6a493dfacb7ddfa7e1fa3c6a85b'
          '29a74ce922b3991dd65ae5254bafa0a308d915e9')

install=install

build() {
	cd "${srcdir}/${pkgname}-${pkgver}"

	./configure \
		--prefix=/ \
		--exec-prefix=/usr \
		--datarootdir=/usr/share \
		--with-pidfile=/run/nsd.pid \

	make
}

package() {
	cd "${srcdir}/${pkgname}-${pkgver}"

	make DESTDIR="${pkgdir}" install

	install -d "${pkgdir}"/etc/rc.d
	ln -s ../../usr/sbin/nsdc "${pkgdir}"/etc/rc.d/nsd
	install -Dm644 ../service "${pkgdir}"/usr/lib/systemd/system/nsd.service

	rm doc/differences.pdf
	install -d "${pkgdir}"/usr/share/{doc,licenses}/"${pkgname}"
	install -m644 doc/* "${pkgdir}"/usr/share/doc/"${pkgname}"
	ln -s ../../doc/"${pkgname}"/LICENSE "${pkgdir}"/usr/share/licenses/"${pkgname}"/LICENSE
}