Project

General

Profile

Feature #13981

in configure, detect mandoc and set MANTYPE=doc

Added by kernigh (George Koehler) about 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:83146]

Description

My OpenBSD machine uses mandoc to format manuals. Ruby's configure guesses MANTYPE=doc or MANTYPE=man after looking for nroff or awf, but doesn't know mandoc. I attach a patch to teach configure.ac about mandoc. This patch changes the guess for my machine from MANTYPE=man to MANTYPE=doc; manuals like ri(1) look better when MANTYPE=doc.

I change the code to use AC_PATH_PROGS_FEATURE_CHECK. My intent is that if we find one of [nroff awf mandoc], but it can't do -mdoc, then we check the other commands for -mdoc. The old code would only check the first found command for -mdoc.

Because I no longer use AC_PATH_PROGS, the configure script no longer sets NROFF=$ac_path_NROFF and no longer does AC_SUBST(NROFF). Therefore, we can't use @NROFF@ in Makefile.in or RbConfig.expand('$(NROFF)') in Ruby scripts. I believe that Ruby doesn't use NROFF in that way, so I don't need to set NROFF in configure.

ruby-mandoc.diff (778 Bytes) ruby-mandoc.diff detect mandoc in configure.ac kernigh (George Koehler), 10/06/2017 03:43 AM

Associated revisions

Revision 4f966c0a
Added by naruse (Yui NARUSE) about 1 year ago

configure.ac: detect mandoc and set MANTYPE=doc

OpenBSD uses mandoc [Feature #13981]
Note: AC_PATH_PROGS_FEATURE_CHECK is autoconf 2.62 feature,
but current CRuby declares AC_PREREQ(2.67); it's safe to use.
Patched by kernigh (George Koehler)

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60129 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 60129
Added by naruse (Yui NARUSE) about 1 year ago

configure.ac: detect mandoc and set MANTYPE=doc

OpenBSD uses mandoc [Feature #13981]
Note: AC_PATH_PROGS_FEATURE_CHECK is autoconf 2.62 feature,
but current CRuby declares AC_PREREQ(2.67); it's safe to use.
Patched by kernigh (George Koehler)

Revision 60129
Added by naruse (Yui NARUSE) about 1 year ago

configure.ac: detect mandoc and set MANTYPE=doc

OpenBSD uses mandoc [Feature #13981]
Note: AC_PATH_PROGS_FEATURE_CHECK is autoconf 2.62 feature,
but current CRuby declares AC_PREREQ(2.67); it's safe to use.
Patched by kernigh (George Koehler)

History

#1 Updated by naruse (Yui NARUSE) about 1 year ago

  • Status changed from Open to Closed

Applied in changeset trunk|r60129.


configure.ac: detect mandoc and set MANTYPE=doc

OpenBSD uses mandoc [Feature #13981]
Note: AC_PATH_PROGS_FEATURE_CHECK is autoconf 2.62 feature,
but current CRuby declares AC_PREREQ(2.67); it's safe to use.
Patched by kernigh (George Koehler)

Also available in: Atom PDF