author | herrick |
Thu, 28 Mar 2019 13:49:38 -0400 | |
branch | JDK-8200758-branch |
changeset 57292 | 7a683c461b80 |
parent 53110 | 50677f43ac3d |
permissions | -rw-r--r-- |
29161 | 1 |
#!/bin/sh |
15070
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
2 |
# |
29161 | 3 |
# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. |
15070
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
4 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
5 |
# |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
6 |
# This code is free software; you can redistribute it and/or modify it |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
7 |
# under the terms of the GNU General Public License version 2 only, as |
29161 | 8 |
# published by the Free Software Foundation. |
15070
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
9 |
# |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
10 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
11 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
12 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
13 |
# version 2 for more details (a copy is included in the LICENSE file that |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
14 |
# accompanied this code). |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
15 |
# |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
16 |
# You should have received a copy of the GNU General Public License version |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
17 |
# 2 along with this work; if not, write to the Free Software Foundation, |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
18 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
19 |
# |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
20 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
21 |
# or visit www.oracle.com if you need additional information or have any |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
22 |
# questions. |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
23 |
# |
f8c9af9daf6f
8005284: build-infra: nonstandard copyright headers under common/autoconf/build-aux
ohair
parents:
12258
diff
changeset
|
24 |
|
29161 | 25 |
# This is a wrapper for the config.guess from autoconf. The latter |
26 |
# does not know about all of our platforms. Instead of patching the |
|
27 |
# autoconf system (which might easily get lost in a future update), we |
|
28 |
# wrap it and fix the broken property, if needed. |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
29 |
|
29161 | 30 |
DIR=`dirname $0` |
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
31 |
|
53110 | 32 |
# Allow wsl |
33 |
if echo $* | grep x86_64-pc-wsl >/dev/null ; then |
|
34 |
echo $* |
|
35 |
exit |
|
36 |
fi |
|
37 |
||
38 |
# Filter out everything that doesn't begin with "aarch64-" |
|
29161 | 39 |
if ! echo $* | grep '^aarch64-' >/dev/null ; then |
40 |
. $DIR/autoconf-config.sub "$@" |
|
41 |
# autoconf-config.sub exits, so we never reach here, but just in |
|
42 |
# case we do: |
|
43 |
exit |
|
44 |
fi |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
45 |
|
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
46 |
while test $# -gt 0 ; do |
29161 | 47 |
case $1 in |
48 |
-- ) # Stop option processing |
|
49 |
shift; break ;; |
|
29164
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
50 |
aarch64-* ) |
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
51 |
config=`echo $1 | sed 's/^aarch64-/arm-/'` |
29161 | 52 |
sub_args="$sub_args $config" |
53 |
shift; ;; |
|
54 |
- ) # Use stdin as input. |
|
55 |
sub_args="$sub_args $1" |
|
56 |
shift; break ;; |
|
57 |
* ) |
|
58 |
sub_args="$sub_args $1" |
|
59 |
shift; ;; |
|
60 |
esac |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
61 |
done |
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
62 |
|
29161 | 63 |
result=`. $DIR/autoconf-config.sub $sub_args "$@"` |
64 |
exitcode=$? |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
65 |
|
29164
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
66 |
result=`echo $result | sed "s/^arm-/aarch64-/"` |
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
67 |
|
29161 | 68 |
echo $result |
69 |
exit $exitcode |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
70 |