aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorehaupt <ehaupt@FreeBSD.org>2014-02-21 18:03:29 +0800
committerehaupt <ehaupt@FreeBSD.org>2014-02-21 18:03:29 +0800
commitfebf6da37e999dc66451337a3d06f520db2f2b61 (patch)
tree400cbd5367ea54ddecc38338ad128cc1f8fc26d7 /mail
parent13c0f99cf97eb156b6278c7c1707658d3bb5b236 (diff)
downloadfreebsd-ports-gnome-febf6da37e999dc66451337a3d06f520db2f2b61.tar.gz
freebsd-ports-gnome-febf6da37e999dc66451337a3d06f520db2f2b61.tar.zst
freebsd-ports-gnome-febf6da37e999dc66451337a3d06f520db2f2b61.zip
- Support staging
- Use optionsng
Diffstat (limited to 'mail')
-rw-r--r--mail/smtprc/Makefile40
-rw-r--r--mail/smtprc/pkg-plist4
2 files changed, 20 insertions, 24 deletions
diff --git a/mail/smtprc/Makefile b/mail/smtprc/Makefile
index 248dd6383edb..cae0d932fe90 100644
--- a/mail/smtprc/Makefile
+++ b/mail/smtprc/Makefile
@@ -10,16 +10,19 @@ EXTRACT_SUFX= .tgz
MAINTAINER= mich@FreeBSD.org
COMMENT= A scanner for open SMTP relays
-.if defined(WITH_GUI)
+OPTIONS_DEFINE= DOCS GUI
+
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MGUI}
RUN_DEPENDS= p5-Tk>=0:${PORTSDIR}/x11-toolkits/p5-Tk
PLIST_SUB+= WITHGUI=""
.else
PLIST_SUB+= WITHGUI="@comment "
.endif
-NO_STAGE= yes
pre-fetch:
-.if defined(WITH_GUI)
+.if ${PORT_OPTIONS:MGUI}
@${ECHO_MSG} ""
@${ECHO_MSG} "Installed with GUI"
@${ECHO_MSG} ""
@@ -34,26 +37,17 @@ post-patch:
s,gcc,${CC},g" ${WRKSRC}/Makefile
do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
- ${MKDIR} ${PREFIX}/etc/${PORTNAME}
- ${INSTALL_DATA} ${WRKSRC}/auto.conf ${PREFIX}/etc/${PORTNAME}/auto.conf.sample
- ${INSTALL_DATA} ${WRKSRC}/email.tmpl ${PREFIX}/etc/${PORTNAME}/email.tmpl.sample
- ${INSTALL_DATA} ${WRKSRC}/rcheck.conf ${PREFIX}/etc/${PORTNAME}/rcheck.conf.sample
- ${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${PREFIX}/man/man1
-.if defined(WITH_GUI)
- ${INSTALL_SCRIPT} ${WRKSRC}/gsmtprc ${PREFIX}/bin
- ${INSTALL_MAN} ${WRKSRC}/gsmtprc.1 ${PREFIX}/man/man1
-.endif
-
-.if !defined(NOPORTDOCS)
- ${MKDIR} ${DOCSDIR}
- ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}/README
-.endif
-
-.if defined(WITH_GUI)
-MAN1= smtprc.1 gsmtprc.1
-.else
-MAN1= smtprc.1
+ ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
+ ${MKDIR} ${STAGEDIR}${PREFIX}/etc/${PORTNAME}
+ ${INSTALL_DATA} ${WRKSRC}/auto.conf ${STAGEDIR}${PREFIX}/etc/${PORTNAME}/auto.conf.sample
+ ${INSTALL_DATA} ${WRKSRC}/email.tmpl ${STAGEDIR}${PREFIX}/etc/${PORTNAME}/email.tmpl.sample
+ ${INSTALL_DATA} ${WRKSRC}/rcheck.conf ${STAGEDIR}${PREFIX}/etc/${PORTNAME}/rcheck.conf.sample
+ ${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${STAGEDIR}${MANPREFIX}/man/man1
+.if ${PORT_OPTIONS:MGUI}
+ ${INSTALL_SCRIPT} ${WRKSRC}/gsmtprc ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_MAN} ${WRKSRC}/gsmtprc.1 ${STAGEDIR}${PREFIX}/man/man1
.endif
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}/README
.include <bsd.port.mk>
diff --git a/mail/smtprc/pkg-plist b/mail/smtprc/pkg-plist
index 233a15ec015a..f60142b77e56 100644
--- a/mail/smtprc/pkg-plist
+++ b/mail/smtprc/pkg-plist
@@ -2,7 +2,9 @@ bin/smtprc
etc/smtprc/auto.conf.sample
etc/smtprc/email.tmpl.sample
etc/smtprc/rcheck.conf.sample
-@dirrm etc/smtprc
+man/man1/smtprc.1.gz
+%%WITHGUI%%man/man1/gsmtprc.1.gz
%%WITHGUI%%bin/gsmtprc
%%PORTDOCS%%share/doc/smtprc/README
%%PORTDOCS%%@dirrm share/doc/smtprc
+@dirrm etc/smtprc