Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Oct 2016 23:18:41 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r306885 - projects/doctools/usr.bin/man
Message-ID:  <201610082318.u98NIfxu014315@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Sat Oct  8 23:18:41 2016
New Revision: 306885
URL: https://svnweb.freebsd.org/changeset/base/306885

Log:
  When a manpage cannot be rendered with mandoc(1) fallback on heirloom-doctools
  then groff(1)

Modified:
  projects/doctools/usr.bin/man/man.sh

Modified: projects/doctools/usr.bin/man/man.sh
==============================================================================
--- projects/doctools/usr.bin/man/man.sh	Sat Oct  8 23:10:57 2016	(r306884)
+++ projects/doctools/usr.bin/man/man.sh	Sat Oct  8 23:18:41 2016	(r306885)
@@ -322,15 +322,23 @@ man_display_page() {
 	fi
 
 	if ! eval "$cattool $manpage | $testline" ;then
-		if which -s groff; then
+		if which -s picpack; then
+			pipeline="soelim | tbl | eqn | nroff -u1 -Tlocale -man - | col -x"
+			if [ -z "$tflags" ]; then
+				pipeline="${pipeline} | $MANPAGER"
+			fi
+		elif which -s groff; then
 			man_display_page_groff
+			return
 		else
-			echo "This manpage needs groff(1) to be rendered" >&2
-			echo "First install groff(1): " >&2
+			echo "This manpage needs heirloom-doctools or groff(1) to be rendered" >&2
+			echo "First install heirloom doctools or groff(1): " >&2
+			echo "pkg install heirloom-doctools " >&2
+			echo "or" >&2
 			echo "pkg install groff " >&2
 			ret=1
+			return
 		fi
-		return
 	fi
 
 	if [ $debug -gt 0 ]; then



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201610082318.u98NIfxu014315>