aboutsummaryrefslogtreecommitdiff
path: root/devel/hs-darcs/Makefile
diff options
context:
space:
mode:
authorOliver Braun <obraun@FreeBSD.org>2003-04-26 16:40:49 +0000
committerOliver Braun <obraun@FreeBSD.org>2003-04-26 16:40:49 +0000
commit654d0e54990cf59e161a4e259ac00e92f07477d8 (patch)
tree849abe5671b5ae9f9e8b350f20147656244bef20 /devel/hs-darcs/Makefile
parent69298fa0d91acc3f2c94599e830bcd20cf415100 (diff)
downloadports-654d0e54990cf59e161a4e259ac00e92f07477d8.tar.gz
ports-654d0e54990cf59e161a4e259ac00e92f07477d8.zip
Notes
Diffstat (limited to 'devel/hs-darcs/Makefile')
-rw-r--r--devel/hs-darcs/Makefile25
1 files changed, 24 insertions, 1 deletions
diff --git a/devel/hs-darcs/Makefile b/devel/hs-darcs/Makefile
index d155fd363d1e..22f7f0891d43 100644
--- a/devel/hs-darcs/Makefile
+++ b/devel/hs-darcs/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= darcs
-PORTVERSION= 0.9.5
+PORTVERSION= 0.9.7
CATEGORIES= devel
MASTER_SITES= http://www.abridgegame.org/darcs/
@@ -23,8 +23,27 @@ ALL_TARGET= darcs darcs.1
GHC_VERSION= `${PREFIX}/bin/ghc --version 2>&1 | \
${SED} 's/^.*version[ ]*\([0-9.]*\).*/\1/'`
+.if defined(WITH_CGI)
+ALL_TARGET+= darcs_cgi
+.if !exists(${PREFIX}/www) && exists(${PREFIX}/share/apache)
+CGIDIR?= share/apache/cgi-bin
+.else
+CGIDIR?= www/cgi-bin
+.endif
+PLIST_SUB+= CGIDIR=${CGIDIR}
+.else
+PLIST_SUB+= CGIDIR="@comment "
+.endif
+
MAN1= darcs.1
+pre-everything::
+.if !defined(WITH_CGI)
+ @${ECHO_CMD} ""
+ @${ECHO_CMD} "To build and install the cgi script define WITH_CGI."
+ @${ECHO_CMD} ""
+.endif
+
post-patch:
@${REINPLACE_CMD} -e 's|<curl|<${PREFIX}/include/curl|' \
${WRKSRC}/hscurl.c
@@ -41,5 +60,9 @@ do-configure:
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/darcs ${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/darcs.1 ${MANPREFIX}/man/man1
+.if defined(WITH_CGI)
+ ${MKDIR} ${PREFIX}/${CGIDIR}
+ ${INSTALL_PROGRAM} ${WRKSRC}/darcs_cgi ${PREFIX}/${CGIDIR}
+.endif
.include <bsd.port.mk>