[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 1/6] * config.sub: Cordon off two component aliases
From: |
John Ericson |
Subject: |
[PATCH 1/6] * config.sub: Cordon off two component aliases |
Date: |
Sat, 19 May 2018 22:15:49 -0400 |
Instead of just catching manufactures as OSes across the board, catch
them just as the second of two components. The prevent nonsense like:
$ ./config.sub amd64-unknown-ibm
x86_64-unknown-ibm-aix
---
ChangeLog | 1 +
config.sub | 45 +++++++++++++++++++++++++--------------------
2 files changed, 26 insertions(+), 20 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index f21c330..6e937e6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
2018-05-21 John Ericson <address@hidden>
* testsuite/config-sub.data: Add clipper-clix and m68k-mint tests.
+ * config.sub: Cordon off two component aliases
2018-05-19 Ben Elliston <address@hidden>
diff --git a/config.sub b/config.sub
index f38250f..c36dd49 100755
--- a/config.sub
+++ b/config.sub
@@ -2,7 +2,7 @@
# Configuration validation subroutine script.
# Copyright 1992-2018 Free Software Foundation, Inc.
-timestamp='2018-05-19'
+timestamp='2018-05-21'
# 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
@@ -149,8 +149,30 @@ case $1 in
esac
;;
*-*)
- basic_machine=$field1
- os=$field2
+ # Second component is usually, but not always the OS
+ case $field2 in
+ # Prevent following clause from handling this valid os
+ sun*os*)
+ basic_machine=$field1
+ os=$field2
+ ;;
+ # Manufacturers
+ dec* | mips* | sequent* | encore* | pc532* | sgi* |
sony* \
+ | att* | 7300* | 3300* | delta* | motorola* | sun[234]*
\
+ | unicom* | ibm* | next | hp | isi* | apollo | altos* \
+ | convergent* | ncr* | news | 32* | 3600* | 3100* |
hitachi* \
+ | c[123]* | convex* | sun | crds | omron* | dg | ultra
| tti* \
+ | harris | dolphin | highlevel | gould | cbm | ns |
masscomp \
+ | apple | axis | knuth | cray | microblaze* \
+ | sim | cisco | oki | wec | winbond)
+ basic_machine=$field1-$field2
+ os=
+ ;;
+ *)
+ basic_machine=$field1
+ os=$field2
+ ;;
+ esac
;;
*)
# Convert single-component short-hands not valid as part of
@@ -545,26 +567,9 @@ esac
### recognize some manufacturers as not being operating systems, so we
### can provide default operating systems below.
case $os in
- sun*os*)
- # Prevent following clause from handling this invalid input.
- ;;
- dec* | mips* | sequent* | encore* | pc532* | sgi* | sony* | \
- att* | 7300* | 3300* | delta* | motorola* | sun[234]* | \
- unicom* | ibm* | next | hp | isi* | apollo | altos* | \
- convergent* | ncr* | news | 32* | 3600* | 3100* | hitachi* |\
- c[123]* | convex* | sun | crds | omron* | dg | ultra | tti* | \
- harris | dolphin | highlevel | gould | cbm | ns | masscomp | \
- apple | axis | knuth | cray | microblaze*)
- os=
- basic_machine=$1
- ;;
bluegene*)
os=cnk
;;
- sim | cisco | oki | wec | winbond)
- os=
- basic_machine=$1
- ;;
scout)
;;
wrs)
--
2.16.3
- [PATCH] * config.sub: Simplify OS checking, John Ericson, 2018/05/20
- Re: [PATCH] * config.sub: Simplify OS checking, Ben Elliston, 2018/05/20
- [PATCH 1/6] * config.sub: Cordon off two component aliases,
John Ericson <=
- [PATCH 2/6] * config.sub: Simplify *-wrs hanlding, John Ericson, 2018/05/20
- [PATCH 3/6] * config.sub: No more os-driven subsitiion of -pc with sed, John Ericson, 2018/05/20
- [PATCH 4/6] * config.sub: No more forced "-sequent" in the `basic_machine` for "ipx", John Ericson, 2018/05/20
- [PATCH 5/6] * config.sub: Don't Force `basic_machine` based on `os` just for "mint" and "clix", John Ericson, 2018/05/20
- [PATCH 6/6] * config.sub: Consolidate OS version checking, John Ericson, 2018/05/20
- Re: [PATCH 6/6] * config.sub: Consolidate OS version checking, Ben Elliston, 2018/05/21
- Re: [PATCH 6/6] * config.sub: Consolidate OS version checking, Ben Elliston, 2018/05/22
- Re: [PATCH 4/6] * config.sub: No more forced "-sequent" in the `basic_machine` for "ipx", Ben Elliston, 2018/05/22
- Re: [PATCH 4/6] * config.sub: No more forced "-sequent" in the `basic_machine` for "ipx", Ben Elliston, 2018/05/22