summaryrefslogtreecommitdiff
path: root/mk/termcap.mk
diff options
context:
space:
mode:
authorWilliam Hubbs <w.d.hubbs@gmail.com>2011-02-02 18:18:55 -0600
committerWilliam Hubbs <w.d.hubbs@gmail.com>2011-02-04 22:30:30 -0600
commitdb6d680765b4b9a4d404f6b2e6d5644b2fe3418d (patch)
tree21986fb2b800f6dc0ddab04dc982b827d3a74e4e /mk/termcap.mk
parenta2e9cde737ede93502a80fe50e62b0aea50643dc (diff)
downloadopenrc-db6d680765b4b9a4d404f6b2e6d5644b2fe3418d.tar.gz
openrc-db6d680765b4b9a4d404f6b2e6d5644b2fe3418d.tar.bz2
openrc-db6d680765b4b9a4d404f6b2e6d5644b2fe3418d.tar.xz
rework pam, ncurses and termcap include files
This allows error checking inside the included files instead of either including the appropriate file or a blank file. Also the blank file named .mk gets removed by this change.
Diffstat (limited to 'mk/termcap.mk')
-rw-r--r--mk/termcap.mk8
1 files changed, 8 insertions, 0 deletions
diff --git a/mk/termcap.mk b/mk/termcap.mk
index 7a603e3..b716276 100644
--- a/mk/termcap.mk
+++ b/mk/termcap.mk
@@ -1,3 +1,11 @@
+ifeq (${MKTERMCAP},ncurses)
+LIBTERMCAP?= -lncurses
+CPPFLAGS+= -DHAVE_TERMCAP
+LDADD+= ${LIBTERMCAP}
+else ifeq (${MKTERMCAP},termcap)
LIBTERMCAP?= -ltermcap
CPPFLAGS+= -DHAVE_TERMCAP
LDADD+= ${LIBTERMCAP}
+else ifneq (${MKTERMCAP},)
+$(error If MKTERMCAP is defined, it must be ncurses or termcap)
+endif