diff options
author | jlam <jlam@pkgsrc.org> | 2005-09-22 22:00:41 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2005-09-22 22:00:41 +0000 |
commit | d7c679a9a88394a31b58665c115050fcc7241dd9 (patch) | |
tree | b0eba66173752015bad7ef62e20035e5f7b07b70 /mail/nmh | |
parent | 74e2928df6ace002aa3eb10b3d4e39d6a835bf13 (diff) | |
download | pkgsrc-d7c679a9a88394a31b58665c115050fcc7241dd9.tar.gz |
Convert to use options framework.
Diffstat (limited to 'mail/nmh')
-rw-r--r-- | mail/nmh/Makefile | 12 | ||||
-rw-r--r-- | mail/nmh/options.mk | 21 |
2 files changed, 24 insertions, 9 deletions
diff --git a/mail/nmh/Makefile b/mail/nmh/Makefile index a71aa3e3328..c5fe7d37c3b 100644 --- a/mail/nmh/Makefile +++ b/mail/nmh/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.56 2005/03/24 21:12:56 wiz Exp $ +# $NetBSD: Makefile,v 1.57 2005/09/22 22:00:41 jlam Exp $ DISTNAME= nmh-1.0.4 PKGREVISION= 6 @@ -20,11 +20,12 @@ CONFLICTS+= ja-mh6-[0-9]* # Locks supported by `mail.local' are ".lock" and flock(2). .include "../../mk/bsd.prefs.mk" +.include "options.mk" # Mail Transport Agent - either "smtp" or "sendmail" NMH_MTA?= smtp -GNU_CONFIGURE= # defined +GNU_CONFIGURE= yes USE_PKGINSTALL= yes CONFIGURE_ARGS+= --libdir=${PREFIX}/libexec/nmh @@ -88,13 +89,6 @@ CONF_FILES+= ${EGDIR}/${f} ${PKG_SYSCONFDIR}/${f} .endfor .undef f -.if defined(NMH_HASH_BACKUP) && (${NMH_HASH_BACKUP} == yes) -post-configure: - ${MV} ${WRKSRC}/config.h ${WRKSRC}/config.h.bak - ${SED} -e 's/^\(#define *BACKUP_PREFIX\) *.*/\1 "#"/' \ - < ${WRKSRC}/config.h.bak > ${WRKSRC}/config.h -.endif - # This hopefully makes sure the permissions and ownership are right. pre-install: ${INSTALL_DATA_DIR} ${EGDIR} diff --git a/mail/nmh/options.mk b/mail/nmh/options.mk new file mode 100644 index 00000000000..1d379ad1090 --- /dev/null +++ b/mail/nmh/options.mk @@ -0,0 +1,21 @@ +# $NetBSD: options.mk,v 1.1 2005/09/22 22:00:42 jlam Exp $ + +PKG_OPTIONS_VAR= PKG_OPTIONS.nmh +PKG_SUPPORTED_OPTIONS= nmh-backup-hash +PKG_OPTIONS_LEGACY_VARS+= NMH_HASH_BACKUP:nmh-backup-hash + +.include "../../mk/bsd.options.mk" + +### +### Prepend a "#" instead of a "," to the name of a message that is +### "removed" by rmm. +### +.if !empty(PKG_OPTIONS:Mnmh-backup-hash) +post-configure: nmh-hash-backup + +nmh-hash-backup: + cd ${WRKSRC}; file=config.h; \ + ${SED} -e 's/^\(#define *BACKUP_PREFIX\) *.*/\1 "#"/' \ + $$file > $$file.new; \ + ${MV} -f $$file.new $$file +.endif |