@@ -674,6 +674,8 @@ PYTHON
674674FLEX
675675YFLAGS
676676YACC
677+ NROFFPROG
678+ MANDOCPROG
677679GROFFPROG
678680TRPROG
679681UNAMEPROG
@@ -17649,16 +17651,19 @@ printf "%s\n" "no" >&6; }
1764917651fi
1765017652
1765117653
17652- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mandoc or nroff" >&5
17653- printf %s "checking for mandoc or nroff... " >&6; }
17654- if test ${ac_cv_path_NROFF+y}
17654+ # Extract the first word of "mandoc", so it can be a program name with args.
17655+ set dummy mandoc; ac_word=$2
17656+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17657+ printf %s "checking for $ac_word... " >&6; }
17658+ if test ${ac_cv_path_MANDOCPROG+y}
1765517659then :
1765617660 printf %s "(cached) " >&6
1765717661else case e in #(
17658- e)
17659- if test -z "$NROFF"; then
17660- ac_path_NROFF_found=false
17661- # Loop through the user's path and test for each of PROGNAME-LIST
17662+ e) case $MANDOCPROG in
17663+ [\\/]* | ?:[\\/]*)
17664+ ac_cv_path_MANDOCPROG="$MANDOCPROG" # Let the user override the test with a path.
17665+ ;;
17666+ *)
1766217667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1766317668for as_dir in $PATH
1766417669do
@@ -17668,45 +17673,104 @@ do
1766817673 */) ;;
1766917674 *) as_dir=$as_dir/ ;;
1767017675 esac
17671- for ac_prog in mandoc nroff
17672- do
1767317676 for ac_exec_ext in '' $ac_executable_extensions; do
17674- ac_path_NROFF= "$as_dir$ac_prog $ac_exec_ext"
17675- as_fn_executable_p "$ac_path_NROFF" || continue
17676- ac_cv_path_NROFF="$ac_path_NROFF"
17677- $ac_path_NROFF_found && break 3
17678- done
17679- done
17677+ if as_fn_executable_p "$as_dir$ac_word $ac_exec_ext"; then
17678+ ac_cv_path_MANDOCPROG="$as_dir$ac_word$ac_exec_ext"
17679+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
17680+ break 2
17681+ fi
17682+ done
1768017683 done
1768117684IFS=$as_save_IFS
17682- if test -z "$ac_cv_path_NROFF"; then
17683- ac_cv_path_NROFF=no
17685+
17686+ test -z "$ac_cv_path_MANDOCPROG" && ac_cv_path_MANDOCPROG="mandoc"
17687+ ;;
17688+ esac ;;
17689+ esac
17690+ fi
17691+ MANDOCPROG=$ac_cv_path_MANDOCPROG
17692+ if test -n "$MANDOCPROG"; then
17693+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANDOCPROG" >&5
17694+ printf "%s\n" "$MANDOCPROG" >&6; }
17695+ else
17696+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17697+ printf "%s\n" "no" >&6; }
17698+ fi
17699+
17700+
17701+ if test "$ac_cv_path_MANDOCPROG" != "mandoc"
17702+ then :
17703+
17704+ ac_cv_path_NROFFPROG="$ac_cv_path_MANDOCPROG"
17705+
17706+ else case e in #(
17707+ e)
17708+ # Extract the first word of "nroff", so it can be a program name with args.
17709+ set dummy nroff; ac_word=$2
17710+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17711+ printf %s "checking for $ac_word... " >&6; }
17712+ if test ${ac_cv_path_NROFFPROG+y}
17713+ then :
17714+ printf %s "(cached) " >&6
17715+ else case e in #(
17716+ e) case $NROFFPROG in
17717+ [\\/]* | ?:[\\/]*)
17718+ ac_cv_path_NROFFPROG="$NROFFPROG" # Let the user override the test with a path.
17719+ ;;
17720+ *)
17721+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17722+ for as_dir in $PATH
17723+ do
17724+ IFS=$as_save_IFS
17725+ case $as_dir in #(((
17726+ '') as_dir=./ ;;
17727+ */) ;;
17728+ *) as_dir=$as_dir/ ;;
17729+ esac
17730+ for ac_exec_ext in '' $ac_executable_extensions; do
17731+ if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
17732+ ac_cv_path_NROFFPROG="$as_dir$ac_word$ac_exec_ext"
17733+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
17734+ break 2
1768417735 fi
17736+ done
17737+ done
17738+ IFS=$as_save_IFS
17739+
17740+ test -z "$ac_cv_path_NROFFPROG" && ac_cv_path_NROFFPROG="nroff"
17741+ ;;
17742+ esac ;;
17743+ esac
17744+ fi
17745+ NROFFPROG=$ac_cv_path_NROFFPROG
17746+ if test -n "$NROFFPROG"; then
17747+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NROFFPROG" >&5
17748+ printf "%s\n" "$NROFFPROG" >&6; }
1768517749else
17686- ac_cv_path_NROFF=$NROFF
17750+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17751+ printf "%s\n" "no" >&6; }
1768717752fi
1768817753
17754+
1768917755 ;;
1769017756esac
1769117757fi
17692- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_NROFF" >&5
17693- printf "%s\n" "$ac_cv_path_NROFF" >&6; }
17694- case "$ac_cv_path_NROFF" in
17695- *mandoc|no)
17696- # Prefer mdoc format for mandoc (or when no formatter is present).
17697- : ${MANTYPE='mdoc'}
17698- ;;
17699- *)
17700- # Check whether nroff supports -mdoc, this may produce incorrect
17701- # results when cross-compiling.
17702- test -n "$MANTYPE" && sudo_cv_var_mantype="$MANTYPE"
17703- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which macro set to use for manual pages" >&5
17758+ # Check whether nroff supports -mdoc, this may produce incorrect
17759+ # results when cross-compiling.
17760+ test -n "$MANTYPE" && sudo_cv_var_mantype="$MANTYPE"
17761+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which macro set to use for manual pages" >&5
1770417762printf %s "checking which macro set to use for manual pages... " >&6; }
1770517763if test ${sudo_cv_var_mantype+y}
1770617764then :
1770717765 printf %s "(cached) " >&6
1770817766else case e in #(
1770917767 e)
17768+ case "$ac_cv_path_NROFFPROG" in
17769+ *mandoc|nroff)
17770+ # Prefer mdoc format for mandoc (or when no formatter is present).
17771+ sudo_cv_var_mantype="mdoc"
17772+ ;;
17773+ *)
1771017774 sudo_cv_var_mantype="man"
1771117775 echo ".Sh NAME" > conftest
1771217776 echo ".Nm sudo" >> conftest
@@ -17717,15 +17781,15 @@ else case e in #(
1771717781 sudo_cv_var_mantype="mdoc"
1771817782 fi
1771917783 rm -f conftest
17784+ ;;
17785+ esac
1772017786
17721- ;;
17787+ ;;
1772217788esac
1772317789fi
1772417790{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $sudo_cv_var_mantype" >&5
1772517791printf "%s\n" "$sudo_cv_var_mantype" >&6; }
17726- MANTYPE="$sudo_cv_var_mantype"
17727- ;;
17728- esac
17792+ MANTYPE="$sudo_cv_var_mantype"
1772917793
1773017794if test -n "$sudo_cv_prev_host"
1773117795then :
@@ -36485,7 +36549,7 @@ then :
3648536549
3648636550fi
3648736551
36488- ac_config_files="$ac_config_files Makefile docs/Makefile examples/Makefile examples/sudoers examples/sudo.conf examples/sudo_logsrvd.conf examples/syslog.conf include/Makefile lib/eventlog/Makefile lib/fuzzstub/Makefile lib/iolog/Makefile lib/logsrv/Makefile lib/protobuf-c/Makefile lib/ssl_compat/Makefile lib/util/Makefile lib/util/regress/harness lib/util/util.exp logsrvd/Makefile src/intercept.exp src/sudo_usage.h src/Makefile plugins/audit_json/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/sample_approval/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/regress/harness plugins/sudoers/sudoers"
36552+ ac_config_files="$ac_config_files Makefile docs/Makefile examples/Makefile examples/sudoers examples/sudo.conf examples/sudo_logsrvd.conf examples/syslog.conf include/Makefile lib/eventlog/Makefile lib/fuzzstub/Makefile lib/iolog/Makefile lib/logsrv/Makefile lib/protobuf-c/Makefile lib/ssl_compat/Makefile lib/util/Makefile lib/util/regress/harness lib/util/util.exp logsrvd/Makefile src/intercept.exp src/sudo_usage.h src/Makefile plugins/audit_json/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/sample_approval/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/regress/harness plugins/sudoers/sudoers scripts/check_man "
3648936553
3649036554ac_config_commands="$ac_config_commands harness"
3649136555
@@ -37518,6 +37582,7 @@ do
3751837582 "plugins/sudoers/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/sudoers/Makefile" ;;
3751937583 "plugins/sudoers/regress/harness") CONFIG_FILES="$CONFIG_FILES plugins/sudoers/regress/harness" ;;
3752037584 "plugins/sudoers/sudoers") CONFIG_FILES="$CONFIG_FILES plugins/sudoers/sudoers" ;;
37585+ "scripts/check_man") CONFIG_FILES="$CONFIG_FILES scripts/check_man" ;;
3752137586 "harness") CONFIG_COMMANDS="$CONFIG_COMMANDS harness" ;;
3752237587
3752337588 *) as_fn_error $? "invalid argument: '$ac_config_target'" "$LINENO" 5;;
0 commit comments