1 BOOKS
:= wanbook.sgml z8530book.sgml mcabook.sgml videobook.sgml \
2 kernel-api.sgml parportbook.sgml kernel-hacking.sgml \
3 kernel-locking.sgml via-audio.sgml mousedrivers.sgml sis900.sgml
5 PS
:= $(patsubst %.sgml
, %.ps
, $(BOOKS
))
6 PDF
:= $(patsubst %.sgml
, %.pdf
, $(BOOKS
))
7 HTML
:= $(patsubst %.sgml
, %, $(BOOKS
))
8 IMG-parportbook
:= parport-share.fig parport-multi.fig parport-structure.fig
9 EPS-parportbook
:= $(patsubst %.fig
, %.eps
, $(IMG-parportbook
))
10 JPG-parportbook
:= $(patsubst %.fig
, %.jpeg
, $(IMG-parportbook
))
12 $(BOOKS
): $(TOPDIR
)/scripts
/docproc
14 .PHONY
: books ps pdf html
clean mrproper
30 $(TOPDIR
)/scripts
/docproc
:
31 $(MAKE
) -C
$(TOPDIR
)/scripts docproc
33 mousedrivers.sgml
: mousedrivers.tmpl
34 $(TOPDIR
)/scripts
/docgen
<$< >$@
36 kernel-hacking.sgml
: kernel-hacking.tmpl
37 $(TOPDIR
)/scripts
/docgen
<$< >$@
39 kernel-locking.sgml
: kernel-locking.tmpl
40 $(TOPDIR
)/scripts
/docgen
<$< >$@
42 wanbook.sgml
: wanbook.tmpl
$(TOPDIR
)/drivers
/net
/wan
/syncppp.c
43 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/net
/wan
/syncppp.c \
44 <wanbook.tmpl
>wanbook.sgml
46 z8530book.sgml
: z8530book.tmpl
$(TOPDIR
)/drivers
/net
/wan
/z85230.c
47 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/net
/wan
/z85230.c \
48 <z8530book.tmpl
>z8530book.sgml
50 via-audio.sgml
: via-audio.tmpl
$(TOPDIR
)/drivers
/sound
/via82cxxx_audio.c
51 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/sound
/via82cxxx_audio.c \
52 <via-audio.tmpl
>via-audio.sgml
54 sis900.sgml
: sis900.tmpl
$(TOPDIR
)/drivers
/net
/sis900.c
55 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/net
/sis900.c \
56 <sis900.tmpl
>sis900.sgml
58 mcabook.sgml
: mcabook.tmpl
$(TOPDIR
)/arch
/i386
/kernel
/mca.c
59 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/arch
/i386
/kernel
/mca.c \
60 <mcabook.tmpl
>mcabook.sgml
62 videobook.sgml
: videobook.tmpl
$(TOPDIR
)/drivers
/media
/video
/videodev.c
63 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/media
/video
/videodev.c \
64 <videobook.tmpl
>videobook.sgml
66 APISOURCES
:= $(TOPDIR
)/drivers
/media
/video
/videodev.c \
67 $(TOPDIR
)/arch
/i386
/kernel
/mca.c \
68 $(TOPDIR
)/arch
/i386
/kernel
/mtrr.c \
69 $(TOPDIR
)/drivers
/char
/misc.c \
70 $(TOPDIR
)/drivers
/net
/net_init.c \
71 $(TOPDIR
)/drivers
/net
/8390.c \
72 $(TOPDIR
)/drivers
/char
/serial.c \
73 $(TOPDIR
)/drivers
/pci
/pci.c \
74 $(TOPDIR
)/drivers
/block
/ll_rw_blk.c \
75 $(TOPDIR
)/drivers
/sound
/sound_core.c \
76 $(TOPDIR
)/drivers
/sound
/sound_firmware.c \
77 $(TOPDIR
)/drivers
/net
/wan
/syncppp.c \
78 $(TOPDIR
)/drivers
/net
/wan
/z85230.c \
79 $(TOPDIR
)/drivers
/usb
/usb.c \
80 $(TOPDIR
)/fs
/locks.c \
81 $(TOPDIR
)/fs
/devfs
/base.c \
82 $(TOPDIR
)/kernel
/pm.c \
83 $(TOPDIR
)/kernel
/ksyms.c \
84 $(TOPDIR
)/net
/netsyms.c
86 kernel-api.sgml
: kernel-api.tmpl
$(APISOURCES
)
87 $(TOPDIR
)/scripts
/docgen
$(APISOURCES
) \
88 <kernel-api.tmpl
>kernel-api.sgml
90 kernel-api-man
: $(APISOURCES
)
91 @
rm -rf
$(TOPDIR
)/Documentation
/man
92 $(TOPDIR
)/scripts
/kernel-doc
-man
$^ | \
93 $(PERL
) $(TOPDIR
)/scripts
/split-man
$(TOPDIR
)/Documentation
/man
95 parportbook
: $(JPG-parportbook
)
96 parportbook.ps
: $(EPS-parportbook
)
97 parportbook.sgml
: parportbook.tmpl
$(TOPDIR
)/drivers
/parport
/init.c
98 $(TOPDIR
)/scripts
/docgen
$(TOPDIR
)/drivers
/parport
/init.c
<$< >$@
100 DVI
:= $(patsubst %.sgml
, %.
dvi, $(BOOKS
))
101 AUX
:= $(patsubst %.sgml
, %.aux
, $(BOOKS
))
102 TEX
:= $(patsubst %.sgml
, %.
tex, $(BOOKS
))
103 LOG
:= $(patsubst %.sgml
, %.log
, $(BOOKS
))
104 OUT
:= $(patsubst %.sgml
, %.out
, $(BOOKS
))
109 -$(RM
) $(DVI
) $(AUX
) $(TEX
) $(LOG
) $(OUT
)
110 -$(RM
) $(JPG-parportbook
) $(EPS-parportbook
)
116 -$(RM
) $(TOPDIR
)/scripts
/mkdep-docbook
119 @
(which db2ps
> /dev
/null
2>&1) || \
120 (echo
"*** You need to install DocBook stylesheets ***"; \
125 @
(which db2pdf
> /dev
/null
2>&1) || \
126 (echo
"*** You need to install DocBook stylesheets ***"; \
131 @
(which db2html
> /dev
/null
2>&1) || \
132 (echo
"*** You need to install DocBook stylesheets ***"; \
136 if
[ ! -z
"$(JPG-$@)" ]; then cp
$(JPG-
$@
) $@
; fi
139 # we could have our own dependency generator
142 # .depend: $(TOPDIR)/scripts/mkdep-docbook
143 # $(TOPDIR)/scripts/mkdep-docbook $(wildcard *.tmpl) > .depend
145 include $(TOPDIR
)/Rules.make