Merge pull request #247 from davidgiven/llgen
Generate HTML versions of the LLgen documentation as well.
This commit is contained in:
commit
4e816eb81f
|
@ -29,6 +29,7 @@ DOCS = \
|
||||||
OBJS = $(patsubst %.c, $(OBJDIR)/%.o, $(SRCS))
|
OBJS = $(patsubst %.c, $(OBJDIR)/%.o, $(SRCS))
|
||||||
DEPS = $(patsubst %.c, $(OBJDIR)/%.d, $(SRCS))
|
DEPS = $(patsubst %.c, $(OBJDIR)/%.d, $(SRCS))
|
||||||
PDFS = $(patsubst doc/%.n, $(OBJDIR)/%.pdf, $(DOCS))
|
PDFS = $(patsubst doc/%.n, $(OBJDIR)/%.pdf, $(DOCS))
|
||||||
|
HTMLS = $(patsubst doc/%.n, $(OBJDIR)/%/index.html, $(DOCS))
|
||||||
|
|
||||||
all: LLgen doc
|
all: LLgen doc
|
||||||
|
|
||||||
|
@ -41,14 +42,18 @@ $(OBJDIR)/%.o: %.c
|
||||||
|
|
||||||
$(OBJDIR)/%.pdf: doc/%.n doc/LLgen.refs
|
$(OBJDIR)/%.pdf: doc/%.n doc/LLgen.refs
|
||||||
@mkdir -p $(dir $@)
|
@mkdir -p $(dir $@)
|
||||||
groff -R -G -e -g -p -ms -Tpdf $< > $@
|
refer $< | groff -G -e -g -p -ms -Tpdf $< > $@
|
||||||
|
|
||||||
doc:: $(PDFS)
|
$(OBJDIR)/%/index.html: doc/%.n doc/LLgen.refs
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
refer $< | (cd $(dir $@) && groff -I$(PWD) -G -e -g -p -ms -Thtml) > $@
|
||||||
|
|
||||||
|
doc:: $(PDFS) $(HTMLS)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -rf $(OBJDIR)
|
rm -rf $(OBJDIR)
|
||||||
|
|
||||||
install: LLgen doc/LLgen.1 $(PDFS) $(wildcard lib/*)
|
install: LLgen doc/LLgen.1 $(PDFS) $(HTMLS) $(wildcard lib/*)
|
||||||
install -D -s LLgen -t $(PREFIX)/bin
|
install -D -s LLgen -t $(PREFIX)/bin
|
||||||
install -D doc/LLgen.1 -t $(PREFIX)/man/man1
|
install -D doc/LLgen.1 -t $(PREFIX)/man/man1
|
||||||
install -D $(OBJDIR)/LLgen.pdf -t $(PREFIX)/doc/LLgen
|
install -D $(OBJDIR)/LLgen.pdf -t $(PREFIX)/doc/LLgen
|
||||||
|
|
Loading…
Reference in a new issue