Home | History | Annotate | Line # | Download | only in groff
Makefile revision 1.19
      1  1.19      wiz #	$NetBSD: Makefile,v 1.19 2003/06/30 18:14:28 wiz Exp $
      2   1.1       tv 
      3   1.1       tv MODULE=		groff
      4   1.1       tv 
      5   1.1       tv ALL_TARGET=	src/include all
      6  1.11       tv MAKE_ARGS=	bindir=${TOOLDIR}/lib/groff
      7   1.6      jmc 
      8   1.6      jmc TMACDIR=	${TOOLDIR}/share/groff/tmac
      9  1.19      wiz SITETMACDIR=	${TOOLDIR}/share/groff/site-tmac
     10   1.2       tv 
     11   1.2       tv # Add gnuwrap hack directly to the Makefile.
     12   1.2       tv _NOWRAPPER=1
     13  1.14       pk 
     14  1.19      wiz # XXX: 20030630: I think the next part is not needed --
     15  1.19      wiz # if it should be, please comment it in again. -- wiz
     16  1.14       pk #
     17  1.14       pk # Fixup build/Makefile.
     18  1.14       pk # XXX - the groff distribution Makefiles don't get their dependencies right.
     19  1.14       pk #	We use internal knowledge to specify additional target ordering.
     20  1.14       pk #	This can be removed once our own make(1) can be invoked in true
     21  1.14       pk #	sequential (i.e. compatible) mode again for subdir makes.
     22  1.14       pk #
     23  1.19      wiz #.configure_done: _post_conf
     24  1.19      wiz #_post_conf: .USE
     25  1.19      wiz #	@(echo '.include "${.CURDIR}/../Makefile.gnuwrap"'; \
     26  1.19      wiz #	  echo '.ORDER: $$(ALLDIRS) dot';\
     27  1.19      wiz #	  echo '.ORDER: all install' ) >> build/Makefile
     28  1.14       pk 
     29   1.1       tv 
     30   1.1       tv .include "${.CURDIR}/../Makefile.gnuhost"
     31   1.1       tv 
     32  1.19      wiz .PATH:		${.CURDIR}/../../share/tmac ${.CURDIR}/../../gnu/usr.bin/groff/tmac
     33   1.1       tv 
     34   1.9       tv _installtmac: .USE
     35   1.1       tv .if defined(UPDATE)
     36   1.9       tv 	@if ! cmp ${.ALLSRC} ${.TARGET} >/dev/null 2>&1; then \
     37   1.9       tv 		echo ${HOST_INSTALL_FILE:Q} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}; \
     38   1.9       tv 		${HOST_INSTALL_FILE} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}; \
     39   1.1       tv 	fi
     40   1.1       tv .else
     41   1.9       tv 	${HOST_INSTALL_FILE} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}
     42   1.1       tv .endif
     43   1.9       tv 
     44  1.15       pk #
     45  1.15       pk # Since ${TMACDIR} is created by the `realinstall' target, the `afterinstall'
     46  1.15       pk # sources below that depend on it must wait until `realinstall' is done.
     47  1.15       pk #
     48  1.19      wiz #.for F in an andoc doc doc-ditroff doc-common doc-nroff doc-syms html html-end man man.local mdoc mdoc.local
     49  1.19      wiz .for F in doc2html
     50  1.19      wiz afterinstall:	${TMACDIR}/${F}.tmac
     51  1.19      wiz .PHONY:		${TMACDIR}/${F}.tmac
     52  1.19      wiz ${TMACDIR}/${F}.tmac: ${F} _installtmac
     53  1.19      wiz .ORDER: realinstall ${TMACDIR}/${F}.tmac
     54  1.19      wiz .endfor
     55  1.19      wiz .for F in man.local mdoc.local
     56  1.19      wiz afterinstall:	${SITETMACDIR}/${F}
     57  1.19      wiz .PHONY:		${SITETMACDIR}/${F}
     58  1.19      wiz ${SITETMACDIR}/${F}: ${F} _installtmac
     59  1.19      wiz .ORDER: realinstall ${SITETMACDIR}/${F}
     60   1.1       tv .endfor
     61   1.4       tv 
     62  1.12       tv # The silly walk below is because sometimes the files begin with "g",
     63  1.12       tv # and sometimes not, depending on what the host tool has at build time.
     64  1.12       tv 
     65  1.12       tv afterinstall: install.grofflinks
     66  1.15       pk .ORDER: realinstall install.grofflinks
     67  1.12       tv install.grofflinks:
     68  1.13       tv 	@cd ${.CURDIR} && ${MAKE} install.grofflinks.recurse
     69  1.13       tv 
     70  1.18      wiz .for F in eqn groff indxbib nroff pic refer soelim tbl
     71  1.16  thorpej install.grofflinks.recurse: ${TOOLDIR}/bin/${_TOOL_PREFIX}${F}
     72  1.12       tv .if exists(${TOOLDIR}/lib/groff/g${F})
     73  1.16  thorpej ${TOOLDIR}/bin/${_TOOL_PREFIX}${F}: ${TOOLDIR}/lib/groff/g${F}
     74  1.12       tv .else
     75  1.16  thorpej ${TOOLDIR}/bin/${_TOOL_PREFIX}${F}: ${TOOLDIR}/lib/groff/${F}
     76  1.12       tv .endif
     77   1.4       tv 	ln -f ${.ALLSRC} ${.TARGET}
     78   1.4       tv .endfor
     79