* config.guess (*:NetBSD:*:*): uname -p' and sysctl -n

hw.machine_arch' have been the same since `uname -p' was
	introduced in 1998.  `sysctl -n hw.machine_arch' has been around a
	little longer, since 1997, so fall back to that in the obscure
	case that someone might still care about that vintage.

Signed-off-by: Ben Elliston <bje@gnu.org>
This commit is contained in:
Taylor R Campbell 2015-02-21 10:52:18 +11:00 committed by Ben Elliston
parent 1366a50997
commit b5c9e06027
2 changed files with 13 additions and 3 deletions

View File

@ -1,3 +1,11 @@
2015-02-21 Taylor R Campbell <riastradh@NetBSD.org>
* config.guess (*:NetBSD:*:*): `uname -p' and `sysctl -n
hw.machine_arch' have been the same since `uname -p' was
introduced in 1998. `sysctl -n hw.machine_arch' has been around a
little longer, since 1997, so fall back to that in the obscure
case that someone might still care about that vintage.
2015-02-20 Ben Elliston <bje@gnu.org> 2015-02-20 Ben Elliston <bje@gnu.org>
* testsuite/config-guess.sh: Read an additional column from the * testsuite/config-guess.sh: Read an additional column from the

8
config.guess vendored
View File

@ -2,7 +2,7 @@
# Attempt to guess a canonical system name. # Attempt to guess a canonical system name.
# Copyright 1992-2015 Free Software Foundation, Inc. # Copyright 1992-2015 Free Software Foundation, Inc.
timestamp='2015-01-01' timestamp='2015-02-21'
# This file is free software; you can redistribute it and/or modify it # This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by # under the terms of the GNU General Public License as published by
@ -168,8 +168,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# Note: NetBSD doesn't particularly care about the vendor # Note: NetBSD doesn't particularly care about the vendor
# portion of the name. We always set it to "unknown". # portion of the name. We always set it to "unknown".
sysctl="sysctl -n hw.machine_arch" sysctl="sysctl -n hw.machine_arch"
UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
/usr/sbin/$sysctl 2>/dev/null || echo unknown)` /sbin/$sysctl 2>/dev/null || \
/usr/sbin/$sysctl 2>/dev/null || \
echo unknown)`
case "${UNAME_MACHINE_ARCH}" in case "${UNAME_MACHINE_ARCH}" in
armeb) machine=armeb-unknown ;; armeb) machine=armeb-unknown ;;
arm*) machine=arm-unknown ;; arm*) machine=arm-unknown ;;