#!/bin/bash # sendmail # # Douglas Thrift # # $Id$ name=sendmail version=8.14.0 revision=0 categories=(base mail) description='Reliable, highly configurable mail transfer agent with utilities' url='http://www.sendmail.org/' depends=('base/glibc') sources=(`site_sendmail` sendmail.patch) without=(milter) function build() { gnu_patch sendmail.patch || return $? local site=devtools/Site/site.config.m4 user=`whoami` cat > $site <<-EOF define(\`confDONT_INSTALL_CATMAN') EOF for category in INC LIB MAN UBIN; do cat >> $site <<-EOF define(\`conf${category}OWN', \`$user') define(\`conf${category}GRP', \`$user') EOF done if [[ -z $without_milter ]]; then cat >> $site <<-EOF APPENDDEF(\`conf_libmilter_ENVDEF', \`-DMILTER') APPENDDEF(\`conf_sendmail_ENVDEF', \`-DMILTER') EOF fi gmake && GROFF_NO_SGR=1 gmake -C doc/op op.txt || return $? if [[ -z $without_milter ]]; then gmake -C libmilter || return $? fi install -dv $package/usr/{{,s}bin,lib{,exec},share/man/man{1,5,8}} gmake install DESTDIR=$package || return $? for directory in @(mail.local|rmail); do gmake -C $directory force-install DESTDIR=$package || return $? done for chapter in 1 5 8; do install -v -m 0644 !(contrib)/*.$chapter $package/usr/share/man/man$chapter done if [[ -z $without_milter ]]; then gmake -C libmilter install DESTDIR=$package || return $? fi }