5 .PHONY: all mostlyclean clean install zip doc html info
9 htmldir = $(PREFIX)/share/doc/cc65$(DESTPACKAGE_SUFFIX)/html
10 infodir = $(PREFIX)/share/info
14 doc clean install zip:
18 SGMLS := $(wildcard *.sgml)
20 ../html/coding.html ../html/index.html: \
29 html: $(addprefix ../html/,$(SGMLS:.sgml=.html) doc.css doc.png)
31 info: $(addprefix ../info/,$(SGMLS:.sgml=.info))
36 ../html/%.html: %.sgml header.html | ../html
37 @cd ../html && linuxdoc -B html -s 0 -T $(TOC_LEVEL) -H ../doc/header.html ../doc/$<
39 ../html/doc.%: doc.% | ../html
42 ../info/%.info: %.sgml | ../info
43 @cd ../info && linuxdoc -B info ../doc/$<
46 $(RM) -r ../html ../info
49 $(if $(PREFIX),,$(error variable `PREFIX' must be set))
50 ifeq ($(wildcard ../html),../html)
51 $(INSTALL) -d $(DESTDIR)$(htmldir)
52 $(INSTALL) -m0644 ../html/*.* $(DESTDIR)$(htmldir)
54 ifeq ($(wildcard ../info),../info)
55 $(INSTALL) -d $(DESTDIR)$(infodir)
56 $(INSTALL) -m0644 ../info/*.* $(DESTDIR)$(infodir)
60 ifneq "$(wildcard ../html)" ""
61 @cd .. && zip cc65 html/*.*