aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--misc/ttyrec/Makefile12
1 files changed, 10 insertions, 2 deletions
diff --git a/misc/ttyrec/Makefile b/misc/ttyrec/Makefile
index aa0a328cedca..fc47b6b39af3 100644
--- a/misc/ttyrec/Makefile
+++ b/misc/ttyrec/Makefile
@@ -7,7 +7,7 @@
PORTNAME= ttyrec
PORTVERSION= 1.0.8
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= misc
MASTER_SITES= http://0xcc.net/ttyrec/
@@ -21,6 +21,10 @@ PLIST_FILES= bin/ttyplay \
MAN1= ttyplay.1 ttyrec.1
BINS= ttyplay ttyrec ttytime
+OPTIONS= OPENPTY "Use openpty instead" off
+
+.include <bsd.port.pre.mk>
+
post-patch:
@${REINPLACE_CMD} -e "s|^CC|#CC|g" -e "s|^CFLAGS|#CFLAGS|g" \
${WRKSRC}/Makefile
@@ -29,4 +33,8 @@ do-install:
${INSTALL_PROGRAM} ${BINS:S,^,${WRKSRC}/,} ${PREFIX}/bin
${INSTALL_MAN} ${MAN1:S,^,${WRKSRC}/,} ${MAN1PREFIX}/man/man1
-.include <bsd.port.mk>
+.if defined(WITH_OPENPTY)
+CFLAGS+= -DHAVE_openpty -lutil
+.endif
+
+.include <bsd.port.post.mk>