summaryrefslogtreecommitdiff
path: root/math/capc-calc
diff options
context:
space:
mode:
authorwiz <wiz>2001-02-08 15:50:20 +0000
committerwiz <wiz>2001-02-08 15:50:20 +0000
commitc6f9989a660ff2ec61cbd03eb8e56e6dc8f52189 (patch)
treed4c0443a34f37b92f313d474070904257b38c460 /math/capc-calc
parent996b3112f9e88b3d91a7078394bff5355ba3ae38 (diff)
downloadpkgsrc-c6f9989a660ff2ec61cbd03eb8e56e6dc8f52189.tar.gz
Try to be backwards compatible in readline emulation usage for older
versions of NetBSD.
Diffstat (limited to 'math/capc-calc')
-rw-r--r--math/capc-calc/Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/math/capc-calc/Makefile b/math/capc-calc/Makefile
index 25beb7fdc62..be1ec026103 100644
--- a/math/capc-calc/Makefile
+++ b/math/capc-calc/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1.1.1 2001/02/08 10:25:54 wiz Exp $
+# $NetBSD: Makefile,v 1.2 2001/02/08 15:50:20 wiz Exp $
#
DISTNAME= calc-2.11.4t2
@@ -13,4 +13,12 @@ HOMEPAGE= http://www.isthe.com/chongo/tech/comp/calc/
NO_CONFIGURE= # defined
+.if exists(/usr/include/readline.h) && !exists(/usr/include/readline/readline.h)
+post-patch:
+ ${SED} -e "s|readline/readline.h|readline.h|" \
+ -e "s|readline/history.h|history.h|" ${WRKSRC}/hist.c > \
+ ${WRKSRC}/hist.c.new && \
+ ${MV} ${WRKSRC}/hist.c.new ${WRKSRC}/hist.c
+.endif
+
.include "../../mk/bsd.pkg.mk"