3 # Copyright (C) 1990, 1991, 1992, 1993 Free Software Foundation
5 # This file is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
25 exec_prefix = @
exec_prefix@
31 man1dir = $(mandir)/man1
32 man2dir = $(mandir)/man2
33 man3dir = $(mandir)/man3
34 man4dir = $(mandir)/man4
35 man5dir = $(mandir)/man5
36 man6dir = $(mandir)/man6
37 man7dir = $(mandir)/man7
38 man8dir = $(mandir)/man8
39 man9dir = $(mandir)/man9
41 includedir = @
includedir@
47 INSTALL_PROGRAM
= @INSTALL_PROGRAM@
48 INSTALL_DATA
= @INSTALL_DATA@
57 #### Host, target, and site specific Makefile fragments come in here.
61 $(CC
) -c
-I..
-I
$(srcdir)/..
-I
$(srcdir)/..
/..
/include $(H_CFLAGS
) $(CFLAGS
) $<
63 DOCFILES
= aoutx.texi archive.texi archures.texi \
64 bfd.texi cache.texi coffcode.texi \
65 core.texi elf.texi elfcode.texi format.texi libbfd.texi \
66 opncls.texi reloc.texi section.texi \
67 syms.texi targets.texi init.texi hash.texi linker.texi
69 PROTOS
= archive.p archures.p bfd.p \
71 libbfd.p opncls.p reloc.p \
72 section.p syms.p targets.p \
73 format.p core.p init.p
75 IPROTOS
= cache.ip libbfd.ip reloc.ip init.ip archures.ip coffcode.ip
77 # SRCDOC, SRCPROT, SRCIPROT only used to sidestep Sun Make bug in interaction
78 # between VPATH and suffix rules. If you use GNU Make, perhaps other Makes,
79 # you don't need these three:
80 SRCDOC
= $(srcdir)/..
/aoutx.h
$(srcdir)/..
/archive.c \
81 $(srcdir)/..
/archures.c
$(srcdir)/..
/bfd.c \
82 $(srcdir)/..
/cache.c
$(srcdir)/..
/coffcode.h \
83 $(srcdir)/..
/corefile.c
$(srcdir)/..
/elf.c \
84 $(srcdir)/..
/elfcode.h
$(srcdir)/..
/format.c \
85 $(srcdir)/..
/libbfd.c
$(srcdir)/..
/opncls.c \
86 $(srcdir)/..
/reloc.c
$(srcdir)/..
/section.c \
87 $(srcdir)/..
/syms.c
$(srcdir)/..
/targets.c \
88 $(srcdir)/..
/hash.c
$(srcdir)/..
/linker.c
90 SRCPROT
= $(srcdir)/..
/archive.c
$(srcdir)/..
/archures.c \
91 $(srcdir)/..
/bfd.c
$(srcdir)/..
/coffcode.h
$(srcdir)/..
/corefile.c \
92 $(srcdir)/..
/format.c
$(srcdir)/..
/libbfd.c \
93 $(srcdir)/..
/opncls.c
$(srcdir)/..
/reloc.c \
94 $(srcdir)/..
/section.c
$(srcdir)/..
/syms.c \
95 $(srcdir)/..
/targets.c
$(srcdir)/..
/init.c
97 SRCIPROT
= $(srcdir)/..
/cache.c
$(srcdir)/..
/libbfd.c \
98 $(srcdir)/..
/reloc.c
$(srcdir)/..
/cpu-h8300.c \
99 $(srcdir)/..
/cpu-i960.c
$(srcdir)/..
/archures.c \
102 STAGESTUFF
= $(DOCFILES
) *.
info*
104 TEXIDIR
= $(srcdir)/..
/..
/texinfo
/fsf
113 $(SHELL
) $(srcdir)/..
/..
/mkinstalldirs
$(infodir)
114 if
[ -r bfd.
info ]; then \
119 for i in
`cd $$dir; echo *.info*`; do \
120 $(INSTALL_DATA
) $$dir/$$i $(infodir)/$$i; \
123 docs
: $(MKDOC
) protos bfd.
info bfd.
dvi bfd.ps
126 $(CC_FOR_BUILD
) -o
$(MKDOC
) chew.o
$(LOADLIBES
) $(LDFLAGS
)
129 $(CC_FOR_BUILD
) -c
-I..
-I
$(srcdir)/..
-I
$(srcdir)/..
/..
/include $(H_CFLAGS
) $(CFLAGS
) $(srcdir)/chew.c
131 protos
: libbfd.h libcoff.h bfd.h
134 # We can't replace these rules with an implicit rule, because
135 # makes without VPATH support couldn't find the .h files in `..'.
137 # We use stamp-XXX targets so that we can distribute the info files,
138 # and permit people to rebuild them, without requiring the makeinfo
139 # program. If somebody tries to rebuild info, but none of the .texi
140 # files have changed, then this Makefile will build chew, and will
141 # build all of the stamp files, but will not actually have to rebuild
144 stamp-aoutx
: $(MKDOC
) $(srcdir)/..
/aoutx.h
$(srcdir)/doc.str
145 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/aoutx.h
>aoutx.tmp
146 $(srcdir)/..
/..
/move-if-change aoutx.tmp aoutx.texi
148 aoutx.texi
: stamp-aoutx
150 stamp-archive
: $(MKDOC
) $(srcdir)/..
/archive.c
$(srcdir)/doc.str
151 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/archive.c
>archive.tmp
152 $(srcdir)/..
/..
/move-if-change archive.tmp archive.texi
154 archive.texi
: stamp-archive
156 stamp-archures
: $(MKDOC
) $(srcdir)/..
/archures.c
$(srcdir)/doc.str
157 $(MKDOC
) -f
$(srcdir)/doc.str
< $(srcdir)/..
/archures.c
>archures.tmp
158 $(srcdir)/..
/..
/move-if-change archures.tmp archures.texi
160 archures.texi
: stamp-archures
162 stamp-bfd
: $(MKDOC
) $(srcdir)/..
/bfd.c
$(srcdir)/doc.str
163 $(MKDOC
) -f
$(srcdir)/doc.str
< $(srcdir)/..
/bfd.c
>bfd.tmp
164 $(srcdir)/..
/..
/move-if-change bfd.tmp bfd.texi
168 stamp-cache
: $(MKDOC
) $(srcdir)/..
/cache.c
$(srcdir)/doc.str
169 $(MKDOC
) -f
$(srcdir)/doc.str
< $(srcdir)/..
/cache.c
>cache.tmp
170 $(srcdir)/..
/..
/move-if-change cache.tmp cache.texi
172 cache.texi
: stamp-cache
174 stamp-coffcode
: $(MKDOC
) $(srcdir)/..
/coffcode.h
$(srcdir)/doc.str
175 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/coffcode.h
>coffcode.tmp
176 $(srcdir)/..
/..
/move-if-change coffcode.tmp coffcode.texi
178 coffcode.texi
: stamp-coffcode
180 stamp-core
: $(MKDOC
) $(srcdir)/..
/corefile.c
$(srcdir)/doc.str
181 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/corefile.c
>core.tmp
182 $(srcdir)/..
/..
/move-if-change core.tmp core.texi
184 core.texi
: stamp-core
186 stamp-elf
: $(MKDOC
) $(srcdir)/..
/elf.c
$(srcdir)/doc.str
187 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/elf.c
>elf.tmp
188 $(srcdir)/..
/..
/move-if-change elf.tmp elf.texi
192 stamp-elfcode
: $(MKDOC
) $(srcdir)/..
/elfcode.h
$(srcdir)/doc.str
193 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/elfcode.h
>elfcode.tmp
194 $(srcdir)/..
/..
/move-if-change elfcode.tmp elfcode.texi
196 elfcode.texi
: stamp-elfcode
198 stamp-format
: $(MKDOC
) $(srcdir)/..
/format.c
$(srcdir)/doc.str
199 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/format.c
>format.tmp
200 $(srcdir)/..
/..
/move-if-change format.tmp format.texi
202 format.texi
: stamp-format
204 stamp-libbfd
: $(MKDOC
) $(srcdir)/..
/libbfd.c
$(srcdir)/doc.str
205 $(MKDOC
) -f
$(srcdir)/doc.str
< $(srcdir)/..
/libbfd.c
>libbfd.tmp
206 $(srcdir)/..
/..
/move-if-change libbfd.tmp libbfd.texi
208 libbfd.texi
: stamp-libbfd
210 stamp-opncls
: $(MKDOC
) $(srcdir)/..
/opncls.c
$(srcdir)/doc.str
211 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/opncls.c
>opncls.tmp
212 $(srcdir)/..
/..
/move-if-change opncls.tmp opncls.texi
214 opncls.texi
: stamp-opncls
216 stamp-reloc
: $(MKDOC
) $(srcdir)/..
/reloc.c
217 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/reloc.c
>reloc.tmp
218 $(srcdir)/..
/..
/move-if-change reloc.tmp reloc.texi
220 reloc.texi
: stamp-reloc
222 stamp-section
: $(MKDOC
) $(srcdir)/..
/section.c
$(srcdir)/doc.str
223 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/section.c
>section.tmp
224 $(srcdir)/..
/..
/move-if-change section.tmp section.texi
226 section.texi
: stamp-section
228 stamp-syms
: $(MKDOC
) $(srcdir)/..
/syms.c
229 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/syms.c
>syms.tmp
230 $(srcdir)/..
/..
/move-if-change syms.tmp syms.texi
232 syms.texi
: stamp-syms
234 stamp-targets
: $(MKDOC
) $(srcdir)/..
/targets.c
$(srcdir)/doc.str
235 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/targets.c
>targets.tmp
236 $(srcdir)/..
/..
/move-if-change targets.tmp targets.texi
238 targets.texi
: stamp-targets
240 stamp-init
: $(MKDOC
) $(srcdir)/..
/init.c
$(srcdir)/doc.str
241 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/init.c
>init.tmp
242 $(srcdir)/..
/..
/move-if-change init.tmp init.texi
244 init.texi
: stamp-init
246 stamp-hash
: $(MKDOC
) $(srcdir)/..
/hash.c
$(srcdir)/doc.str
247 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/hash.c
>hash.tmp
248 $(srcdir)/..
/..
/move-if-change hash.tmp hash.texi
250 hash.texi
: stamp-hash
252 stamp-linker
: $(MKDOC
) $(srcdir)/..
/linker.c
$(srcdir)/doc.str
253 $(MKDOC
) -f
$(srcdir)/doc.str
<$(srcdir)/..
/linker.c
>linker.tmp
254 $(srcdir)/..
/..
/move-if-change linker.tmp linker.texi
256 linker.texi
: stamp-linker
258 libbfd.h
: $(srcdir)/..
/libbfd-in.h \
259 $(srcdir)/..
/init.c \
260 $(srcdir)/..
/libbfd.c \
261 $(srcdir)/..
/cache.c \
262 $(srcdir)/..
/reloc.c \
263 $(srcdir)/..
/cpu-h8300.c \
264 $(srcdir)/..
/cpu-i960.c \
265 $(srcdir)/..
/archures.c \
266 $(srcdir)/..
/elfcode.h \
267 $(srcdir)/proto.str \
269 cat
$(srcdir)/..
/libbfd-in.h
>libbfd.h
270 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/init.c
>>libbfd.h
271 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/libbfd.c
>>libbfd.h
272 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/cache.c
>>libbfd.h
273 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/reloc.c
>>libbfd.h
274 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/cpu-h8300.c
>>libbfd.h
275 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/cpu-i960.c
>>libbfd.h
276 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/archures.c
>>libbfd.h
277 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/elf.c
>>libbfd.h
278 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/elfcode.h
>>libbfd.h
280 libcoff.h
: $(srcdir)/..
/libcoff-in.h \
281 $(srcdir)/..
/coffcode.h \
282 $(srcdir)/proto.str \
284 cat
$(srcdir)/..
/libcoff-in.h
>libcoff.h
285 $(MKDOC
) -i
-f
$(srcdir)/proto.str
< $(srcdir)/..
/coffcode.h
>>libcoff.h
287 bfd.h
: $(srcdir)/..
/bfd-in.h \
288 $(srcdir)/..
/init.c \
289 $(srcdir)/..
/opncls.c \
290 $(srcdir)/..
/libbfd.c \
291 $(srcdir)/..
/section.c \
292 $(srcdir)/..
/archures.c \
293 $(srcdir)/..
/reloc.c \
294 $(srcdir)/..
/syms.c \
296 $(srcdir)/..
/archive.c \
297 $(srcdir)/..
/corefile.c \
298 $(srcdir)/..
/targets.c \
299 $(srcdir)/..
/format.c \
300 $(srcdir)/proto.str \
302 cat
$(srcdir)/..
/bfd-in.h
>bfd.h
303 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/init.c
>>bfd.h
304 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/opncls.c
>>bfd.h
305 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/libbfd.c
>>bfd.h
306 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/section.c
>>bfd.h
307 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/archures.c
>>bfd.h
308 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/reloc.c
>>bfd.h
309 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/syms.c
>>bfd.h
310 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/bfd.c
>>bfd.h
311 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/archive.c
>>bfd.h
312 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/corefile.c
>>bfd.h
313 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/targets.c
>>bfd.h
314 $(MKDOC
) -f
$(srcdir)/proto.str
<$(srcdir)/..
/format.c
>>bfd.h
315 echo
"#ifdef __cplusplus" >>bfd.h
317 echo
"#endif" >>bfd.h
318 echo
"#endif" >>bfd.h
324 rm -rf
*.log
*.ps
*~
* *.
dvi *# $(MKDOC) *.o
327 rm -rf
$(STAGESTUFF
) stamp-
*
328 rm -f
*.p
*.ip bfd.?? bfd.??? bfd.h libbfd.h libcoff.h texput.log
330 distclean: mostlyclean
331 rm -f
*.p
*.ip bfd.?? bfd.??? bfd.h libbfd.h libcoff.h texput.log
333 rm -f Makefile config.status
335 maintainer-clean
realclean: clean
336 rm -f Makefile config.status
338 bfd.
info: $(DOCFILES
) bfdsumm.texi bfd.texinfo
339 $(MAKEINFO
) -I
$(srcdir) -o bfd.
info $(srcdir)/bfd.texinfo
341 bfd.
dvi: $(DOCFILES
) bfdsumm.texi bfd.texinfo
342 $(TEXI2DVI
) $(srcdir)/bfd.texinfo
347 quickdoc
: $(DOCFILES
) bfdsumm.texi bfd.texinfo
348 TEXINPUTS
=${TEXIDIR}:.
:$$TEXINPUTS tex bfd.texinfo
352 - mv
-f
$(STAGESTUFF
) stage1
356 - mv
-f
$(STAGESTUFF
) stage2
360 - mv
-f
$(STAGESTUFF
) stage3
365 for i in
$(STAGESTUFF
) ; do cmp
$$i $(against
)/$$i || exit
1 ; done
368 - (cd stage1
; mv
-f
$(STAGESTUFF
) ..
)
372 - (cd stage2
; mv
-f
$(STAGESTUFF
) ..
)
376 - (cd stage3
; mv
-f
$(STAGESTUFF
) ..
)
381 Makefile
: $(srcdir)/Makefile.in
382 cd ..
&& CONFIG_FILES
=doc
/$@ CONFIG_HEADERS
= $(SHELL
) .
/config.status