PageRenderTime 12ms CodeModel.GetById 1ms app.highlight 8ms RepoModel.GetById 2ms app.codeStats 0ms

/contrib/groff/contrib/mm/Makefile.sub

https://bitbucket.org/freebsd/freebsd-head/
Unknown | 62 lines | 55 code | 7 blank | 0 comment | 0 complexity | 3a6a20b21c577251c9e50ef9c68076ac MD5 | raw file
 1#
 2# $Id: Makefile.sub,v 2.3 2002/05/22 06:26:12 jhaegg Exp $
 3#
 4PROG=mmroff
 5MAN1=\
 6  mmroff.n
 7MAN7=\
 8  groff_mm.n \
 9  groff_mmse.n
10FILES=0.MT 5.MT 4.MT ms.cov se_ms.cov 
11# Local configuration files with default values.
12LOCALE=locale se_locale
13CLEANADD=temp
14
15all: mmroff
16
17install: install_mm
18
19install_mm: install_mmroff install_m
20	-test -d $(tmacdir)/mm || $(mkinstalldirs) $(tmacdir)/mm
21	-for f in $(FILES); do \
22		rm -f $(tmacdir)/mm/$$f; \
23		$(INSTALL_DATA) $(srcdir)/mm/$$f $(tmacdir)/mm/$$f; \
24	done
25	-for f in $(LOCALE); do \
26		test -f $(tmacdir)/mm/$$f || touch $(tmacdir)/mm/$$f; \
27	done
28
29install_m:
30	-test -d $(tmacdir) || $(mkinstalldirs) $(tmacdir)
31	-rm -f $(tmacdir)/tmac.$(tmac_m_prefix)m
32	-rm -f $(tmacdir)/$(tmac_m_prefix)m.tmac
33	$(INSTALL_DATA) $(srcdir)/m.tmac $(tmacdir)/$(tmac_m_prefix)m.tmac
34	@sed -e "s;^.mso m.tmac;.mso $(tmac_m_prefix)m.tmac;g" \
35		$(srcdir)/mse.tmac > $(tmacdir)/$(tmac_m_prefix)mse.tmac
36	@sed -e "s;^.mso mse.tmac;.mso $(tmac_m_prefix)mse.tmac;g" \
37		$(srcdir)/mmse.tmac > $(tmacdir)/$(tmac_m_prefix)mmse.tmac
38	@sed -e "s;^.mso m.tmac;.mso $(tmac_m_prefix)m.tmac;g" \
39		$(srcdir)/mm.tmac > $(tmacdir)/$(tmac_m_prefix)mm.tmac
40
41install_mmroff: mmroff
42	-test -d $(bindir) || $(mkinstalldirs) $(bindir)
43	-rm -f $(bindir)/mmroff
44	$(INSTALL_SCRIPT) mmroff $(bindir)/mmroff
45
46mmroff: mmroff.pl
47	-rm -f $@
48	-sed -e 's;/usr/bin/perl;$(PERLPATH);' $(srcdir)/mmroff.pl >$@
49	-chmod +x $@
50
51uninstall_sub:
52	-for f in $(FILES); do rm -f $(tmacdir)/mm/$$f; done
53	-for f in $(LOCALE); do \
54	test -s $(tmacdir)/mm/$$f || rm -f $(tmacdir)/mm/$$f; \
55	done
56	-rm -f $(tmacdir)/tmac.$(tmac_m_prefix)m
57	-rm -f $(tmacdir)/$(tmac_m_prefix)m.tmac
58	-rm -f $(tmacdir)/$(tmac_m_prefix)mm.tmac
59	-rm -f $(tmacdir)/$(tmac_m_prefix)mse.tmac
60	-rm -f $(tmacdir)/$(tmac_m_prefix)mmse.tmac
61	-rmdir $(tmacdir)/mm
62	-rm -f $(bindir)/mmroff