2012-09-28 15:44:19 -06:00
|
|
|
#
|
|
|
|
# This generates man-pages out of the Docbook XML files. Simply add your files
|
|
|
|
# to the $MANPAGES array. If aliases are created, please add them to the
|
|
|
|
# MANPAGES_ALIASES array so they get installed correctly.
|
|
|
|
#
|
|
|
|
|
|
|
|
MANPAGES = \
|
2012-09-28 15:44:20 -06:00
|
|
|
drm.7 \
|
2012-09-28 15:44:21 -06:00
|
|
|
drm-kms.7 \
|
2012-09-28 15:44:22 -06:00
|
|
|
drm-memory.7 \
|
2012-09-28 15:44:19 -06:00
|
|
|
drmAvailable.3 \
|
|
|
|
drmHandleEvent.3 \
|
|
|
|
drmModeGetResources.3
|
2012-09-28 15:44:22 -06:00
|
|
|
MANPAGES_ALIASES = \
|
|
|
|
drm-mm.7 \
|
|
|
|
drm-gem.7 \
|
|
|
|
drm-ttm.7
|
2012-09-28 15:44:19 -06:00
|
|
|
|
|
|
|
XML_FILES = \
|
2013-01-18 05:22:01 -07:00
|
|
|
$(patsubst %.1,%.xml,$(patsubst %.3,%.xml,$(patsubst %.5,%.xml,$(patsubst %.7,%.xml,$(MANPAGES)))))
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
EXTRA_DIST = $(XML_FILES)
|
|
|
|
CLEANFILES = $(MANPAGES) $(MANPAGES_ALIASES) .man_fixup
|
2012-09-28 15:44:19 -06:00
|
|
|
man_MANS =
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
if BUILD_MANPAGES
|
|
|
|
if HAVE_MANPAGES_STYLESHEET
|
2012-09-28 15:44:19 -06:00
|
|
|
|
|
|
|
man_MANS += $(MANPAGES) $(MANPAGES_ALIASES)
|
|
|
|
|
|
|
|
XSLTPROC_FLAGS = \
|
|
|
|
--stringparam man.authors.section.enabled 0 \
|
|
|
|
--stringparam man.copyright.section.enabled 0 \
|
|
|
|
--stringparam funcsynopsis.style ansi \
|
2013-01-16 11:35:25 -07:00
|
|
|
--stringparam man.output.quietly 1 \
|
|
|
|
--nonet
|
2012-09-28 15:44:19 -06:00
|
|
|
|
|
|
|
XSLTPROC_PROCESS_MAN = \
|
|
|
|
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
|
2013-01-16 11:35:25 -07:00
|
|
|
$(XSLTPROC) -o "$@" $(XSLTPROC_FLAGS) $(MANPAGES_STYLESHEET) "$<" && \
|
|
|
|
touch .man_fixup
|
2012-09-28 15:44:19 -06:00
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
# Force .man_fixup if $(MANPAGES) are not built
|
|
|
|
.man_fixup: | $(MANPAGES)
|
|
|
|
@touch .man_fixup
|
|
|
|
|
|
|
|
$(MANPAGES_ALIASES): $(MANPAGES) .man_fixup
|
|
|
|
$(AM_V_GEN)if test -n "$@" ; then $(SED) -i -e 's/^\.so \([a-z_]\+\)\.\([0-9]\)$$/\.so man\2\/\1\.\2/' "$@" ; fi
|
|
|
|
|
|
|
|
%.1: $(top_srcdir)/man/%.xml
|
2012-09-28 15:44:19 -06:00
|
|
|
$(XSLTPROC_PROCESS_MAN)
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
%.3: $(top_srcdir)/man/%.xml
|
2012-09-28 15:44:19 -06:00
|
|
|
$(XSLTPROC_PROCESS_MAN)
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
%.5: $(top_srcdir)/man/%.xml
|
2012-09-28 15:44:19 -06:00
|
|
|
$(XSLTPROC_PROCESS_MAN)
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
%.7: $(top_srcdir)/man/%.xml
|
2012-09-28 15:44:19 -06:00
|
|
|
$(XSLTPROC_PROCESS_MAN)
|
|
|
|
|
2013-01-16 11:35:25 -07:00
|
|
|
endif # HAVE_MANPAGES_STYLESHEET
|
|
|
|
endif # BUILD_MANPAGES
|