#!/bin/sh set -e name=alpine daversionappend=debathena1 dir=$(cd "$(dirname "$0")"; pwd) hack_package () { add_build_depends libhesiod-dev add_build_depends libkrb5-dev # alpine versions prior to 1.10 have broken krb5 detection. # Versions prior to 1.0 can be patched in a similar fashion (though # not with exactly the same patch) but we're not currently # integrating those. case $version in 1.0*) patch -p1 < $dir/alpine-1.00-krb5-configure.patch ;; esac # Integrate krb4 support. tar -C imap/src -xzf "$dir/kerberos4-patches.tar.Z" patch -p1 < $dir/alpine-1.00-krb4-build.patch echo 'DEFAULTAUTHENTICATORS+=krb' >> imap/src/osdep/unix/Makefile # Ensure newly created mail directories in AFS are private. patch -p1 < $dir/alpine-1.00-creatdir.patch # Integrate Hesiod support. patch -p1 < $dir/alpine-1.00-hesiod.patch # Turn on Hesiod and krb4 suppport in the build. configure_flags='alpine_c_client_cflags="-DHESIOD -DKERBEROS" alpine_c_client_ldflags="-lhesiod" LIBS="-lhesiod -lkrb4"' if grep -Fq DEB_CONFIGURE_EXTRA_FLAGS debian/rules; then echo "DEB_CONFIGURE_EXTRA_FLAGS += $configure_flags" >> debian/rules else perl -0pe "s|./configure|./configure $configure_flags|m or die" -i debian/rules fi append_description <