pkgname=krb5 pkgver=1.21.3 pkgrel=1 pkgdesc="The Kerberos network authentication system" arch=('x86_64') url="https://web.mit.edu/kerberos/" license=('custom') depends=('bash' 'e2fsprogs' 'glibc' 'keyutils' 'libldap' 'openssl' 'perl' 'systemd') backup=(etc/krb5.conf var/lib/krb5kdc/kdc.conf) options=('!emptydirs') install=${pkgname}.install source=(https://kerberos.org/dist/krb5/${pkgver%.*}/${pkgname}-${pkgver}.tar.gz krb5-kadmind.service krb5-kdc.service krb5-kpropd.service) sha256sums=(b7a4cd5ead67fb08b980b21abd150ff7217e85ea320c9ed0c6dadd304840ad35 5f2b7844e2c9767c6de41a465bd34f00f4b23c6a63c571d7e52ad5f83ea28743 b9c7295d275f9e5fe0d9f3d1e0742e0aa1a27f68ed3dfb43aca3146d3b052f71 90589d9a4d836f59a2dca535ac00d931a30d0cb687642dd9781230f512e955ba) prepare() { cd ${pkgname}-${pkgver}/src sed -i -e '/eq 0/{N;s/12 //}' plugins/kdb/db2/libdb2/test/run.test } build() { cd ${pkgname}-${pkgver}/src export CFLAGS+=" -fPIC -fno-strict-aliasing -fstack-protector-all" export CPPFLAGS+=" -I/usr/include/et" local configure_args=( --sysconfdir=/etc --localstatedir=/var/lib --runstatedir=/run --with-system-et --with-system-ss --with-system-verto=no --enable-dns-for-realm --disable-rpath --with-ldap ${configure_options} ) ./configure ${configure_args[@]} make } package() { cd ${pkgname}-${pkgver}/src make DESTDIR=${pkgdir} install install -vdm755 ${pkgdir}/usr/share/doc/${pkgname}-${pkgver} cp -vfr ../doc -T ${pkgdir}/usr/share/doc/${pkgname}-${pkgver} install -Dpm 644 config-files/krb5.conf -t ${pkgdir}/etc install -Dpm 644 config-files/kdc.conf -t ${pkgdir}/var/lib/krb5kdc install -vDm644 ${srcdir}/krb5-kdc.service ${pkgdir}/usr/lib/systemd/system/krb5-kdc.service install -vDm644 ${srcdir}/krb5-kpropd.service ${pkgdir}/usr/lib/systemd/system/krb5-kpropd.service install -vDm644 ${srcdir}/krb5-kadmind.service ${pkgdir}/usr/lib/systemd/system/krb5-kadmind.service }