]> CyberLeo.Net >> Repos - FreeBSD/releng/8.1.git/blob - contrib/binutils/bfd/doc/Makefile.am
Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.
[FreeBSD/releng/8.1.git] / contrib / binutils / bfd / doc / Makefile.am
1 ## Process this file with automake to generate Makefile.in
2
3 AUTOMAKE_OPTIONS = cygnus
4
5 DOCFILES = aoutx.texi  archive.texi archures.texi \
6         bfdt.texi  cache.texi coffcode.texi \
7         core.texi elf.texi elfcode.texi  format.texi \
8         libbfd.texi bfdwin.texi bfdio.texi \
9         opncls.texi  reloc.texi  section.texi  \
10         syms.texi  targets.texi init.texi hash.texi linker.texi \
11         mmo.texi
12
13 PROTOS = archive.p archures.p bfd.p \
14          core.p format.p \
15         bfdio.p bfdwin.p \
16         libbfd.p opncls.p reloc.p \
17         section.p syms.p targets.p  \
18         format.p  core.p init.p
19
20 IPROTOS = cache.ip libbfd.ip reloc.ip init.ip archures.ip coffcode.ip
21
22 # SRCDOC, SRCPROT, SRCIPROT only used to sidestep Sun Make bug in interaction 
23 # between VPATH and suffix rules.  If you use GNU Make, perhaps other Makes,
24 # you don't need these three:
25 SRCDOC = $(srcdir)/../aoutx.h  $(srcdir)/../archive.c \
26         $(srcdir)/../archures.c $(srcdir)/../bfd.c \
27         $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
28         $(srcdir)/../cache.c $(srcdir)/../coffcode.h \
29         $(srcdir)/../corefile.c $(srcdir)/../elf.c \
30         $(srcdir)/../elfcode.h  $(srcdir)/../format.c \
31         $(srcdir)/../libbfd.c $(srcdir)/../opncls.c \
32         $(srcdir)/../reloc.c  $(srcdir)/../section.c \
33         $(srcdir)/../syms.c  $(srcdir)/../targets.c \
34         $(srcdir)/../hash.c $(srcdir)/../linker.c \
35         $(srcdir)/../mmo.c
36
37 SRCPROT = $(srcdir)/../archive.c $(srcdir)/../archures.c \
38         $(srcdir)/../bfd.c $(srcdir)/../coffcode.h $(srcdir)/../corefile.c \
39         $(srcdir)/../format.c $(srcdir)/../libbfd.c \
40         $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
41         $(srcdir)/../opncls.c $(srcdir)/../reloc.c \
42         $(srcdir)/../section.c $(srcdir)/../syms.c \
43         $(srcdir)/../targets.c $(srcdir)/../init.c
44
45 SRCIPROT = $(srcdir)/../cache.c $(srcdir)/../libbfd.c \
46         $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
47         $(srcdir)/../reloc.c $(srcdir)/../cpu-h8300.c \
48         $(srcdir)/../cpu-i960.c $(srcdir)/../archures.c \
49         $(srcdir)/../init.c
50
51 TEXIDIR = $(srcdir)/../../texinfo/fsf
52
53 info_TEXINFOS = bfd.texinfo
54
55 MKDOC = chew$(EXEEXT_FOR_BUILD)
56
57 $(MKDOC): chew.o
58         $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS)
59
60 chew.o: chew.c
61         $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c
62
63 protos: libbfd.h libcoff.h bfd.h
64
65 bfd.info bfd.dvi: $(DOCFILES) bfdsumm.texi bfd.texinfo
66
67 # We can't replace these rules with an implicit rule, because
68 # makes without VPATH support couldn't find the .h files in `..'.
69
70 # We use s-XXX targets so that we can distribute the info files,
71 # and permit people to rebuild them, without requiring the makeinfo
72 # program.  If somebody tries to rebuild info, but none of the .texi
73 # files have changed, then this Makefile will build chew, and will
74 # build all of the stamp files, but will not actually have to rebuild
75 # bfd.info.
76
77 s-aoutx: $(MKDOC) $(srcdir)/../aoutx.h $(srcdir)/doc.str
78         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../aoutx.h >aoutx.tmp
79         $(srcdir)/../../move-if-change aoutx.tmp aoutx.texi
80         touch s-aoutx
81 aoutx.texi: s-aoutx
82
83 s-archive: $(MKDOC) $(srcdir)/../archive.c $(srcdir)/doc.str
84         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../archive.c >archive.tmp
85         $(srcdir)/../../move-if-change archive.tmp archive.texi
86         touch s-archive
87 archive.texi: s-archive
88
89 s-archures: $(MKDOC) $(srcdir)/../archures.c $(srcdir)/doc.str
90         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../archures.c >archures.tmp
91         $(srcdir)/../../move-if-change archures.tmp archures.texi
92         touch s-archures
93 archures.texi: s-archures
94
95 # We use bfdt.texi, rather than bfd.texi, to avoid conflicting with
96 # bfd.texinfo on an 8.3 filesystem.
97 s-bfd: $(MKDOC) $(srcdir)/../bfd.c $(srcdir)/doc.str
98         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfd.c >bfd.tmp
99         $(srcdir)/../../move-if-change bfd.tmp bfdt.texi
100         touch s-bfd
101 bfdt.texi: s-bfd
102
103 s-cache: $(MKDOC) $(srcdir)/../cache.c $(srcdir)/doc.str
104         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../cache.c >cache.tmp
105         $(srcdir)/../../move-if-change cache.tmp cache.texi
106         touch s-cache
107 cache.texi: s-cache
108
109 s-coffcode: $(MKDOC) $(srcdir)/../coffcode.h $(srcdir)/doc.str
110         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../coffcode.h >coffcode.tmp
111         $(srcdir)/../../move-if-change coffcode.tmp coffcode.texi
112         touch s-coffcode
113 coffcode.texi: s-coffcode
114
115 s-core: $(MKDOC) $(srcdir)/../corefile.c $(srcdir)/doc.str
116         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../corefile.c >core.tmp
117         $(srcdir)/../../move-if-change core.tmp core.texi
118         touch s-core
119 core.texi: s-core
120
121 s-elf: $(MKDOC) $(srcdir)/../elf.c $(srcdir)/doc.str
122         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../elf.c >elf.tmp
123         $(srcdir)/../../move-if-change elf.tmp elf.texi
124         touch s-elf
125 elf.texi: s-elf
126
127 s-elfcode: $(MKDOC) $(srcdir)/../elfcode.h $(srcdir)/doc.str
128         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../elfcode.h >elfcode.tmp
129         $(srcdir)/../../move-if-change elfcode.tmp elfcode.texi
130         touch s-elfcode
131 elfcode.texi: s-elfcode
132
133 s-mmo: $(MKDOC) $(srcdir)/../mmo.c $(srcdir)/doc.str
134         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../mmo.c >mmo.tmp
135         $(srcdir)/../../move-if-change mmo.tmp mmo.texi
136         touch s-mmo
137 mmo.texi: s-mmo
138
139 s-format: $(MKDOC) $(srcdir)/../format.c $(srcdir)/doc.str
140         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../format.c >format.tmp
141         $(srcdir)/../../move-if-change format.tmp format.texi
142         touch s-format
143 format.texi: s-format
144
145 s-libbfd: $(MKDOC) $(srcdir)/../libbfd.c $(srcdir)/doc.str
146         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../libbfd.c >libbfd.tmp
147         $(srcdir)/../../move-if-change libbfd.tmp libbfd.texi
148         touch s-libbfd
149 libbfd.texi: s-libbfd
150
151 s-bfdio: $(MKDOC) $(srcdir)/../bfdio.c $(srcdir)/doc.str
152         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdio.c >bfdio.tmp
153         $(srcdir)/../../move-if-change bfdio.tmp bfdio.texi
154         touch s-bfdio
155 bfdio.texi: s-bfdio
156
157 s-bfdwin: $(MKDOC) $(srcdir)/../bfdwin.c $(srcdir)/doc.str
158         ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdwin.c >bfdwin.tmp
159         $(srcdir)/../../move-if-change bfdwin.tmp bfdwin.texi
160         touch s-bfdwin
161 bfdwin.texi: s-bfdwin
162
163 s-opncls: $(MKDOC) $(srcdir)/../opncls.c $(srcdir)/doc.str
164         ./$(MKDOC) -f $(srcdir)/doc.str  <$(srcdir)/../opncls.c >opncls.tmp
165         $(srcdir)/../../move-if-change opncls.tmp opncls.texi
166         touch s-opncls
167 opncls.texi: s-opncls
168
169 s-reloc: $(MKDOC) $(srcdir)/../reloc.c $(srcdir)/doc.str
170         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../reloc.c >reloc.tmp
171         $(srcdir)/../../move-if-change reloc.tmp reloc.texi
172         touch s-reloc
173 reloc.texi: s-reloc
174
175 s-section: $(MKDOC) $(srcdir)/../section.c $(srcdir)/doc.str
176         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../section.c >section.tmp
177         $(srcdir)/../../move-if-change section.tmp section.texi
178         touch s-section
179 section.texi: s-section
180
181 s-syms: $(MKDOC) $(srcdir)/../syms.c $(srcdir)/doc.str
182         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../syms.c >syms.tmp
183         $(srcdir)/../../move-if-change syms.tmp syms.texi
184         touch s-syms
185 syms.texi: s-syms
186
187 s-targets: $(MKDOC) $(srcdir)/../targets.c $(srcdir)/doc.str
188         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../targets.c >targets.tmp
189         $(srcdir)/../../move-if-change targets.tmp targets.texi
190         touch s-targets
191 targets.texi: s-targets
192
193 s-init: $(MKDOC) $(srcdir)/../init.c $(srcdir)/doc.str
194         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../init.c >init.tmp
195         $(srcdir)/../../move-if-change init.tmp init.texi
196         touch s-init
197 init.texi: s-init
198
199 s-hash: $(MKDOC) $(srcdir)/../hash.c $(srcdir)/doc.str
200         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../hash.c >hash.tmp
201         $(srcdir)/../../move-if-change hash.tmp hash.texi
202         touch s-hash
203 hash.texi: s-hash
204
205 s-linker: $(MKDOC) $(srcdir)/../linker.c $(srcdir)/doc.str
206         ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../linker.c >linker.tmp
207         $(srcdir)/../../move-if-change linker.tmp linker.texi
208         touch s-linker
209 linker.texi: s-linker
210
211 LIBBFD_H_DEP = \
212         $(srcdir)/../libbfd-in.h        \
213         $(srcdir)/../init.c             \
214         $(srcdir)/../libbfd.c           \
215         $(srcdir)/../bfdio.c            \
216         $(srcdir)/../bfdwin.c           \
217         $(srcdir)/../cache.c            \
218         $(srcdir)/../reloc.c            \
219         $(srcdir)/../archures.c         \
220         $(srcdir)/../elf.c              \
221         $(srcdir)/header.sed            \
222         $(srcdir)/proto.str             \
223         $(MKDOC)
224
225 libbfd.h: $(LIBBFD_H_DEP)
226         echo "$(LIBBFD_H_DEP)" | sed -f $(srcdir)/header.sed > $@
227         for file in $(LIBBFD_H_DEP); do \
228           case $$file in \
229             *-in.h) cat $$file >> $@ ;; \
230             */header.sed) break ;; \
231             *)  echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
232                                 -e 's,$$,.  */,' >> $@ ; \
233                 ./$(MKDOC) -i -f $(srcdir)/proto.str < $$file >> $@ ;; \
234           esac; \
235         done
236
237 LIBCOFF_H_DEP = \
238         $(srcdir)/../libcoff-in.h       \
239         $(srcdir)/../coffcode.h         \
240         $(srcdir)/header.sed            \
241         $(srcdir)/proto.str             \
242         $(MKDOC)
243
244 libcoff.h: $(LIBCOFF_H_DEP)
245         echo "$(LIBCOFF_H_DEP)" | sed -f $(srcdir)/header.sed > $@
246         for file in $(LIBCOFF_H_DEP); do \
247           case $$file in \
248             *-in.h) cat $$file >> $@ ;; \
249             */header.sed) break ;; \
250             *)  echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
251                                 -e 's,$$,.  */,' >> $@ ; \
252                 ./$(MKDOC) -i -f $(srcdir)/proto.str < $$file >> $@ ;; \
253           esac; \
254         done
255
256 BFD_H_DEP = \
257         $(srcdir)/../bfd-in.h           \
258         $(srcdir)/../init.c             \
259         $(srcdir)/../opncls.c           \
260         $(srcdir)/../libbfd.c           \
261         $(srcdir)/../bfdio.c            \
262         $(srcdir)/../bfdwin.c           \
263         $(srcdir)/../section.c          \
264         $(srcdir)/../archures.c         \
265         $(srcdir)/../reloc.c            \
266         $(srcdir)/../syms.c             \
267         $(srcdir)/../bfd.c              \
268         $(srcdir)/../archive.c          \
269         $(srcdir)/../corefile.c         \
270         $(srcdir)/../targets.c          \
271         $(srcdir)/../format.c           \
272         $(srcdir)/../linker.c           \
273         $(srcdir)/../simple.c           \
274         $(srcdir)/header.sed            \
275         $(srcdir)/proto.str             \
276         $(srcdir)/../version.h          \
277         $(MKDOC)
278
279 bfd.h: $(BFD_H_DEP)
280         echo "$(BFD_H_DEP)" | sed -f $(srcdir)/header.sed > $@
281         for file in $(BFD_H_DEP); do \
282           case $$file in \
283             *-in.h) cat $$file >> $@ ;; \
284             */header.sed) break ;; \
285             *)  echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
286                                 -e 's,$$,.  */,' >> $@ ; \
287                 ./$(MKDOC) -f $(srcdir)/proto.str < $$file >> $@ ;; \
288           esac; \
289         done
290         echo "#ifdef __cplusplus" >> $@
291         echo "}" >> $@
292         echo "#endif" >> $@
293         echo "#endif" >> $@
294
295 noinst_TEXINFOS = bfdint.texi
296
297 MOSTLYCLEANFILES = $(MKDOC) *.o
298
299 CLEANFILES = s-* *.p *.ip
300
301 DISTCLEANFILES = bfd.?? bfd.??? bfd.h libbfd.h libcoff.h texput.log
302
303 MAINTAINERCLEANFILES = $(DOCFILES)
304
305 # We want install to imply install-info as per GNU standards, despite the
306 # cygnus option.
307 install: install-info