]> git.ipfire.org Git - thirdparty/kmod.git/blob - man/Makefile.am
libkmod: keep KMOD_FILE_COMPRESSION_NONE/load_reg in comp_types
[thirdparty/kmod.git] / man / Makefile.am
1 MAN5 = depmod.d.5 modprobe.d.5 modules.dep.5
2 MAN8 = kmod.8 depmod.8 insmod.8 lsmod.8 rmmod.8 modprobe.8 modinfo.8
3 MAN_STUB = modules.dep.bin.5
4
5 AM_V_XSLT = $(AM_V_XSLT_$(V))
6 AM_V_XSLT_ = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
7 AM_V_XSLT_0 = @echo " XSLT " $@;
8
9 XSLT = $(if $(XSLTPROC), $(XSLTPROC), xsltproc)
10
11 if BUILD_TOOLS
12 dist_man_MANS = $(MAN5) $(MAN8) $(MAN_STUB)
13 modules.dep.bin.5: modules.dep.5
14 endif
15
16 EXTRA_DIST = $(MAN5:%.5=%.5.xml) $(MAN8:%.8=%.8.xml)
17 CLEANFILES = $(dist_man_MANS)
18
19 define generate_manpage
20 $(AM_V_XSLT)if [ '$(distconfdir)' != '/lib' ] ; then \
21 sed -e 's|@DISTCONFDIR@|$(distconfdir)|g' $< ; \
22 else \
23 sed -e '/@DISTCONFDIR@/d' $< ; \
24 fi | \
25 sed -e 's|@MODULE_DIRECTORY@|$(module_directory)|g' | \
26 $(XSLT) \
27 -o $@ \
28 --nonet \
29 --stringparam man.output.quietly 1 \
30 --param funcsynopsis.style "'ansi'" \
31 http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl -
32 endef
33
34 %.5: %.5.xml
35 $(generate_manpage)
36
37 %.8: %.8.xml
38 $(generate_manpage)