I think it's better to catch this early rather than in individual logical components. --- ChangeLog | 4 ++++ config.sub | 9 ++++----- 2 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/ChangeLog b/ChangeLog index 7295df3..099af21 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2018-05-11 John Ericson <john.ericson@obsidian.systems> + + * config.sub: Blow up on >4 component configs + 2018-05-05 Ben Elliston <b...@gnu.org> * config.sub: Simplify an if expression. diff --git a/config.sub b/config.sub index 0a518c3..8e517e7 100755 --- a/config.sub +++ b/config.sub @@ -117,6 +117,10 @@ EOF # Separate into logical components for further validation case $1 in + *-*-*-*-*) + echo Invalid configuration \`"$1"\': more than 4 components >&2 + exit 1 + ;; *-*-*-*) basic_machine=$field1-$field2 os=-$field3-$field4 @@ -385,11 +389,6 @@ case $basic_machine in i*86 | x86_64) basic_machine=$basic_machine-pc ;; - # Object if more than one company name word. - *-*-*) - echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2 - exit 1 - ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ -- 2.16.3 _______________________________________________ config-patches mailing list config-patches@gnu.org https://lists.gnu.org/mailman/listinfo/config-patches