gri3-wm/man/man.mk

43 lines
822 B
Makefile
Raw Normal View History

2012-06-17 14:52:41 +02:00
DISTCLEAN_TARGETS += clean-mans
A2X = a2x
2012-12-11 22:31:44 +01:00
POD2MAN = pod2man
2012-06-17 14:52:41 +02:00
A2X_MAN_CALL = $(V_A2X)$(A2X) -f manpage --asciidoc-opts="-f man/asciidoc.conf" $(A2X_FLAGS) $<
2012-12-11 22:31:44 +01:00
POD2MAN_CALL = $(V_POD2MAN)$(POD2MAN) --utf8 $< > $@
2012-06-17 14:52:41 +02:00
2012-12-11 22:31:44 +01:00
MANS_ASCIIDOC = \
2012-06-17 14:52:41 +02:00
man/i3.1 \
man/i3bar.1 \
man/i3-msg.1 \
man/i3-input.1 \
man/i3-nagbar.1 \
man/i3-config-wizard.1 \
man/i3-migrate-config-to-v4.1 \
man/i3-sensible-editor.1 \
man/i3-sensible-pager.1 \
man/i3-sensible-terminal.1 \
man/i3-dump-log.1
2012-12-11 22:31:44 +01:00
MANS_POD = \
man/i3-dmenu-desktop.1 \
man/i3-save-tree.1
2012-12-11 22:31:44 +01:00
2012-06-17 14:52:41 +02:00
MANS = \
2012-12-11 22:31:44 +01:00
$(MANS_ASCIIDOC) \
$(MANS_POD)
2012-06-17 14:52:41 +02:00
mans: $(MANS)
2012-12-11 22:31:44 +01:00
$(MANS_ASCIIDOC): %.1: %.man man/asciidoc.conf
2012-06-17 14:52:41 +02:00
$(A2X_MAN_CALL)
$(MANS_POD): man/%.1: %
2012-12-11 22:31:44 +01:00
$(POD2MAN_CALL)
2012-06-17 14:52:41 +02:00
clean-mans:
for file in $(notdir $(MANS)); \
do \
rm -f man/$${file} man/$${file%.*}.html man/$${file%.*}.xml; \
done