diff options
author | maya <maya@pkgsrc.org> | 2021-04-28 11:14:51 +0000 |
---|---|---|
committer | maya <maya@pkgsrc.org> | 2021-04-28 11:14:51 +0000 |
commit | dd5a5a1350aa0e88d74f887c80cf2674b4a1e818 (patch) | |
tree | d419ef77a74bb3dc4374941c677b67937c1be018 /bootstrap | |
parent | 714a6a665cf77c20e2f8314afad1ad4f641cd9be (diff) | |
download | pkgsrc-dd5a5a1350aa0e88d74f887c80cf2674b4a1e818.tar.gz |
Don't reject dash as /bin/sh.
From a discussion with jperkin, who tested this on bulk builds, the
remaining issues with non-BSD echo are in legacy wrappers.
Keep the workaround to use bash on Debian GNU kFreeBSD because it still
uses legacy wrappers and add a comment that that's why it's there.
Now naive usage of bootstrap on many popular Linux distros doesn't require
setting an environment variable.
Diffstat (limited to 'bootstrap')
-rwxr-xr-x | bootstrap/bootstrap | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/bootstrap/bootstrap b/bootstrap/bootstrap index a9fdc4e66c8..971177eb275 100755 --- a/bootstrap/bootstrap +++ b/bootstrap/bootstrap @@ -1,6 +1,6 @@ #! /bin/sh -# $NetBSD: bootstrap,v 1.298 2021/03/15 16:22:06 ryoon Exp $ +# $NetBSD: bootstrap,v 1.299 2021/04/28 11:14:51 maya Exp $ # # Copyright (c) 2001-2011 Alistair Crooks <agc@NetBSD.org> # All rights reserved. @@ -399,19 +399,6 @@ case "$bootstrap_sh" in ;; esac -# On some newer Ubuntu installations, /bin/sh is a symlink to /bin/dash, -# whose echo(1) is not BSD-compatible. -# On all Debian GNU/kFreeBSD 7.0, /bin/sh is a symlink to /bin/dash, and -# use /bin/bash. bootstrap forces /bin/bash is used. -dash_echo_test=`$bootstrap_sh -c 'echo "\\100"'` -if [ "$opsys" != "GNUkFreeBSD" ] && [ "$dash_echo_test" = "@" ]; then - { echo "ERROR: Your shell's echo command is not BSD-compatible." - echo "ERROR: Please select another shell by setting the environment" - echo "ERROR: variable SH." - } 1>&2 - exit 1; -fi - if [ -n "$PKG_PATH" ]; then die "ERROR: Please unset PKG_PATH before running bootstrap." fi @@ -1149,6 +1136,7 @@ esac # On all Debian GNU/kFreeBSD 7, /bin/sh is a symlink to /bin/dash, and # use /bin/bash. +# Only needed by legacy wrappers. if [ "$opsys" = "GNUkFreeBSD" -a "$bootstrap_sh_set" != "set" ]; then echo "TOOLS_PLATFORM.sh?= /bin/bash # instead of /bin/sh" >> ${TARGET_MKCONF} echo "TOOLS_PLATFORM.sh?= /bin/bash # instead of /bin/sh" >> ${BOOTSTRAP_MKCONF} |