summaryrefslogtreecommitdiff
path: root/devel/readline
diff options
context:
space:
mode:
authorjlam <jlam>2001-05-16 05:05:48 +0000
committerjlam <jlam>2001-05-16 05:05:48 +0000
commit305cd1311c8a27ab0376d4fad82ed986034e7165 (patch)
tree74f87aee83d901e5918388aec2155f2bb1105772 /devel/readline
parent7a4cb1c7723d33de772c16ac28761ef0c0fe30b8 (diff)
downloadpkgsrc-305cd1311c8a27ab0376d4fad82ed986034e7165.tar.gz
Fix this up so it actually works (tested with www/cadaver) on installations
without readline emulation in the base system.
Diffstat (limited to 'devel/readline')
-rw-r--r--devel/readline/Makefile.readline17
1 files changed, 10 insertions, 7 deletions
diff --git a/devel/readline/Makefile.readline b/devel/readline/Makefile.readline
index c380472647d..fb809c0d22d 100644
--- a/devel/readline/Makefile.readline
+++ b/devel/readline/Makefile.readline
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.readline,v 1.1 2001/05/16 04:39:12 jlam Exp $
+# $NetBSD: Makefile.readline,v 1.2 2001/05/16 05:05:48 jlam Exp $
#
# This Makefile fragment is included by packages that use readline().
#
@@ -29,16 +29,14 @@ LIBHISTORY= /usr/lib/libedit.a
LIBHISTORY+= /usr/lib/libedit.so*
HAVE_LIBEDIT_READLINE= # defined
.elif exists(/usr/include/readline/readline.h)
-READLINE_H= /usr/include/readline/readline.h
-HISTORY_H= /usr/include/readline/history.h
+READLINE_INCDIR= /usr/include/readline
LIBREADLINE= /usr/lib/libedit.a
LIBREADLINE+= /usr/lib/libedit.so*
LIBHISTORY= /usr/lib/libedit.a
LIBHISTORY+= /usr/lib/libedit.so*
HAVE_LIBEDIT_READLINE= # defined
.else
-READLINE_H= ${LOCALBASE}/readline/readline.h
-HISTORY_H= ${LOCALBASE}/readline/history.h
+READLINE_INCDIR= ${LOCALBASE}/include/readline
LIBREADLINE= ${LOCALBASE}/lib/libreadline.a
LIBREADLINE+= ${LOCALBASE}/lib/libreadline.so*
LIBHISTORY= ${LOCALBASE}/lib/libhistory.a
@@ -54,10 +52,15 @@ WRKLIBDIR?= ${WRKDIR}/lib
#
link-readline-headers:
${MKDIR} -p ${WRKINCDIR}/readline
- ${RM} -f ${WRKINCDIR}/readline/readline.h
- ${RM} -f ${WRKINCDIR}/readline/history.h
+ ${RM} -f ${WRKINCDIR}/readline/*
+.if defined(READLINE_INCDIR)
+ for inc in ${READLINE_INCDIR}/*; do \
+ ${LN} -sf $${inc} ${WRKINCDIR}/readline; \
+ done
+.else
${LN} -sf ${READLINE_H} ${WRKINCDIR}/readline
${LN} -sf ${HISTORY_H} ${WRKINCDIR}/readline
+.endif
# This target links the readline and history libraries into ${WRKLIBDIR},
# which should be searched first by the linker.