Makefile revision 1.25
11.25Swiz# $NetBSD: Makefile,v 1.25 2003/10/20 08:25:36 wiz Exp $ 21.1Stv 31.1StvMODULE= groff 41.1Stv 51.1StvALL_TARGET= src/include all 61.24SlukemMAKE_ARGS= bindir=${TOOLDIR}/lib/groff MAKEINFO=${TOOL_MAKEINFO:Q} \ 71.24Slukem INSTALL_INFO=${TOOL_INSTALL_INFO:Q} 81.6Sjmc 91.6SjmcTMACDIR= ${TOOLDIR}/share/groff/tmac 101.19SwizSITETMACDIR= ${TOOLDIR}/share/groff/site-tmac 111.2Stv 121.2Stv# Add gnuwrap hack directly to the Makefile. 131.2Stv_NOWRAPPER=1 141.14Spk 151.14Spk# Fixup build/Makefile. 161.14Spk# XXX - the groff distribution Makefiles don't get their dependencies right. 171.14Spk# We use internal knowledge to specify additional target ordering. 181.14Spk# This can be removed once our own make(1) can be invoked in true 191.14Spk# sequential (i.e. compatible) mode again for subdir makes. 201.14Spk# 211.21Smartin.configure_done: _post_conf 221.21Smartin_post_conf: .USE 231.21Smartin @(echo '.include "${.CURDIR}/../Makefile.gnuwrap"'; \ 241.21Smartin echo '.ORDER: $$(ALLDIRS) dot';\ 251.21Smartin echo '.ORDER: all install' ) >> build/Makefile 261.14Spk 271.1Stv 281.1Stv.include "${.CURDIR}/../Makefile.gnuhost" 291.1Stv 301.19Swiz.PATH: ${.CURDIR}/../../share/tmac ${.CURDIR}/../../gnu/usr.bin/groff/tmac 311.1Stv 321.9Stv_installtmac: .USE 331.23Slukem.if ${MKUPDATE} != "no" 341.9Stv @if ! cmp ${.ALLSRC} ${.TARGET} >/dev/null 2>&1; then \ 351.9Stv echo ${HOST_INSTALL_FILE:Q} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}; \ 361.9Stv ${HOST_INSTALL_FILE} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}; \ 371.1Stv fi 381.1Stv.else 391.9Stv ${HOST_INSTALL_FILE} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET} 401.1Stv.endif 411.9Stv 421.15Spk# 431.15Spk# Since ${TMACDIR} is created by the `realinstall' target, the `afterinstall' 441.15Spk# sources below that depend on it must wait until `realinstall' is done. 451.15Spk# 461.19Swiz#.for F in an andoc doc doc-ditroff doc-common doc-nroff doc-syms html html-end man man.local mdoc mdoc.local 471.19Swiz.for F in doc2html 481.19Swizafterinstall: ${TMACDIR}/${F}.tmac 491.19Swiz.PHONY: ${TMACDIR}/${F}.tmac 501.19Swiz${TMACDIR}/${F}.tmac: ${F} _installtmac 511.19Swiz.ORDER: realinstall ${TMACDIR}/${F}.tmac 521.19Swiz.endfor 531.19Swiz.for F in man.local mdoc.local 541.19Swizafterinstall: ${SITETMACDIR}/${F} 551.19Swiz.PHONY: ${SITETMACDIR}/${F} 561.25Swiz${SITETMACDIR}/${F}: ${F}-s _installtmac 571.19Swiz.ORDER: realinstall ${SITETMACDIR}/${F} 581.25Swiz${F}-s: ${F} 591.25Swiz sed -f ${.CURDIR}/../../gnu/dist/groff/tmac/strip.sed ${.ALLSRC} > ${.TARGET} 601.1Stv.endfor 611.4Stv 621.12Stv# The silly walk below is because sometimes the files begin with "g", 631.12Stv# and sometimes not, depending on what the host tool has at build time. 641.12Stv 651.12Stvafterinstall: install.grofflinks 661.15Spk.ORDER: realinstall install.grofflinks 671.12Stvinstall.grofflinks: 681.13Stv @cd ${.CURDIR} && ${MAKE} install.grofflinks.recurse 691.13Stv 701.18Swiz.for F in eqn groff indxbib nroff pic refer soelim tbl 711.16Sthorpejinstall.grofflinks.recurse: ${TOOLDIR}/bin/${_TOOL_PREFIX}${F} 721.12Stv.if exists(${TOOLDIR}/lib/groff/g${F}) 731.16Sthorpej${TOOLDIR}/bin/${_TOOL_PREFIX}${F}: ${TOOLDIR}/lib/groff/g${F} 741.12Stv.else 751.16Sthorpej${TOOLDIR}/bin/${_TOOL_PREFIX}${F}: ${TOOLDIR}/lib/groff/${F} 761.12Stv.endif 771.4Stv ln -f ${.ALLSRC} ${.TARGET} 781.4Stv.endfor 79