jobcore/krb5/PKGBUILD

99 lines
3.1 KiB
Bash

#!/usr/bin/bash
# JOBoRun : Jwm OpenBox Obarun RUNit
# Maintainer : Joe Bo Run <joborun@disroot.org>
# PkgSource : url="https://git.disroot.org/joborun-pkg/jobcore/src/branch/main/$pkgname"
# Website : https://pozol.eu
#-----------------------------------------| DESCRIPTION |---------------------------------------
pkgname=krb5
_pkgvermajor=1.21
pkgver=1.21.3
pkgrel=01
pkgdesc='The Kerberos network authentication system w/o systemd'
url='https://web.mit.edu/kerberos/'
depends=(bash e2fsprogs glibc keyutils libldap libverto-module-base openssl
lmdb libcom_err.so libkeyutils.so libss.so libverto.so)
makedepends=(perl bison gettext)
provides=(
libgssapi_krb5.so
libgssrpc.so
libk5crypto.so
libkadm5clnt_mit.so
libkadm5srv_mit.so
libkdb5.so
libkdb_ldap.so
libkrad.so
libkrb5.so
libkrb5support.so
)
backup=(
'etc/krb5.conf'
'var/lib/krb5kdc/kdc.conf'
)
options=('!emptydirs')
source=(https://web.mit.edu/kerberos/dist/krb5/${_pkgvermajor}/${pkgname}-${pkgver}.tar.gz{,.asc})
# 0001-krb5-config_LDFLAGS.patch::https://github.com/krb5/krb5/commit/0bfd22feb6493f34fdc894daaf680c3a2f2e7784.patch)
prepare() {
cd ${pkgname}-${pkgver}
# # https://github.com/krb5/krb5/commit/0bfd22feb6493f34fdc894daaf680c3a2f2e7784
# # https://krbdev.mit.edu/rt/Ticket/Display.html?id=9057
# patch -Np1 < "${srcdir}"/0001-krb5-config_LDFLAGS.patch
# FS#25384
sed -i "/KRB5ROOT=/s/\/local//" src/util/ac_check_krb5.m4
}
build() {
cd ${pkgname}-${pkgver}/src
export CFLAGS+=" -fPIC -fno-strict-aliasing -fstack-protector-all"
export CPPFLAGS+=" -I/usr/include/et"
./configure --prefix=/usr \
--sbindir=/usr/bin \
--sysconfdir=/etc \
--localstatedir=/var/lib \
--enable-shared \
--with-system-et \
--with-system-ss \
--disable-rpath \
--without-tcl \
--enable-dns-for-realm \
--with-lmdb \
--with-ldap \
--with-system-verto
make
}
package() {
cd ${pkgname}-${pkgver}/src
make DESTDIR="${pkgdir}" EXAMPLEDIR=/usr/share/doc/${pkgname}/examples install
# Fix FS#29889
install -m 644 plugins/kdb/ldap/libkdb_ldap/kerberos.{ldif,schema} \
"${pkgdir}/usr/share/doc/${pkgname}/examples"
install -Dpm 644 config-files/krb5.conf -t "${pkgdir}/etc"
install -Dpm 644 config-files/kdc.conf -t "${pkgdir}/var/lib/krb5kdc"
install -Dm 644 util/ac_check_krb5.m4 -t "${pkgdir}/usr/share/aclocal"
install -Dm 644 "${srcdir}"/${pkgname}-${pkgver}/NOTICE \
"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
#---- arch license gpg-key & sha256sums ----
arch=(x86_64)
license=(custom)
validpgpkeys=('2C732B1C0DBEF678AB3AF606A32F17FD0055C305' # Tom Yu <tlyu@mit.edu>
'C4493CB739F4A89F9852CBC20CBA08575F8372DF') # Greg Hudson <ghudson@mit.edu>
sha256sums=(b7a4cd5ead67fb08b980b21abd150ff7217e85ea320c9ed0c6dadd304840ad35 # krb5-1.21.3.tar.gz
85047c935fe949ef2e275885451b168557b923dd13a5aab0ef8fe6acd27b94d7) # krb5-1.21.3.tar.gz.asc
## 9e905308b73de7e49e5f54e9663b35900c0c197db3fa055bf011c8d7194023eb krb5-1.21.3-01-x86_64.pkg.tar.lz