diff --git a/lib/libterminfo/Makefile b/lib/libterminfo/Makefile index a8581f9128bd..f3838fb26f4e 100644 --- a/lib/libterminfo/Makefile +++ b/lib/libterminfo/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.19 2011/11/02 17:48:53 christos Exp $ +# $NetBSD: Makefile,v 1.20 2011/11/02 20:39:41 yamt Exp $ .include @@ -44,9 +44,9 @@ term.c: compiled_terms.c termcap.c: termcap_hash.c # Generate our man pages -terminfo.5: terminfo.5.in term.h termcap_map.c +terminfo.5: genman terminfo.5.in term.h termcap_map.c @echo "Generating terminfo man pages" - cd ${.CURDIR} && ${HOST_SH} ./genman >${.OBJDIR}/$@ + ${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC} > ${.TARGET} CLEANFILES+= terminfo.5 diff --git a/lib/libterminfo/Makefile.hash b/lib/libterminfo/Makefile.hash index 64901287a78b..26aac955f188 100644 --- a/lib/libterminfo/Makefile.hash +++ b/lib/libterminfo/Makefile.hash @@ -1,20 +1,25 @@ -# $NetBSD: Makefile.hash,v 1.2 2011/11/02 20:30:00 christos Exp $ +# $NetBSD: Makefile.hash,v 1.3 2011/11/02 20:39:41 yamt Exp $ + +SCRIPT_ENV= \ + TOOL_AWK=${TOOL_AWK:Q} \ + TOOL_NBPERF=${TOOL_NBPERF:Q} \ + TOOL_SED=${TOOL_SED:Q} \ + TOOL_SORT=${TOOL_SORT:Q} \ + TOOL_TIC=${TOOL_TIC:Q} PARSEDIR:=${.PARSEDIR} # Generate our string and hash tables hash.c: genhash term.h @echo "Generating terminfo hash" - TOOL_NBPERF=${TOOL_NBPERF} TOOL_AWK=${TOOL_AWK} \ - TOOL_SED=${TOOL_SED} ${HOST_SH} ${.ALLSRC} > ${.TARGET} + ${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC} > ${.TARGET} termcap_hash.c: genthash termcap_map.c @echo "Generating termcap hash" - ${HOST_SH} ${.ALLSRC} > ${.TARGET} - + ${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC} > ${.TARGET} # Allow terminfo descriptions to be compiled into libterminfo compiled_terms.c: genterms term.h ${NETBSDSRCDIR}/share/terminfo/terminfo @echo "Generating compiled terminfo descriptions" - ${HOST_SH} ${.ALLSRC} > ${.TARGET} + ${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC} > ${.TARGET} CLEANFILES+= hash.c termcap_hash.c compiled_terms.c