btrfs-progs: docs: add html build target

We can easily build the documentation in html format:

 $ make html

in the Documentation directory.

Signed-off-by: David Sterba <dsterba@suse.com>
master
David Sterba 2015-10-07 14:36:34 +02:00
parent d3d1a995a5
commit 4ee3d2e94d
2 changed files with 11 additions and 1 deletions

1
.gitignore vendored
View File

@ -7,6 +7,7 @@ version.h
version
man/*.gz
Documentation/*.gz
Documentation/*.html
btrfs
btrfs.static
btrfs-debug-tree

View File

@ -36,6 +36,7 @@ MAN5_TXT += btrfs-mount.asciidoc
MAN_TXT = $(MAN8_TXT) $(MAN5_TXT)
MAN_XML = $(patsubst %.asciidoc,%.xml,$(MAN_TXT))
MAN_HTML = $(patsubst %.asciidoc,%.html,$(MAN_TXT))
DOC_MAN5 = $(patsubst %.asciidoc,%.5,$(MAN5_TXT))
GZ_MAN5 = $(patsubst %.asciidoc,%.5.gz,$(MAN5_TXT))
@ -81,6 +82,7 @@ all: man
man: man5 man8
man5: $(GZ_MAN5)
man8: $(GZ_MAN8)
html: $(MAN_HTML)
install: install-man
@ -100,7 +102,7 @@ uninstall:
$(RMDIR) -p --ignore-fail-on-non-empty $(DESTDIR)$(man8dir)
clean:
$(QUIET_RM)$(RM) -f *.xml *.xml+ *.5 *.5.gz *.8 *.8.gz
$(QUIET_RM)$(RM) -f *.xml *.xml+ *.5 *.5.gz *.8 *.8.gz *.html
%.5.gz : %.5
$(QUIET_GZIP)$(GZIPCMD) -n -c $< > $@
@ -122,3 +124,10 @@ clean:
$(ASCIIDOC_EXTRA) -abtrfs_version=$(BTRFS_VERSION) \
-o $@+ $< && \
$(MV) $@+ $@
%.html : %.asciidoc asciidoc.conf
$(QUIET_ASCIIDOC)$(RM) -f $@+ $@ && \
$(ASCIIDOC) -b html -d article -f asciidoc.conf \
$(ASCIIDOC_EXTRA) -abtrfs_version=$(BTRFS_VERSION) \
-o $@+ $< && \
$(MV) $@+ $@