* bfd-in.h, libbfd-in.h, doc/Makefile, doc/tolibbfd, doc/intobfd:
[platform/upstream/binutils.git] / bfd / doc / Makefile
1 .SUFFIXES: .texi .o .c .h .p .ip
2 VPATH=..
3 .c.texi:
4         scanit $< $@
5
6 .h.texi:
7         scanit $< $@
8
9 .c.p:
10         scanph $< $@
11
12 .h.p:
13         scanph $< $@
14
15 .c.ip:
16         scanph -i $< $@
17
18
19 DOCFILES = aoutx.texi  archive.texi archures.texi \
20         bfd.texi  cache.texi coffcode.texi \
21         core.texi  format.texi  libbfd.texi  \
22         opncls.texi  reloc.texi  section.texi  \
23         syms.texi  targets.texi init.texi
24         
25
26 PROTOS = archive.p archures.p bfd.p \
27         coffcode.p core.p format.p \
28         libbfd.p opncls.p reloc.p \
29         section.p syms.p targets.p  \
30         format.p coffcode.p core.p machines.p init.p
31
32 IPROTOS = cache.ip libbfd.ip reloc.ip init.ip archures.ip
33
34 # SRCDOC, SRCPROT, SRCIPROT only used to sidestep Sun Make bug in interaction 
35 # between VPATH and suffix rules.  If you use GNU Make, perhaps other Makes,
36 # you don't need these three:
37 SRCDOC = aoutx.h  archive.c archures.c \
38         bfd.c  cache.c coffcode.h \
39         core.c  format.c  libbfd.c  \
40         opncls.c  reloc.c  section.c  \
41         syms.c  targets.c init.c
42
43 SRCPROT = archive.c archures.c bfd.c \
44         coffcode.h core.c format.c \
45         libbfd.c opncls.c reloc.c \
46         section.c syms.c targets.c init.c
47
48 SRCIPROT = cache.c libbfd.c reloc.c cpu-h8300.c  cpu-i960.c archures.c init.c
49
50
51 docs: protos bfd.info bfd.dvi bfd.ps
52
53 protos: $(PROTOS) $(IPROTOS)
54         sed -f intobfd bfd-in.h  > bfd.h
55         sed -f tolibbfd libbfd-in.h  > libbfd.h
56         sed -f tolibcoff libcoff-in.h  > libcoff.h
57
58 # Following three rules only for the benefit of Sun Make; see comment above
59 $(DOCFILES) : $(SRCDOC)
60 $(PROTOS) : $(SRCPROT)
61 $(IPROTOS) : $(SRCIPROT)
62
63 clean:
64         rm -f $(PROTOS) *.p *.ip *.h bfd.?? $(DOCFILES) bfd.dvi bfd.ps *~* *# bfd.??? 
65
66 bfd.info: $(DOCFILES) bfd.texinfo
67         makeinfo +no-validate bfd.texinfo
68
69 bfd.dvi: $(DOCFILES) bfd.texinfo
70         tex bfd.texinfo
71         texindex bfd.??
72         tex bfd.texinfo
73
74 bfd.ps: bfd.dvi
75         dvips bfd -o
76         
77 quickdoc: $(DSRC) docs
78         tex bfd.texinfo