summaryrefslogblamecommitdiff
path: root/user/i3status/asciidoctor.patch
blob: 575a00e1bee3412fd4015e322f83a83698622bff (plain) (tree)
















































                                                                                                       
From 1821c7cd94e2424352f0fcb1f2933b368a4c381c Mon Sep 17 00:00:00 2001
From: Luis Ressel <aranea@aixah.de>
Date: Tue, 9 Jul 2019 13:18:43 +0200
Subject: [PATCH] Build man pages with asciidoctor

asciidoctor doesn't support the -f option. Furthermore, its docbook
output appears to be unsuitable for xmlto, so make it generate a manpage
directly.
---
 Makefile.am  | 7 ++-----
 configure.ac | 3 ---
 2 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index bb251f0..93ef552 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -11,13 +11,10 @@ dist_man1_MANS = \
 asciidoc_MANS = \
 	man/i3status.1
 
-$(asciidoc_MANS): man/%.1: man/%.xml man/$(dirstamp)
-	$(AM_V_GEN) out='$@'; @PATH_XMLTO@ man -o "$${out%/*}" $<
+$(asciidoc_MANS): man/%.1: man/%.man man/$(dirstamp)
+	$(AM_V_GEN) @PATH_ASCIIDOC@ -d manpage -b manpage -o $@ $<
 	@stamp='$@'; $(MKDIR_P) "$${stamp%/*}"
 
-man/%.xml: man/%.man man/asciidoc.conf man/$(dirstamp)
-	$(AM_V_GEN) @PATH_ASCIIDOC@ -d manpage -b docbook -f $(top_builddir)/man/asciidoc.conf -o $@ $<
-
 AM_CPPFLAGS = \
 	-DSYSCONFDIR="\"$(sysconfdir)\"" \
 	-I$(top_srcdir)/include \
diff --git a/configure.ac b/configure.ac
index cf9e430..78c4aa5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -104,9 +104,6 @@ AC_PROG_LN_S
 AC_PATH_PROG([PATH_ASCIIDOC], [asciidoc], [no])
 AS_IF([test x"$PATH_ASCIIDOC" = x"no"],
       [AC_MSG_ERROR([asciidoc is required for generating man pages])])
-AC_PATH_PROG([PATH_XMLTO], [xmlto], [no])
-AS_IF([test x"$PATH_XMLTO" = x"no"],
-      [AC_MSG_ERROR([xmlto is required for generating man pages])])
 
 AM_PROG_AR
 
-- 
2.22.0