diff options
author | Tedd Ho-Jeong An <tedd.an@intel.com> | 2021-05-03 22:02:05 -0700 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2021-05-04 16:49:01 -0700 |
commit | b66f406e1e15fb7137412963b82ad143e4a4cd93 (patch) | |
tree | 8e78a9810b74998a891d06a776edd8d8321e5bd1 /Makefile.am | |
parent | c0cae92548b4716869b440c3d454ff4517d1fde1 (diff) | |
download | bluez-b66f406e1e15fb7137412963b82ad143e4a4cd93.tar.gz |
monitor: Convert manpage to rst format
This patch adds support to convert reStructuredText formatted btmon
manpage to manpage with rst2man tool.
Diffstat (limited to 'Makefile.am')
-rw-r--r-- | Makefile.am | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am index cb0d5fc0a..4e9cae885 100644 --- a/Makefile.am +++ b/Makefile.am @@ -594,7 +594,7 @@ if LIBRARY pkgconfig_DATA = lib/bluez.pc endif -EXTRA_DIST += $(manual_pages:.1=.txt) +EXTRA_DIST += $(manual_pages:.1=.rst) DISTCHECK_CONFIGURE_FLAGS = --disable-datafiles --enable-library \ --enable-health \ @@ -616,11 +616,20 @@ SED_PROCESS = $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \ $(SED) -e 's,@pkglibexecdir\@,$(pkglibexecdir),g' \ < $< > $@ +if RUN_RST2MAN +RST2MAN_PROCESS = $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \ + $(RST2MAN) --strict --no-raw \ + --no-generator --no-datestamp $< $@ +else +RST2MAN_PROCESS = $(AM_V_GEN)test -f $@ || \ + { echo "Generated manual page $@ does not exist"; false; } +endif + %.service: %.service.in Makefile $(SED_PROCESS) -%.1: %.txt - $(AM_V_GEN)a2x --doctype manpage --format manpage $(srcdir)/$< +%.1: %.rst Makefile + $(RST2MAN_PROCESS) src/builtin.h: src/genbuiltin $(builtin_sources) $(AM_V_GEN)$(srcdir)/src/genbuiltin $(builtin_modules) > $@ |