Contents in 1999-06-04-13 of release-21-2.
[chise/xemacs-chise.git.1] / man / Makefile
1 #  Makefile for man subdirectory in XEmacs
2 #   Copyright (C) 1995 Board of Trustees, University of Illinois
3 #   Copyright (C) 1994, 1995 Sun Microsystems.
4
5 # This file is part of XEmacs.
6
7 # XEmacs is free software; you can redistribute it and/or modify it
8 # under the terms of the GNU General Public License as published by the
9 # Free Software Foundation; either version 2, or (at your option) any
10 # later version.
11
12 # XEmacs is distributed in the hope that it will be useful, but WITHOUT
13 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15 # for more details.
16
17 # You should have received a copy of the GNU General Public License
18 # along with XEmacs; see the file COPYING.  If not, write to
19 # the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 # Boston, MA 02111-1307, USA.
21
22 # Avoid trouble on systems where the "SHELL" variable might be
23 # inherited from the environment.
24 SHELL = /bin/sh
25
26 EMACS = ../src/xemacs
27 EMACSFLAGS = -batch -q -no-site-file 
28
29 # NOTE:  You *must* have makeinfo-1.68 or later to rebuild the
30 # info tree.
31 MAKEINFO = makeinfo
32 TEXI2DVI = texi2dvi
33
34 .SUFFIXES:
35 .SUFFIXES: .info .texi .dvi
36
37 RECURSIVE_MAKE = $(MAKE) $(MFLAGS) MAKEINFO='$(MAKEINFO)' TEXI2DVI='$(TEXI2DVI)'
38
39 # Ughhh!  The things we do to have portable makefiles...
40
41 INFODIR = ../info
42
43 info_files = \
44         $(INFODIR)/cl.info \
45         $(INFODIR)/custom.info \
46         $(INFODIR)/emodules.info \
47         $(INFODIR)/external-widget.info \
48         $(INFODIR)/info.info \
49         $(INFODIR)/standards.info \
50         $(INFODIR)/term.info \
51         $(INFODIR)/termcap.info \
52         $(INFODIR)/texinfo.info \
53         $(INFODIR)/widget.info \
54         $(INFODIR)/xemacs-faq.info
55
56 dvi_files = \
57         cl.dvi \
58         custom.dvi \
59         emodules.dvi \
60         external-widget.dvi \
61         info.dvi \
62         standards.dvi \
63         term.dvi \
64         termcap.dvi \
65         texinfo.dvi \
66         widget.dvi \
67         xemacs-faq.dvi
68
69 ../info/cl.info : cl.texi
70         -$(MAKEINFO) cl.texi -o ../info/cl.info
71
72 ../info/custom.info : custom.texi
73         -$(MAKEINFO) custom.texi -o ../info/custom.info
74
75 ../info/emodules.info : emodules.texi
76         -$(MAKEINFO) emodules.texi -o ../info/emodules.info
77
78 ../info/external-widget.info : external-widget.texi
79         -$(MAKEINFO) external-widget.texi -o ../info/external-widget.info
80
81 ../info/info.info : info.texi
82         -$(MAKEINFO) info.texi -o ../info/info.info
83
84 ../info/standards.info : standards.texi
85         -$(MAKEINFO) standards.texi -o ../info/standards.info
86
87 ../info/term.info : term.texi
88         -$(MAKEINFO) term.texi -o ../info/term.info
89
90 ../info/termcap.info : termcap.texi
91         -$(MAKEINFO) termcap.texi -o ../info/termcap.info
92
93 ../info/texinfo.info : texinfo.texi
94         -$(MAKEINFO) texinfo.texi -o ../info/texinfo.info
95
96 ../info/widget.info : widget.texi
97         -$(MAKEINFO) widget.texi -o ../info/widget.info
98
99 ../info/xemacs-faq.info : xemacs-faq.texi
100         -$(MAKEINFO) xemacs-faq.texi -o ../info/xemacs-faq.info
101
102
103 # ../info/w3.info : w3.texi
104 #       -$(MAKEINFO) w3.texi -o ../info/w3.info
105
106 # ../info/vm.info : vm.texi
107 #       -$(EMACS) $(EMACSFLAGS) -insert vm.texi -l texinfmt \
108 #               -f texinfo-format-buffer -f save-buffer
109 #       -mv vm.info* ../info
110
111 # special = # ../info/w3.info ../info/vm.info ../info/texinfo.info
112
113 all: info
114
115 # Subdirectories to make recursively.
116 SUBDIR = xemacs lispref new-users-guide internals
117 .PHONY: $(SUBDIR)
118
119 info : $(info_files)
120         -for d in $(SUBDIR) ; do (cd ./$$d && $(RECURSIVE_MAKE) $@) ; done
121
122 .PHONY: info dvi
123
124 xemacs: FRC.xemacs
125         -cd ./$@ && $(RECURSIVE_MAKE)
126 lispref: FRC.lispref
127         -cd ./$@ && $(RECURSIVE_MAKE)
128 new-users-guide: FRC.new-users-guide
129         -cd ./$@ && $(RECURSIVE_MAKE)
130 internals: FRC.internals
131         -cd ./$@ && $(RECURSIVE_MAKE)
132 # tm: FRC.tm
133 #       -cd ./$@ && $(RECURSIVE_MAKE)
134 # gnats: FRC.gnats
135 #       -cd ./$@ && $(RECURSIVE_MAKE)
136 # FRC.xemacs FRC.lispref FRC.new-users-guide FRC.internals FRC.tm FRC.gnats:
137 FRC.info FRC.dvi FRC.xemacs FRC.lispref FRC.new-users-guide FRC.internals:
138
139
140 .texi.dvi:
141         $(TEXI2DVI) $<
142
143 dvi : $(dvi_files)
144         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
145
146
147 .PHONY: mostlyclean clean distclean realclean extraclean
148 mostlyclean:
149         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
150         rm -f *.toc *.aux *.log *.op \
151               *.cp *.cps *.fn *.fns *.ky *.kys *.pg *.pgs *.vr *.vrs *.tp *.tps
152 clean: mostlyclean
153         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
154         rm -f *.o core *.dvi
155 distclean: clean
156         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
157 realclean: distclean
158         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
159 extraclean: distclean
160         -for d in $(SUBDIR) ; do (cd ./$${d} && $(RECURSIVE_MAKE) $@) ; done
161         -rm -f *~ \#*