提交 49ba028a 编写于 作者: A Andrea Bolognani

build: Replace variables in man pages

We can't use eg. @sysconfdir@ directly in the .pod file, because
pod2man(1) will interpret that as a variable name and format it
accordingly.

Instead, we use eg. SYSCONFDIR and use a subsequent sed(1) call
to turn it into the expected @sysconfdir@.
上级 f806febb
...@@ -508,8 +508,14 @@ endif ! WITH_LIBVIRTD ...@@ -508,8 +508,14 @@ endif ! WITH_LIBVIRTD
POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)" POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)"
%.8.in: %.pod %.8.in: %.pod
$(AM_V_GEN)$(POD2MAN) --section=8 $< $@ \ $(AM_V_GEN)$(POD2MAN) --section=8 $< $@-t1 && \
&& if grep 'POD ERROR' $@ ; then rm $@; exit 1; fi if grep 'POD ERROR' $@-t1; then rm $@-t1; exit 1; fi && \
sed \
-e 's|SYSCONFDIR|\@sysconfdir\@|g' \
-e 's|LOCALSTATEDIR|\@localstatedir\@|g' \
< $@-t1 > $@-t2 && \
rm -f $@-t1 && \
mv $@-t2 $@
%.8: %.8.in $(top_srcdir)/configure.ac %.8: %.8.in $(top_srcdir)/configure.ac
$(AM_V_GEN)sed \ $(AM_V_GEN)sed \
......
...@@ -2565,12 +2565,24 @@ virtlogd.init: logging/virtlogd.init.in $(top_builddir)/config.status ...@@ -2565,12 +2565,24 @@ virtlogd.init: logging/virtlogd.init.in $(top_builddir)/config.status
POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)" POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)"
virtlockd.8.in: locking/virtlockd.pod virtlockd.8.in: locking/virtlockd.pod
$(AM_V_GEN)$(POD2MAN) --section 8 $< $@ \ $(AM_V_GEN)$(POD2MAN) --section=8 $< $@-t1 && \
&& if grep 'POD ERROR' $@ ; then rm $@; exit 1; fi if grep 'POD ERROR' $@-t1; then rm $@-t1; exit 1; fi && \
sed \
-e 's|SYSCONFDIR|\@sysconfdir\@|g' \
-e 's|LOCALSTATEDIR|\@localstatedir\@|g' \
< $@-t1 > $@-t2 && \
rm -f $@-t1 && \
mv $@-t2 $@
virtlogd.8.in: logging/virtlogd.pod virtlogd.8.in: logging/virtlogd.pod
$(AM_V_GEN)$(POD2MAN) --section 8 $< $@ \ $(AM_V_GEN)$(POD2MAN) --section=8 $< $@-t1 && \
&& if grep 'POD ERROR' $@ ; then rm $@; exit 1; fi if grep 'POD ERROR' $@-t1; then rm $@-t1; exit 1; fi && \
sed \
-e 's|SYSCONFDIR|\@sysconfdir\@|g' \
-e 's|LOCALSTATEDIR|\@localstatedir\@|g' \
< $@-t1 > $@-t2 && \
rm -f $@-t1 && \
mv $@-t2 $@
%.8: %.8.in $(top_srcdir)/configure.ac %.8: %.8.in $(top_srcdir)/configure.ac
$(AM_V_GEN)sed \ $(AM_V_GEN)sed \
......
...@@ -280,12 +280,24 @@ endif WITH_WIN_ICON ...@@ -280,12 +280,24 @@ endif WITH_WIN_ICON
POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)" POD2MAN = pod2man -c "Virtualization Support" -r "$(PACKAGE)-$(VERSION)"
%.1.in: %.pod %.1.in: %.pod
$(AM_V_GEN)$(POD2MAN) $< $@ \ $(AM_V_GEN)$(POD2MAN) $< $@-t1 && \
&& if grep 'POD ERROR' $@ ; then rm $@; exit 1; fi if grep 'POD ERROR' $@-t1; then rm $@-t1; exit 1; fi && \
sed \
-e 's|SYSCONFDIR|\@sysconfdir\@|g' \
-e 's|LOCALSTATEDIR|\@localstatedir\@|g' \
< $@-t1 > $@-t2 && \
rm -f $@-t1 && \
mv $@-t2 $@
%.8.in: %.pod %.8.in: %.pod
$(AM_V_GEN)$(POD2MAN) --section=8 $< $@ \ $(AM_V_GEN)$(POD2MAN) --section=8 $< $@-t1 && \
&& if grep 'POD ERROR' $@ ; then rm $@; exit 1; fi if grep 'POD ERROR' $@-t1; then rm $@-t1; exit 1; fi && \
sed \
-e 's|SYSCONFDIR|\@sysconfdir\@|g' \
-e 's|LOCALSTATEDIR|\@localstatedir\@|g' \
< $@-t1 > $@-t2 && \
rm -f $@-t1 && \
mv $@-t2 $@
%.1: %.1.in $(top_srcdir)/configure.ac %.1: %.1.in $(top_srcdir)/configure.ac
$(AM_V_GEN)sed \ $(AM_V_GEN)sed \
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册