summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgrant <grant>2005-02-19 04:07:31 +0000
committergrant <grant>2005-02-19 04:07:31 +0000
commitf1d2a36523a5a02c105a52e7d04400499dee4047 (patch)
treef38ed706120feddf7ac9603bc11f809df3f50d32
parentf59a33a423e82f3626977168b40f80efac0d6066 (diff)
downloadpkgsrc-f1d2a36523a5a02c105a52e7d04400499dee4047.tar.gz
set MACHINE_ARCH correctly on AIX.
-rwxr-xr-xbootstrap/bootstrap13
1 files changed, 12 insertions, 1 deletions
diff --git a/bootstrap/bootstrap b/bootstrap/bootstrap
index af615cdf233..fe75c1e22a2 100755
--- a/bootstrap/bootstrap
+++ b/bootstrap/bootstrap
@@ -1,6 +1,6 @@
#! /bin/sh
-# $NetBSD: bootstrap,v 1.30 2005/02/15 08:48:34 grant Exp $
+# $NetBSD: bootstrap,v 1.31 2005/02/19 04:07:31 grant Exp $
#
#
# Copyright (c) 2001-2002 Alistair G. Crooks. All rights reserved.
@@ -103,6 +103,16 @@ get_abi()
esac
}
+get_machine_arch_aix()
+{
+ _cpuid=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
+ if /usr/sbin/lsattr -El $_cpuid | grep ' POWER' >/dev/null 2>&1; then
+ echo rs6000
+ else
+ echo powerpc
+ fi
+}
+
check_prog()
{
_var="$1"; _name="$2"
@@ -306,6 +316,7 @@ AIX)
need_sed=yes
need_fixed_strip=yes
set_opsys=no
+ machine_arch=`get_machine_arch_aix`
;;
Interix)
is_root () {