From 3e39f931e39a81870f966f8e9fe24e1dd447e51b Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 3 Jun 2020 13:03:34 +1000 Subject: man: swap __ for @ in the sed substitutions meson cannot replace __foo__ easily, it's built to substitute only @foo@. So as prep-work let's switch to that notation but add an extra sed to swap that back to the __foo__ notation for autotools. That one can't switch away from that either because it relies on MAN_SUBST which is filled in by xorg-macros.m4. Signed-off-by: Peter Hutterer --- man/Makefile.am | 3 ++- man/man.xsl | 24 ++++++++++++------------ 2 files changed, 14 insertions(+), 13 deletions(-) (limited to 'man') diff --git a/man/Makefile.am b/man/Makefile.am index 8d55603..8b3946d 100644 --- a/man/Makefile.am +++ b/man/Makefile.am @@ -11,7 +11,8 @@ MAN_SUBSTS += -e 's|__xkb_base__|$(xkb_base)|g' xkeyboard-config.man: $(top_srcdir)/rules/evdev.xml $(srcdir)/man.xsl $(XSLTPROC) -nonet $(srcdir)/man.xsl $(top_srcdir)/rules/evdev.xml > $@ +# First sed swaps @appmansuffix@ back to __appmansuffix__ for the MAN_SUBSTS .man.$(MISC_MAN_SUFFIX): - $(SED) $(MAN_SUBSTS) < $< > $@ + $(SED) -e 's|@\(\<[a-z_]*\>\)@|__\1__|g' < $< | $(SED) $(MAN_SUBSTS) > $@ endif diff --git a/man/man.xsl b/man/man.xsl index a5bd14d..883cfa3 100644 --- a/man/man.xsl +++ b/man/man.xsl @@ -3,13 +3,13 @@ -- cgit v1.2.1