summaryrefslogtreecommitdiff
path: root/bootstrap/bootstrap
diff options
context:
space:
mode:
authorryoon <ryoon>2013-07-26 09:38:15 +0000
committerryoon <ryoon>2013-07-26 09:38:15 +0000
commit1e98be906da5a3567566f2b296043c88a940837d (patch)
tree060af1ad99979eccdb051427a022abab32d059f3 /bootstrap/bootstrap
parenta4f2118c99756810cd15efc5c191c30e0b47b2c4 (diff)
downloadpkgsrc-1e98be906da5a3567566f2b296043c88a940837d.tar.gz
Add (Debian) GNU/kFreeBSD port.
Similar to GNU/Linux. Bump bootstrap-mk-files to 20130727.
Diffstat (limited to 'bootstrap/bootstrap')
-rwxr-xr-xbootstrap/bootstrap22
1 files changed, 20 insertions, 2 deletions
diff --git a/bootstrap/bootstrap b/bootstrap/bootstrap
index 1bbb9842d30..7ffdaa8fb1a 100755
--- a/bootstrap/bootstrap
+++ b/bootstrap/bootstrap
@@ -1,6 +1,6 @@
#! /bin/sh
-# $NetBSD: bootstrap,v 1.194 2013/06/14 15:07:37 tron Exp $
+# $NetBSD: bootstrap,v 1.195 2013/07/26 09:38:15 ryoon Exp $
#
# Copyright (c) 2001-2011 Alistair Crooks <agc@NetBSD.org>
# All rights reserved.
@@ -341,8 +341,10 @@ 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 [ "$dash_echo_test" = "@" ]; then
+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."
@@ -532,6 +534,14 @@ FreeBSD)
set_opsys=no
machine_arch=`uname -p`
;;
+GNUkFreeBSD)
+ root_group=root
+ need_bsd_install=no
+ need_awk=yes
+ need_sed=no
+ set_opsys=no
+ machine_arch=`uname -m`
+ ;;
Haiku)
root_user=`id -un`
root_group=root
@@ -950,6 +960,14 @@ fi
BOOTSTRAP_MKCONF=${wrkdir}/mk.conf
cp ${TARGET_MKCONF} ${BOOTSTRAP_MKCONF}
+# On all Debian GNU/kFreeBSD 7, /bin/sh is a symlink to /bin/dash, and
+# use /bin/bash.
+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}
+ echo $opsys
+fi
+
# sbin is used by pkg_install, share/mk by bootstrap-mk-files
mkdir_p $wrkdir/sbin $wrkdir/share/mk
mkdir_p_early ${wrkdir}