[ovs-dev] [PATCH 4/7] man: fix pic issue at the source

Chris Wright chrisw at sous-sol.org
Fri Dec 9 07:36:03 UTC 2011


The commit 0993b66 (man: pic failed to run during manpage-check) worked
around the manpage-check warning generated by groff.  Using "-T ascii"
rather "-T utf8" was enough to silence the warning because the man page
has this condition in it:

  .if !'\*[.T]'ascii'

However, rpmlint generates the same warning as manpage-check was (it
uses -Tutf8), and manpages are generated using -Tutf8 (leading to an
fairly unreadable drawing).  So let's change the logic a bit and allow
pdf generation w/ nice drawing and kill it for tty's.

Cc: Ethan Jackson <ethan at nicira.com>
Signed-off-by: Chris Wright <chrisw at sous-sol.org>
---
 Makefile.am        |    2 +-
 ovsdb/ovsdb-doc.in |    3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index c0a7ade..51441ce 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -157,7 +157,7 @@ ALL_LOCAL += manpage-check
 manpage-check: $(man_MANS) $(dist_man_MANS) $(noinst_man_MANS)
 	@error=false; \
 	for manpage in $?; do \
-		LANG=en_US.UTF-8 groff -w mac -w delim -w escape -w input -w missing -w tab -T ascii -man -p -z $$manpage >$@.tmp 2>&1; \
+		LANG=en_US.UTF-8 groff -w mac -w delim -w escape -w input -w missing -w tab -T utf8 -man -p -z $$manpage >$@.tmp 2>&1; \
 		if grep warning: $@.tmp; then error=:; fi; \
 		rm -f $@.tmp; \
 	done; \
diff --git a/ovsdb/ovsdb-doc.in b/ovsdb/ovsdb-doc.in
index 5aac1ad..53292b3 100755
--- a/ovsdb/ovsdb-doc.in
+++ b/ovsdb/ovsdb-doc.in
@@ -312,7 +312,8 @@ Purpose
 
     if erFile:
         s += """
-.if !'\*[.T]'ascii' \{
+.\\" check if in troff mode (TTY)
+.if t \{
 .bp
 .SH "TABLE RELATIONSHIPS"
 .PP
-- 
1.7.7.3



More information about the dev mailing list