mirror of
git://git.savannah.gnu.org/config.git
synced 2025-05-26 09:06:38 +12:00
config.sub: add javascript-*-ghcjs
GHC has been using a custom triple "javascript-unknown-ghcjs" for
their (non asm.js, non wasm) javascript-emitting kernel-less target.
This triple is a bit of an oddball, so the support for it is highly
restricted in order to discourage further proliferation of the
javascript "cpu" or ghcjs "operating system", which are valid only
in combination with each other.
* config.sub (javascript-*-ghcjs): Allow.
* doc/config.sub.1: Regenerate.
* testsuite/config-sub.data (javascript-ghcjs,
javascript-unknown-ghcjs): New entries.
Link: 6636b67023
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
This commit is contained in:
parent
2a7c4b64d4
commit
6c78704d54
20
config.sub
vendored
20
config.sub
vendored
@ -4,7 +4,7 @@
|
||||
|
||||
# shellcheck disable=SC2006,SC2268 # see below for rationale
|
||||
|
||||
timestamp='2023-08-07'
|
||||
timestamp='2023-08-16'
|
||||
|
||||
# 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
|
||||
@ -1200,6 +1200,7 @@ case $cpu-$vendor in
|
||||
| d10v | d30v | dlx | dsp16xx \
|
||||
| e2k | elxsi | epiphany \
|
||||
| f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \
|
||||
| javascript \
|
||||
| h8300 | h8500 \
|
||||
| hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
|
||||
| hexagon \
|
||||
@ -1728,6 +1729,9 @@ case $os in
|
||||
# VxWorks passes extra cpu info in the 4th filed.
|
||||
simlinux | simwindows | spe)
|
||||
;;
|
||||
# See `case $cpu-$os` validation below
|
||||
ghcjs)
|
||||
;;
|
||||
# Now accept the basic system types.
|
||||
# The portable systems comes first.
|
||||
# Each alternative MUST end in a * to match a version number.
|
||||
@ -1797,6 +1801,20 @@ case $obj in
|
||||
;;
|
||||
esac
|
||||
|
||||
# Here we handle the constraint that a (synthetic) cpu and os are
|
||||
# valid only in combination with each other and nowhere else.
|
||||
case $cpu-$os in
|
||||
# The "javascript-unknown-ghcjs" triple is used by GHC; we
|
||||
# accept it here in order to tolerate that, but reject any
|
||||
# variations.
|
||||
javascript-ghcjs)
|
||||
;;
|
||||
javascript-* | *-ghcjs)
|
||||
echo "Invalid configuration '$1': cpu '$cpu' is not valid with os '$os$obj'" 1>&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# As a final step for OS-related things, validate the OS-kernel combination
|
||||
# (given a valid OS), if there is a kernel.
|
||||
case $kernel-$os-$obj in
|
||||
|
@ -1,5 +1,5 @@
|
||||
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.48.5.
|
||||
.TH CONFIG.SUB "1" "August 2023" "GNU config.sub (2023-08-07)" "User Commands"
|
||||
.TH CONFIG.SUB "1" "August 2023" "GNU config.sub (2023-08-16)" "User Commands"
|
||||
.SH NAME
|
||||
config.sub \- validate and canonicalize a configuration triplet
|
||||
.SH SYNOPSIS
|
||||
|
@ -343,6 +343,8 @@ isi68 m68k-isi-sysv
|
||||
j90 j90-cray-unicos
|
||||
j90-cray j90-cray-unicos
|
||||
j90-unicos j90-cray-unicos
|
||||
javascript-ghcjs javascript-unknown-ghcjs
|
||||
javascript-unknown-ghcjs javascript-unknown-ghcjs
|
||||
k1om k1om-unknown-none
|
||||
k1om-linux k1om-unknown-linux-gnu
|
||||
kvx-cos kvx-unknown-cos
|
||||
|
Loading…
x
Reference in New Issue
Block a user