Use ${HOST_SH} instead of the host system's /bin/sh wherever possible:

* Don't use GROFF_CSH_HACK.  It would change the "#! /bin/sh" to just
  ":", and this causes trouble for some shells.  For example, if
  CONFIG_SHELL=/bin/ksh, when the groff build uses ${CONFIG_SHELL} to
  run a script that has been modified in this way, ksh sees the ":" and
  decided to run the script under /bin/sh instead.

* Use SH_SCRIPT_SED_CMD="1s,/bin/sh,${CONFIG_SHELL},"
  to edit the "#! /bin/sh" line, to ensure that scripts
  are always run under the correct shell.
This commit is contained in:
apb 2006-09-29 20:19:40 +00:00
parent 9130d905da
commit 9a724f1a2d

View File

@ -44,9 +44,7 @@ GROFF_INSTALL_INFO
AC_PROG_INSTALL
AC_PROG_LN_S
# use a dummy substitution if no csh hack is necessary to avoid errors
# with non-GNU sed programs
GROFF_CSH_HACK([SH_SCRIPT_SED_CMD='1s/.*/:/'], [SH_SCRIPT_SED_CMD='1s/a/a/'])
SH_SCRIPT_SED_CMD="1s,/bin/sh,${CONFIG_SHELL},"
AC_SUBST([SH_SCRIPT_SED_CMD])
# checks for headers