Remove remnants of non-interleavable raw slot spport.
[sbcl.git] / doc / manual / Makefile
blobd559996dcc54e308f9b138fefd929fd3aa09f2a9
1 SBCLTEXI:=sbcl.texinfo
2 ASDFTEXI:=asdf.texinfo version.texinfo
3 DOCFILES:=*.texinfo $(ASDFTEXI)
4 TMPTYPES:=aux cp cps fn fns ky log pg toc tp tps vr vrs
5 TMPFILES:=$(foreach target,asdf sbcl,$(foreach type,$(TMPTYPES),$(target).$(type)))
6 PSFILES=sbcl.ps asdf.ps
7 PDFFILES=sbcl.pdf asdf.pdf
8 INFOFILES=sbcl.info asdf.info
9 HTMLDIRS=$(basename $(SBCLTEXI)) $(basename $(ASDFTEXI))
10 HTMLFILES=sbcl.html asdf.html
11 # Place where generated documentation ends up. The value of
12 # DOCSTRINGDIR has to end with a slash or you lose (it's passed to
13 # Lisp's `pathname' function).
14 DOCSTRINGDIR="docstrings/"
15 CONTRIB_SRC_DIR="../../contrib/"
16 CONTRIB_OBJ_DIR="../../obj/asdf-cache/"
17 I_FLAGS=-I $(DOCSTRINGDIR) -I $(CONTRIB_SRC_DIR)
18 # List of contrib modules that docstring docs will be created for.
19 MODULES=':sb-md5 :sb-queue :sb-concurrency :sb-rotate-byte :sb-grovel \
20 :sb-sprof :sb-bsd-sockets :sb-cover :sb-posix'
21 # List of package names that docstring docs will be created for.
22 PACKAGES=":COMMON-LISP :SB-ALIEN :SB-DEBUG :SB-EXT :SB-GRAY :SB-MOP \
23 :SB-PCL :SB-SYS :SB-SEQUENCE :SB-UNICODE \
24 :SB-PROFILE :SB-THREAD :SB-MD5 :SB-QUEUE :SB-ROTATE-BYTE \
25 :SB-SPROF :SB-BSD-SOCKETS :SB-COVER :SB-POSIX :SB-CONCURRENCY"
27 # SBCL_SYSTEM is an optional argument to this make program. If this
28 # variable is set, its contents are used as the command line for
29 # invoking SBCL.
31 # When passing a non-standard SBCL_SYSTEM, be sure to set the
32 # environment variable SBCL_HOME to a useful value, as well.
34 ifeq ($(MAKEINFO),)
35 MAKEINFO:=makeinfo
36 endif
38 ifeq ($(TEXI2PDF),)
39 TEXI2PDF:=texi2dvi -p
40 endif
42 ifeq ($(DVIPS),)
43 DVIPS:=dvips
44 endif
46 .PHONY: all
47 all: $(ASDFTEXI) ps pdf info html
49 .PHONY: dist
50 dist: html pdf
52 asdf.texinfo:
53 rm -f asdf.texinfo
54 ln -s ../../contrib/asdf/asdf.texinfo
56 version.texinfo:
57 rm -f version.texinfo
58 ln -s ../../contrib/asdf/version.texinfo
60 # html documentation; output in $(HTMLDIRS)
61 .PHONY: html
62 html: html-stamp
64 html-stamp: $(DOCFILES) docstrings
65 @rm -rf $(HTMLDIRS)
66 @rm -f $(HTMLFILES)
67 # $(MAKEINFO) $(I_FLAGS) --html --css-include=style-multi.css $(SBCLTEXI)
68 # $(MAKEINFO) --html --css-include=style-multi.css $(ASDFTEXI)
69 $(MAKEINFO) $(I_FLAGS) --html --no-split --css-include=style-single.css $(SBCLTEXI)
70 $(MAKEINFO) --html --no-split --css-include=style-single.css $(ASDFTEXI)
71 touch html-stamp
73 # Postscript documentation
74 .PHONY: ps
75 ps: $(PSFILES)
77 %.ps: %.dvi
78 dvips -o $@ $<
80 # DVI generation
81 %.dvi: %.texinfo $(DOCFILES) docstrings
82 texi2dvi $(I_FLAGS) $<
84 # PDF documentation
85 .PHONY: pdf
86 pdf: $(PDFFILES)
88 %.pdf: %.texinfo $(DOCFILES) docstrings
89 $(TEXI2PDF) $(I_FLAGS) $<
91 # info docfiles
92 .PHONY: info
93 info: $(INFOFILES)
95 %.info: %.texinfo $(DOCFILES) docstrings
96 $(MAKEINFO) $(I_FLAGS) $<
98 # Texinfo docstring snippets
99 # Note: assumes contrib module names are the same as the names of
100 # directories containing the modules, and that these directories
101 # are in $(CONTRIB_OBJ_DIR).
102 CONTRIB_FASLS=$(shell find $(shell echo $(MODULES) | sed "s|:|$(CONTRIB_OBJ_DIR)|g") -name '*.fasl')
103 docstrings: $(CONTRIB_FASLS) tempfiles-stamp
104 for module in $(shell echo $(MODULES)); do \
105 test -f $(CONTRIB_OBJ_DIR)/`echo $$module | tr -d :`/test-passed.test-report \
106 || { echo "The documented contrib $$module seems \
107 to have failed its tests." && exit 1; } \
108 done
109 DOCSTRINGDIR=$(DOCSTRINGDIR) \
110 PACKAGES=$(PACKAGES) \
111 MODULES=$(MODULES) \
112 sh make-tempfiles.sh "$(SBCL_SYSTEM)" && touch $(DOCSTRINGDIR)
114 tempfiles-stamp:
115 touch tempfiles-stamp
117 .PHONY: clean
118 clean:
119 rm -f *~ *.bak *.orig \#*\# .\#* texput.log *.fasl
120 rm -rf $(HTMLDIRS) $(DOCSTRINGDIR)
121 rm -f $(HTMLFILES)
122 rm -f contrib-docs.texi-temp
123 rm -f package-locks.texi-temp
124 rm -f variables.texinfo
125 rm -f $(PSFILES) $(PDFFILES) html-stamp tempfiles-stamp
126 rm -f $(TMPFILES) $(INDEXFILES)
127 rm -f sbcl.info sbcl.info-* asdf.info
129 .PHONY: distclean
130 distclean: clean