summaryrefslogtreecommitdiff
path: root/mk/termcap.builtin.mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2008-03-02 07:05:28 +0000
committerjlam <jlam@pkgsrc.org>2008-03-02 07:05:28 +0000
commit9b49134ee18634b5916315d7e45816557c23cff5 (patch)
tree201d3d5719e91663cf062a3e1d858b99207c7b6a /mk/termcap.builtin.mk
parent515da0626952194d3ec860ba3b87a2e2a44e919a (diff)
downloadpkgsrc-9b49134ee18634b5916315d7e45816557c23cff5.tar.gz
+ Teach buildlink3.mk to cause GNU configure script to not find any other
terminal library other than the one we specify. + Also look for "termlib" as some systems have that. Note that we need to make the library search more sophisticated to work correctly on more exotic platforms.
Diffstat (limited to 'mk/termcap.builtin.mk')
-rw-r--r--mk/termcap.builtin.mk19
1 files changed, 14 insertions, 5 deletions
diff --git a/mk/termcap.builtin.mk b/mk/termcap.builtin.mk
index 3f8ad0eb407..52417f64ead 100644
--- a/mk/termcap.builtin.mk
+++ b/mk/termcap.builtin.mk
@@ -1,8 +1,8 @@
-# $NetBSD: termcap.builtin.mk,v 1.1 2008/02/29 22:41:13 jlam Exp $
+# $NetBSD: termcap.builtin.mk,v 1.2 2008/03/02 07:05:28 jlam Exp $
BUILTIN_PKG:= termcap
-BUILTIN_FIND_LIBS:= termcap tinfo curses
+BUILTIN_FIND_LIBS:= curses termcap termlib tinfo
.include "buildlink3/bsd.builtin.mk"
@@ -12,9 +12,10 @@ BUILTIN_FIND_LIBS:= termcap tinfo curses
###
.if !defined(IS_BUILTIN.termcap)
IS_BUILTIN.termcap= no
-. if !empty(BUILTIN_LIB_FOUND.termcap:M[yY][eE][sS]) || \
- !empty(BUILTIN_LIB_FOUND.tinfo:M[yY][eE][sS]) || \
- !empty(BUILTIN_LIB_FOUND.curses:M[yY][eE][sS])
+. if !empty(BUILTIN_LIB_FOUND.curses:M[yY][eE][sS]) || \
+ !empty(BUILTIN_LIB_FOUND.termcap:M[yY][eE][sS]) || \
+ !empty(BUILTIN_LIB_FOUND.termlib:M[yY][eE][sS]) || \
+ !empty(BUILTIN_LIB_FOUND.tinfo:M[yY][eE][sS])
IS_BUILTIN.termcap= yes
. endif
.endif
@@ -36,12 +37,20 @@ MAKEVARS+= USE_BUILTIN.termcap
# Define BUILTIN_LIBNAME.termcap to be the base name of the built-in
# termcap library.
#
+# XXX This needs to be more sophisticated. We will want to do what
+# XXX most packages do: test for tgetent() in the following libraries
+# XXX in order: c, curses, termcap, termlib. Since we can't test for
+# XXX symbols in libraries, we'll need to be clever with looking at
+# XXX headers.
+#
.if !empty(BUILTIN_LIB_FOUND.termcap:M[yY][eE][sS])
BUILTIN_LIBNAME.termcap= termcap
.elif !empty(BUILTIN_LIB_FOUND.tinfo:M[yY][eE][sS])
BUILTIN_LIBNAME.termcap= tinfo
.elif !empty(BUILTIN_LIB_FOUND.curses:M[yY][eE][sS])
BUILTIN_LIBNAME.termcap= curses
+.elif !empty(BUILTIN_LIB_FOUND.termlib:M[yY][eE][sS])
+BUILTIN_LIBNAME.termcap= termlib
.endif
###