Skip to content
Snippets Groups Projects
Verified Commit c888c5dc authored by Tomas Krizek's avatar Tomas Krizek
Browse files

packaging: add files for arch

parent 0bc3e7f1
No related branches found
No related tags found
1 merge request!884Packaging: automate build in OBS
# Maintainer: Tomas Krizek <tomas.krizek@nic.cz>
# Maintainer: Bruno Pagani <archange@archlinux.org>
# Contributor: Ondřej Surý <ondrej@sury.org>
# Contributor: Julian Brost <julian@0x4a42.net>
# Contributor: Oleander Reis <oleander@oleander.cc>
# Contributor: Otto Sabart <seberm[at]gmail[dot]com>
pkgname=knot
pkgver=__VERSION__
pkgrel=1
pkgdesc="High-performance authoritative-only DNS server"
arch=('x86_64')
url="https://www.knot-dns.cz/"
license=('GPL3')
depends=('lmdb' 'liburcu' 'protobuf-c' 'fstrm' 'libedit' 'systemd' 'libcap-ng' 'gnutls' 'libidn2')
optdepends=('python: for pykeymgr')
backup=('etc/knot/knot.conf')
source=("${pkgname}_${pkgver}.orig.tar.xz"
"${pkgname}.service"
"${pkgname}.sysusers"
"${pkgname}.tmpfiles.arch")
sha256sums=('SKIP'
'SKIP'
'SKIP'
'SKIP')
validpgpkeys=('742FA4E95829B6C5EAC6B85710BB7AF6FEBBD6AB') # Daniel Salzman <daniel.salzman@nic.cz>
build() {
cd ${pkgname}-${pkgver}
./configure \
--prefix=/usr \
--sbindir=/usr/bin \
--sysconfdir=/etc \
--localstatedir=/var/lib \
--libexecdir=/usr/lib/knot \
--with-rundir=/run/knot \
--with-storage=/var/lib/knot \
--enable-recvmmsg \
--enable-dnstap \
--enable-systemd \
--enable-reuseport \
--disable-silent-rules
make
}
check() {
cd ${pkgname}-${pkgver}
make check
}
package() {
cd ${pkgname}-${pkgver}
make DESTDIR="${pkgdir}" install
# Don’t keep those empty dir, manage them with systemd-tmpfiles instead
rmdir "${pkgdir}"/{var/{lib/{knot/,},},run/{knot/,}}
rm "${pkgdir}"/etc/knot/example.com.zone
mv "${pkgdir}"/etc/knot/{knot.sample.conf,knot.conf}
cd ..
install -Dm644 ${pkgname}.service -t "${pkgdir}"/usr/lib/systemd/system/
install -Dm644 ${pkgname}.tmpfiles.arch "${pkgdir}"/usr/lib/tmpfiles.d/${pkgname}.conf
install -Dm644 ${pkgname}.sysusers "${pkgdir}"/usr/lib/sysusers.d/${pkgname}.conf
}
../common/knot.service
\ No newline at end of file
u knot - "Knot DNS Daemon User"
d /run/knot 0755 knot knot - -
d /var/lib/knot 0700 knot knot - -
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment