diff options
Diffstat (limited to 'gnu/usr.bin/groff/tmac/Makefile')
-rw-r--r-- | gnu/usr.bin/groff/tmac/Makefile | 47 |
1 files changed, 23 insertions, 24 deletions
diff --git a/gnu/usr.bin/groff/tmac/Makefile b/gnu/usr.bin/groff/tmac/Makefile index 25689e1..e6de585 100644 --- a/gnu/usr.bin/groff/tmac/Makefile +++ b/gnu/usr.bin/groff/tmac/Makefile @@ -1,4 +1,6 @@ -# Makefile for groff macros +# $Id$ + +.include "../Makefile.inc" TMACOWN?= ${BINOWN} TMACGRP?= ${BINGRP} @@ -10,8 +12,7 @@ MAN7= groff_ms.7 me.7 MLINKS= groff_ms.7 ms.7 me.7 groff_me.7 LINKS= ${TMACDIR}/tmac.andoc ${TMACDIR}/tmac.an -MANDEPEND= ${MAN7} -CLEANFILES+= temp ${MANDEPEND} tmac.groff_an +CLEANFILES= ${MAN7} ${MDOCFILES} ${STRIPFILES} tmac.groff_an FILES= tmac.andoc tmac.pic tmac.ps tmac.psnew tmac.psold\ tmac.pspic tmac.psatk tmac.dvi tmac.tty tmac.tty-char tmac.X\ @@ -19,30 +20,28 @@ FILES= tmac.andoc tmac.pic tmac.ps tmac.psnew tmac.psold\ STRIPFILES= tmac.e tmac.s tmac.doc MDOCFILES= doc-common doc-ditroff doc-nroff doc-syms +all: ${MDOCFILES} ${STRIPFILES} tmac.groff_an + +.for f in ${MDOCFILES} ${STRIPFILES} +$f: ${DIST_DIR}/$f + sed -f ${DIST_DIR}/strip.sed ${.ALLSRC} > ${.TARGET} +.endfor + +tmac.groff_an: tmac.an + sed -f ${DIST_DIR}/strip.sed ${.ALLSRC} > ${.TARGET} beforeinstall: - for f in ${FILES}; do \ - ${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ - ${DIST_DIR}/$$f ${DESTDIR}${TMACDIR}; \ - done - sed -f ${DIST_DIR}/strip.sed ${DIST_DIR}/tmac.an >tmac.groff_an ${INSTALL} ${COPY} -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ - tmac.groff_an ${DESTDIR}${TMACDIR} - for f in ${STRIPFILES}; do \ - rm -f temp; \ - sed -f ${DIST_DIR}/strip.sed ${DIST_DIR}/$$f >temp; \ - ${INSTALL} ${COPY} -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ - temp ${DESTDIR}${TMACDIR}/$$f; \ - done - for f in ${MDOCFILES}; do \ - rm -f temp; \ - sed -f ${DIST_DIR}/strip.sed ${DIST_DIR}/$$f >temp; \ - ${INSTALL} ${COPY} -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ - temp ${DESTDIR}${MDOCDIR}/$$f; \ - done - test -f ${DESTDIR}${TMACDIR}/man.local || \ - ${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ - ${DIST_DIR}/man.local ${DESTDIR}${TMACDIR} + ${MDOCFILES} ${DESTDIR}${MDOCDIR} + ${INSTALL} ${COPY} -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ + ${STRIPFILES} tmac.groff_an ${DESTDIR}${TMACDIR} + cd ${DIST_DIR}; \ + ${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ + ${FILES} ${DESTDIR}${TMACDIR} +.if !exists(${DESTDIR}${TMACDIR}/man.local) + ${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \ + ${DIST_DIR}/man.local ${DESTDIR}${TMACDIR} +.endif .include "../Makefile.cfg" .include <bsd.prog.mk> |