author | zmajo |
Tue, 30 Aug 2016 09:30:16 +0200 | |
changeset 41052 | 3362c4368286 |
parent 29164 | 5307d5d020ff |
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 |
|
29161 | 32 |
# First, filter out everything that doesn't begin with "aarch64-" |
33 |
if ! echo $* | grep '^aarch64-' >/dev/null ; then |
|
34 |
. $DIR/autoconf-config.sub "$@" |
|
35 |
# autoconf-config.sub exits, so we never reach here, but just in |
|
36 |
# case we do: |
|
37 |
exit |
|
38 |
fi |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
39 |
|
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
40 |
while test $# -gt 0 ; do |
29161 | 41 |
case $1 in |
42 |
-- ) # Stop option processing |
|
43 |
shift; break ;; |
|
29164
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
44 |
aarch64-* ) |
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
45 |
config=`echo $1 | sed 's/^aarch64-/arm-/'` |
29161 | 46 |
sub_args="$sub_args $config" |
47 |
shift; ;; |
|
48 |
- ) # Use stdin as input. |
|
49 |
sub_args="$sub_args $1" |
|
50 |
shift; break ;; |
|
51 |
* ) |
|
52 |
sub_args="$sub_args $1" |
|
53 |
shift; ;; |
|
54 |
esac |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
55 |
done |
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
56 |
|
29161 | 57 |
result=`. $DIR/autoconf-config.sub $sub_args "$@"` |
58 |
exitcode=$? |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
59 |
|
29164
5307d5d020ff
8068927: AARCH64: better handling of aarch64- triples
dlong
parents:
29161
diff
changeset
|
60 |
result=`echo $result | sed "s/^arm-/aarch64-/"` |
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
61 |
|
29161 | 62 |
echo $result |
63 |
exit $exitcode |
|
12258
6ec26f6cc53e
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
64 |