Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/distrib/utils/libhack Extend the curses hack to terminfo - b...



details:   https://anonhg.NetBSD.org/src/rev/37865bde9cc6
branches:  trunk
changeset: 1008901:37865bde9cc6
user:      martin <martin%NetBSD.org@localhost>
date:      Sun Apr 05 11:18:02 2020 +0000

description:
Extend the curses hack to terminfo - build selected parts of
libterminfo as part of libhack, so we can drop unwanted features
for small install media.

diffstat:

 distrib/utils/libhack/Makefile.inc |  19 ++++++++++++++++++-
 1 files changed, 18 insertions(+), 1 deletions(-)

diffs (33 lines):

diff -r 769e02b7acee -r 37865bde9cc6 distrib/utils/libhack/Makefile.inc
--- a/distrib/utils/libhack/Makefile.inc        Sun Apr 05 10:43:09 2020 +0000
+++ b/distrib/utils/libhack/Makefile.inc        Sun Apr 05 11:18:02 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.34 2020/03/02 16:01:52 roy Exp $
+# $NetBSD: Makefile.inc,v 1.35 2020/04/05 11:18:02 martin Exp $
 #
 # Include this fragment to build libhack.o
 # It is .o and not .a to make sure these are the
@@ -41,6 +41,23 @@
 HACKOBJS+=     ${s:S/.c/.o/}
 ${s:S/.c/.o/}: ${HACKSRC}/../../../lib/libcurses/${s}
 .endfor
+
+TERMINFO_SRC!= cd ${HACKSRC}/../../../lib/libterminfo && \
+               ${MAKE} SMALLPROG=1 -v SRCS
+TERMINFO_PATH!=        cd ${HACKSRC}/../../../lib/libterminfo && \
+               ${MAKE} -v .OBJDIR
+
+.for s in ${TERMINFO_SRC}
+CPPFLAGS.${s}+=        -DDISABLE_WCHAR -DSMALL \
+               -I${HACKSRC}/../../../lib/libterminfo \
+               -I${TERMINFO_PATH}
+HACKOBJS+=     ${s:S/.c/.o/}
+.if ${s:Mhash*} != ""
+${s:S/.c/.o/}: ${TERMINFO_PATH}/${s}
+.else
+${s:S/.c/.o/}: ${HACKSRC}/../../../lib/libterminfo/${s}
+.endif
+.endfor
 .endif
 
 CPPFLAGS.runetable.c+= -I${HACKSRC}/../../../lib/libc/citrus \



Home | Main Index | Thread Index | Old Index