1 From c4621d41fda90a735b670a63622aa8b7bc03a9c5 Mon Sep 17 00:00:00 2001
2 From: Rene Engelhard <rene@debian.org>
3 Date: Wed, 25 Dec 2019 17:55:29 +0100
4 Subject: [PATCH] support mdds 1.5 in rules and bump mdds build-dep to >= 1.4
5
6 ---
7 Makefile.in | 5 +-
8 aclocal.m4 | 114 +----
9 ar-lib | 4 +-
10 build/Makefile.in | 1 +
11 build/win32/Makefile.in | 1 +
12 config.guess | 893 +++++++++++++++++--------------------
13 config.sub | 359 +++++++--------
14 configure | 89 ++--
15 docs/Makefile.in | 1 +
16 docs/doxygen/Makefile.in | 1 +
17 inc/Makefile.in | 1 +
18 inc/libetonyek/Makefile.in | 1 +
19 install-sh | 397 ++++++++---------
20 ltmain.sh | 246 +++++++---
21 m4/libtool.m4 | 54 ++-
22 src/Makefile.in | 1 +
23 src/conv/Makefile.in | 1 +
24 src/conv/csv/Makefile.in | 1 +
25 src/conv/html/Makefile.in | 1 +
26 src/conv/raw/Makefile.in | 1 +
27 src/conv/svg/Makefile.in | 1 +
28 src/conv/text/Makefile.in | 1 +
29 src/fuzz/Makefile.in | 1 +
30 src/lib/Makefile.in | 1 +
31 src/test/Makefile.in | 1 +
32 test-driver | 41 +-
33 29 files changed, 1138 insertions(+), 1091 deletions(-)
34
35 diff --git a/Makefile.in b/Makefile.in
36 index 24cd1fb..03c0834 100644
37 --- a/Makefile.in
38 +++ b/Makefile.in
39 @@ -194,8 +194,8 @@ CTAGS = ctags
40 CSCOPE = cscope
41 DIST_SUBDIRS = $(SUBDIRS)
42 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \
43 - $(srcdir)/libetonyek.pc.in AUTHORS COPYING NEWS README TODO \
44 - ar-lib compile config.guess config.sub depcomp install-sh \
45 + $(srcdir)/libetonyek.pc.in AUTHORS COPYING ChangeLog NEWS \
46 + README TODO ar-lib compile config.guess config.sub install-sh \
47 ltmain.sh missing
48 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
49 distdir = $(PACKAGE)-$(VERSION)
50 @@ -395,6 +395,7 @@ pdfdir = @pdfdir@
51 prefix = @prefix@
52 program_transform_name = @program_transform_name@
53 psdir = @psdir@
54 +runstatedir = @runstatedir@
55 sbindir = @sbindir@
56 sharedstatedir = @sharedstatedir@
57 srcdir = @srcdir@
58 diff --git a/aclocal.m4 b/aclocal.m4
59 index e5191ba..be7ff61 100644
60 --- a/aclocal.m4
61 +++ b/aclocal.m4
62 @@ -20,47 +20,9 @@ You have another version of autoconf. It may work, but is not guaranteed to.
63 If you have problems, you may need to regenerate the build system entirely.
64 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
65
66 -# ===========================================================================
67 -# https://www.gnu.org/software/autoconf-archive/ax_require_defined.html
68 -# ===========================================================================
69 -#
70 -# SYNOPSIS
71 -#
72 -# AX_REQUIRE_DEFINED(MACRO)
73 -#
74 -# DESCRIPTION
75 -#
76 -# AX_REQUIRE_DEFINED is a simple helper for making sure other macros have
77 -# been defined and thus are available for use. This avoids random issues
78 -# where a macro isn't expanded. Instead the configure script emits a
79 -# non-fatal:
80 -#
81 -# ./configure: line 1673: AX_CFLAGS_WARN_ALL: command not found
82 -#
83 -# It's like AC_REQUIRE except it doesn't expand the required macro.
84 -#
85 -# Here's an example:
86 -#
87 -# AX_REQUIRE_DEFINED([AX_CHECK_LINK_FLAG])
88 -#
89 -# LICENSE
90 -#
91 -# Copyright (c) 2014 Mike Frysinger <vapier@gentoo.org>
92 -#
93 -# Copying and distribution of this file, with or without modification, are
94 -# permitted in any medium without royalty provided the copyright notice
95 -# and this notice are preserved. This file is offered as-is, without any
96 -# warranty.
97 -
98 -#serial 2
99 -
100 -AC_DEFUN([AX_REQUIRE_DEFINED], [dnl
101 - m4_ifndef([$1], [m4_fatal([macro ]$1[ is not defined; is a m4 file missing?])])
102 -])dnl AX_REQUIRE_DEFINED
103 -
104 -# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
105 -# serial 11 (pkg-config-0.29.1)
106 -
107 +dnl pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
108 +dnl serial 11 (pkg-config-0.29)
109 +dnl
110 dnl Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
111 dnl Copyright © 2012-2015 Dan Nicholson <dbn.lists@gmail.com>
112 dnl
113 @@ -101,7 +63,7 @@ dnl
114 dnl See the "Since" comment for each macro you use to see what version
115 dnl of the macros you require.
116 m4_defun([PKG_PREREQ],
117 -[m4_define([PKG_MACROS_VERSION], [0.29.1])
118 +[m4_define([PKG_MACROS_VERSION], [0.29])
119 m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1,
120 [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])])
121 ])dnl PKG_PREREQ
122 @@ -334,74 +296,6 @@ AS_VAR_COPY([$1], [pkg_cv_][$1])
123 AS_VAR_IF([$1], [""], [$5], [$4])dnl
124 ])dnl PKG_CHECK_VAR
125
126 -dnl PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES,
127 -dnl [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND],
128 -dnl [DESCRIPTION], [DEFAULT])
129 -dnl ------------------------------------------
130 -dnl
131 -dnl Prepare a "--with-" configure option using the lowercase
132 -dnl [VARIABLE-PREFIX] name, merging the behaviour of AC_ARG_WITH and
133 -dnl PKG_CHECK_MODULES in a single macro.
134 -AC_DEFUN([PKG_WITH_MODULES],
135 -[
136 -m4_pushdef([with_arg], m4_tolower([$1]))
137 -
138 -m4_pushdef([description],
139 - [m4_default([$5], [build with ]with_arg[ support])])
140 -
141 -m4_pushdef([def_arg], [m4_default([$6], [auto])])
142 -m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes])
143 -m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no])
144 -
145 -m4_case(def_arg,
146 - [yes],[m4_pushdef([with_without], [--without-]with_arg)],
147 - [m4_pushdef([with_without],[--with-]with_arg)])
148 -
149 -AC_ARG_WITH(with_arg,
150 - AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),,
151 - [AS_TR_SH([with_]with_arg)=def_arg])
152 -
153 -AS_CASE([$AS_TR_SH([with_]with_arg)],
154 - [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)],
155 - [auto],[PKG_CHECK_MODULES([$1],[$2],
156 - [m4_n([def_action_if_found]) $3],
157 - [m4_n([def_action_if_not_found]) $4])])
158 -
159 -m4_popdef([with_arg])
160 -m4_popdef([description])
161 -m4_popdef([def_arg])
162 -
163 -])dnl PKG_WITH_MODULES
164 -
165 -dnl PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
166 -dnl [DESCRIPTION], [DEFAULT])
167 -dnl -----------------------------------------------
168 -dnl
169 -dnl Convenience macro to trigger AM_CONDITIONAL after PKG_WITH_MODULES
170 -dnl check._[VARIABLE-PREFIX] is exported as make variable.
171 -AC_DEFUN([PKG_HAVE_WITH_MODULES],
172 -[
173 -PKG_WITH_MODULES([$1],[$2],,,[$3],[$4])
174 -
175 -AM_CONDITIONAL([HAVE_][$1],
176 - [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"])
177 -])dnl PKG_HAVE_WITH_MODULES
178 -
179 -dnl PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
180 -dnl [DESCRIPTION], [DEFAULT])
181 -dnl ------------------------------------------------------
182 -dnl
183 -dnl Convenience macro to run AM_CONDITIONAL and AC_DEFINE after
184 -dnl PKG_WITH_MODULES check. HAVE_[VARIABLE-PREFIX] is exported as make
185 -dnl and preprocessor variable.
186 -AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES],
187 -[
188 -PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4])
189 -
190 -AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"],
191 - [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])])
192 -])dnl PKG_HAVE_DEFINE_WITH_MODULES
193 -
194 # Copyright (C) 2002-2018 Free Software Foundation, Inc.
195 #
196 # This file is free software; the Free Software Foundation
197 diff --git a/ar-lib b/ar-lib
198 index fe2301e..0baa4f6 100755
199 --- a/ar-lib
200 +++ b/ar-lib
201 @@ -4,7 +4,7 @@
202 me=ar-lib
203 scriptversion=2012-03-01.08; # UTC
204
205 -# Copyright (C) 2010-2013 Free Software Foundation, Inc.
206 +# Copyright (C) 2010-2018 Free Software Foundation, Inc.
207 # Written by Peter Rosin <peda@lysator.liu.se>.
208 #
209 # This program is free software; you can redistribute it and/or modify
210 @@ -18,7 +18,7 @@ scriptversion=2012-03-01.08; # UTC
211 # GNU General Public License for more details.
212 #
213 # You should have received a copy of the GNU General Public License
214 -# along with this program. If not, see <http://www.gnu.org/licenses/>.
215 +# along with this program. If not, see <https://www.gnu.org/licenses/>.
216
217 # As a special exception to the GNU General Public License, if you
218 # distribute this file as part of a program that contains a
219 diff --git a/build/Makefile.in b/build/Makefile.in
220 index 1789b05..de51487 100644
221 --- a/build/Makefile.in
222 +++ b/build/Makefile.in
223 @@ -341,6 +341,7 @@ pdfdir = @pdfdir@
224 prefix = @prefix@
225 program_transform_name = @program_transform_name@
226 psdir = @psdir@
227 +runstatedir = @runstatedir@
228 sbindir = @sbindir@
229 sharedstatedir = @sharedstatedir@
230 srcdir = @srcdir@
231 diff --git a/build/win32/Makefile.in b/build/win32/Makefile.in
232 index 59aa3a0..d7190da 100644
233 --- a/build/win32/Makefile.in
234 +++ b/build/win32/Makefile.in
235 @@ -281,6 +281,7 @@ pdfdir = @pdfdir@
236 prefix = @prefix@
237 program_transform_name = @program_transform_name@
238 psdir = @psdir@
239 +runstatedir = @runstatedir@
240 sbindir = @sbindir@
241 sharedstatedir = @sharedstatedir@
242 srcdir = @srcdir@
243 diff --git a/config.guess b/config.guess
244 index 1804e9f..f50dcdb 100755
245 --- a/config.guess
246 +++ b/config.guess
247 @@ -1,10 +1,8 @@
248 #! /bin/sh
249 # Attempt to guess a canonical system name.
250 -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
251 -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
252 -# 2011, 2012, 2013 Free Software Foundation, Inc.
253 +# Copyright 1992-2018 Free Software Foundation, Inc.
254
255 -timestamp='2012-12-29'
256 +timestamp='2018-02-24'
257
258 # This file is free software; you can redistribute it and/or modify it
259 # under the terms of the GNU General Public License as published by
260 @@ -17,7 +15,7 @@ timestamp='2012-12-29'
261 # General Public License for more details.
262 #
263 # You should have received a copy of the GNU General Public License
264 -# along with this program; if not, see <http://www.gnu.org/licenses/>.
265 +# along with this program; if not, see <https://www.gnu.org/licenses/>.
266 #
267 # As a special exception to the GNU General Public License, if you
268 # distribute this file as part of a program that contains a
269 @@ -26,12 +24,12 @@ timestamp='2012-12-29'
270 # program. This Exception is an additional permission under section 7
271 # of the GNU General Public License, version 3 ("GPLv3").
272 #
273 -# Originally written by Per Bothner.
274 +# Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
275 #
276 # You can get the latest version of this script from:
277 -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
278 +# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
279 #
280 -# Please send patches with a ChangeLog entry to config-patches@gnu.org.
281 +# Please send patches to <config-patches@gnu.org>.
282
283
284 me=`echo "$0" | sed -e 's,.*/,,'`
285 @@ -41,7 +39,7 @@ Usage: $0 [OPTION]
286
287 Output the configuration name of the system \`$me' is run on.
288
289 -Operation modes:
290 +Options:
291 -h, --help print this help, then exit
292 -t, --time-stamp print date of last modification, then exit
293 -v, --version print version number, then exit
294 @@ -52,9 +50,7 @@ version="\
295 GNU config.guess ($timestamp)
296
297 Originally written by Per Bothner.
298 -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
299 -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011,
300 -2012, 2013 Free Software Foundation, Inc.
301 +Copyright 1992-2018 Free Software Foundation, Inc.
302
303 This is free software; see the source for copying conditions. There is NO
304 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
305 @@ -111,9 +107,9 @@ trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
306 dummy=$tmp/dummy ;
307 tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
308 case $CC_FOR_BUILD,$HOST_CC,$CC in
309 - ,,) echo "int x;" > $dummy.c ;
310 + ,,) echo "int x;" > "$dummy.c" ;
311 for c in cc gcc c89 c99 ; do
312 - if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
313 + if ($c -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then
314 CC_FOR_BUILD="$c"; break ;
315 fi ;
316 done ;
317 @@ -136,9 +132,37 @@ UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
318 UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
319 UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
320
321 +case "$UNAME_SYSTEM" in
322 +Linux|GNU|GNU/*)
323 + # If the system lacks a compiler, then just pick glibc.
324 + # We could probably try harder.
325 + LIBC=gnu
326 +
327 + eval "$set_cc_for_build"
328 + cat <<-EOF > "$dummy.c"
329 + #include <features.h>
330 + #if defined(__UCLIBC__)
331 + LIBC=uclibc
332 + #elif defined(__dietlibc__)
333 + LIBC=dietlibc
334 + #else
335 + LIBC=gnu
336 + #endif
337 + EOF
338 + eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`"
339 +
340 + # If ldd exists, use it to detect musl libc.
341 + if command -v ldd >/dev/null && \
342 + ldd --version 2>&1 | grep -q ^musl
343 + then
344 + LIBC=musl
345 + fi
346 + ;;
347 +esac
348 +
349 # Note: order is significant - the case branches are not exclusive.
350
351 -case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
352 +case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
353 *:NetBSD:*:*)
354 # NetBSD (nbsd) targets should (where applicable) match one or
355 # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
356 @@ -151,21 +175,31 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
357 # Note: NetBSD doesn't particularly care about the vendor
358 # portion of the name. We always set it to "unknown".
359 sysctl="sysctl -n hw.machine_arch"
360 - UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
361 - /usr/sbin/$sysctl 2>/dev/null || echo unknown)`
362 - case "${UNAME_MACHINE_ARCH}" in
363 + UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
364 + "/sbin/$sysctl" 2>/dev/null || \
365 + "/usr/sbin/$sysctl" 2>/dev/null || \
366 + echo unknown)`
367 + case "$UNAME_MACHINE_ARCH" in
368 armeb) machine=armeb-unknown ;;
369 arm*) machine=arm-unknown ;;
370 sh3el) machine=shl-unknown ;;
371 sh3eb) machine=sh-unknown ;;
372 sh5el) machine=sh5le-unknown ;;
373 - *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
374 + earmv*)
375 + arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
376 + endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'`
377 + machine="${arch}${endian}"-unknown
378 + ;;
379 + *) machine="$UNAME_MACHINE_ARCH"-unknown ;;
380 esac
381 # The Operating System including object format, if it has switched
382 - # to ELF recently, or will in the future.
383 - case "${UNAME_MACHINE_ARCH}" in
384 + # to ELF recently (or will in the future) and ABI.
385 + case "$UNAME_MACHINE_ARCH" in
386 + earm*)
387 + os=netbsdelf
388 + ;;
389 arm*|i386|m68k|ns32k|sh3*|sparc|vax)
390 - eval $set_cc_for_build
391 + eval "$set_cc_for_build"
392 if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
393 | grep -q __ELF__
394 then
395 @@ -180,44 +214,67 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
396 os=netbsd
397 ;;
398 esac
399 + # Determine ABI tags.
400 + case "$UNAME_MACHINE_ARCH" in
401 + earm*)
402 + expr='s/^earmv[0-9]/-eabi/;s/eb$//'
403 + abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"`
404 + ;;
405 + esac
406 # The OS release
407 # Debian GNU/NetBSD machines have a different userland, and
408 # thus, need a distinct triplet. However, they do not need
409 # kernel version information, so it can be replaced with a
410 # suitable tag, in the style of linux-gnu.
411 - case "${UNAME_VERSION}" in
412 + case "$UNAME_VERSION" in
413 Debian*)
414 release='-gnu'
415 ;;
416 *)
417 - release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
418 + release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2`
419 ;;
420 esac
421 # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
422 # contains redundant information, the shorter form:
423 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
424 - echo "${machine}-${os}${release}"
425 + echo "$machine-${os}${release}${abi}"
426 exit ;;
427 *:Bitrig:*:*)
428 UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
429 - echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE}
430 + echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE"
431 exit ;;
432 *:OpenBSD:*:*)
433 UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
434 - echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
435 + echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE"
436 + exit ;;
437 + *:LibertyBSD:*:*)
438 + UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
439 + echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE"
440 + exit ;;
441 + *:MidnightBSD:*:*)
442 + echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE"
443 exit ;;
444 *:ekkoBSD:*:*)
445 - echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
446 + echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE"
447 exit ;;
448 *:SolidBSD:*:*)
449 - echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
450 + echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE"
451 exit ;;
452 macppc:MirBSD:*:*)
453 - echo powerpc-unknown-mirbsd${UNAME_RELEASE}
454 + echo powerpc-unknown-mirbsd"$UNAME_RELEASE"
455 exit ;;
456 *:MirBSD:*:*)
457 - echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
458 + echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE"
459 + exit ;;
460 + *:Sortix:*:*)
461 + echo "$UNAME_MACHINE"-unknown-sortix
462 exit ;;
463 + *:Redox:*:*)
464 + echo "$UNAME_MACHINE"-unknown-redox
465 + exit ;;
466 + mips:OSF1:*.*)
467 + echo mips-dec-osf1
468 + exit ;;
469 alpha:OSF1:*:*)
470 case $UNAME_RELEASE in
471 *4.0)
472 @@ -234,63 +291,54 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
473 ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
474 case "$ALPHA_CPU_TYPE" in
475 "EV4 (21064)")
476 - UNAME_MACHINE="alpha" ;;
477 + UNAME_MACHINE=alpha ;;
478 "EV4.5 (21064)")
479 - UNAME_MACHINE="alpha" ;;
480 + UNAME_MACHINE=alpha ;;
481 "LCA4 (21066/21068)")
482 - UNAME_MACHINE="alpha" ;;
483 + UNAME_MACHINE=alpha ;;
484 "EV5 (21164)")
485 - UNAME_MACHINE="alphaev5" ;;
486 + UNAME_MACHINE=alphaev5 ;;
487 "EV5.6 (21164A)")
488 - UNAME_MACHINE="alphaev56" ;;
489 + UNAME_MACHINE=alphaev56 ;;
490 "EV5.6 (21164PC)")
491 - UNAME_MACHINE="alphapca56" ;;
492 + UNAME_MACHINE=alphapca56 ;;
493 "EV5.7 (21164PC)")
494 - UNAME_MACHINE="alphapca57" ;;
495 + UNAME_MACHINE=alphapca57 ;;
496 "EV6 (21264)")
497 - UNAME_MACHINE="alphaev6" ;;
498 + UNAME_MACHINE=alphaev6 ;;
499 "EV6.7 (21264A)")
500 - UNAME_MACHINE="alphaev67" ;;
501 + UNAME_MACHINE=alphaev67 ;;
502 "EV6.8CB (21264C)")
503 - UNAME_MACHINE="alphaev68" ;;
504 + UNAME_MACHINE=alphaev68 ;;
505 "EV6.8AL (21264B)")
506 - UNAME_MACHINE="alphaev68" ;;
507 + UNAME_MACHINE=alphaev68 ;;
508 "EV6.8CX (21264D)")
509 - UNAME_MACHINE="alphaev68" ;;
510 + UNAME_MACHINE=alphaev68 ;;
511 "EV6.9A (21264/EV69A)")
512 - UNAME_MACHINE="alphaev69" ;;
513 + UNAME_MACHINE=alphaev69 ;;
514 "EV7 (21364)")
515 - UNAME_MACHINE="alphaev7" ;;
516 + UNAME_MACHINE=alphaev7 ;;
517 "EV7.9 (21364A)")
518 - UNAME_MACHINE="alphaev79" ;;
519 + UNAME_MACHINE=alphaev79 ;;
520 esac
521 # A Pn.n version is a patched version.
522 # A Vn.n version is a released version.
523 # A Tn.n version is a released field test version.
524 # A Xn.n version is an unreleased experimental baselevel.
525 # 1.2 uses "1.2" for uname -r.
526 - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
527 + echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`"
528 # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
529 exitcode=$?
530 trap '' 0
531 exit $exitcode ;;
532 - Alpha\ *:Windows_NT*:*)
533 - # How do we know it's Interix rather than the generic POSIX subsystem?
534 - # Should we change UNAME_MACHINE based on the output of uname instead
535 - # of the specific Alpha model?
536 - echo alpha-pc-interix
537 - exit ;;
538 - 21064:Windows_NT:50:3)
539 - echo alpha-dec-winnt3.5
540 - exit ;;
541 Amiga*:UNIX_System_V:4.0:*)
542 echo m68k-unknown-sysv4
543 exit ;;
544 *:[Aa]miga[Oo][Ss]:*:*)
545 - echo ${UNAME_MACHINE}-unknown-amigaos
546 + echo "$UNAME_MACHINE"-unknown-amigaos
547 exit ;;
548 *:[Mm]orph[Oo][Ss]:*:*)
549 - echo ${UNAME_MACHINE}-unknown-morphos
550 + echo "$UNAME_MACHINE"-unknown-morphos
551 exit ;;
552 *:OS/390:*:*)
553 echo i370-ibm-openedition
554 @@ -302,7 +350,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
555 echo powerpc-ibm-os400
556 exit ;;
557 arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
558 - echo arm-acorn-riscix${UNAME_RELEASE}
559 + echo arm-acorn-riscix"$UNAME_RELEASE"
560 exit ;;
561 arm*:riscos:*:*|arm*:RISCOS:*:*)
562 echo arm-unknown-riscos
563 @@ -329,38 +377,38 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
564 sparc) echo sparc-icl-nx7; exit ;;
565 esac ;;
566 s390x:SunOS:*:*)
567 - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
568 + echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
569 exit ;;
570 sun4H:SunOS:5.*:*)
571 - echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
572 + echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
573 exit ;;
574 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
575 - echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
576 + echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
577 exit ;;
578 i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
579 - echo i386-pc-auroraux${UNAME_RELEASE}
580 + echo i386-pc-auroraux"$UNAME_RELEASE"
581 exit ;;
582 i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
583 - eval $set_cc_for_build
584 - SUN_ARCH="i386"
585 + eval "$set_cc_for_build"
586 + SUN_ARCH=i386
587 # If there is a compiler, see if it is configured for 64-bit objects.
588 # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
589 # This test works for both compilers.
590 - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
591 + if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
592 if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
593 - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
594 + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
595 grep IS_64BIT_ARCH >/dev/null
596 then
597 - SUN_ARCH="x86_64"
598 + SUN_ARCH=x86_64
599 fi
600 fi
601 - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
602 + echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
603 exit ;;
604 sun4*:SunOS:6*:*)
605 # According to config.sub, this is the proper way to canonicalize
606 # SunOS6. Hard to guess exactly what SunOS6 will be like, but
607 # it's likely to be more like Solaris than SunOS4.
608 - echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
609 + echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
610 exit ;;
611 sun4*:SunOS:*:*)
612 case "`/usr/bin/arch -k`" in
613 @@ -369,25 +417,25 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
614 ;;
615 esac
616 # Japanese Language versions have a version number like `4.1.3-JL'.
617 - echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
618 + echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`"
619 exit ;;
620 sun3*:SunOS:*:*)
621 - echo m68k-sun-sunos${UNAME_RELEASE}
622 + echo m68k-sun-sunos"$UNAME_RELEASE"
623 exit ;;
624 sun*:*:4.2BSD:*)
625 UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
626 - test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
627 + test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3
628 case "`/bin/arch`" in
629 sun3)
630 - echo m68k-sun-sunos${UNAME_RELEASE}
631 + echo m68k-sun-sunos"$UNAME_RELEASE"
632 ;;
633 sun4)
634 - echo sparc-sun-sunos${UNAME_RELEASE}
635 + echo sparc-sun-sunos"$UNAME_RELEASE"
636 ;;
637 esac
638 exit ;;
639 aushp:SunOS:*:*)
640 - echo sparc-auspex-sunos${UNAME_RELEASE}
641 + echo sparc-auspex-sunos"$UNAME_RELEASE"
642 exit ;;
643 # The situation for MiNT is a little confusing. The machine name
644 # can be virtually everything (everything which is not
645 @@ -398,44 +446,44 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
646 # MiNT. But MiNT is downward compatible to TOS, so this should
647 # be no problem.
648 atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
649 - echo m68k-atari-mint${UNAME_RELEASE}
650 + echo m68k-atari-mint"$UNAME_RELEASE"
651 exit ;;
652 atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
653 - echo m68k-atari-mint${UNAME_RELEASE}
654 + echo m68k-atari-mint"$UNAME_RELEASE"
655 exit ;;
656 *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
657 - echo m68k-atari-mint${UNAME_RELEASE}
658 + echo m68k-atari-mint"$UNAME_RELEASE"
659 exit ;;
660 milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
661 - echo m68k-milan-mint${UNAME_RELEASE}
662 + echo m68k-milan-mint"$UNAME_RELEASE"
663 exit ;;
664 hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
665 - echo m68k-hades-mint${UNAME_RELEASE}
666 + echo m68k-hades-mint"$UNAME_RELEASE"
667 exit ;;
668 *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
669 - echo m68k-unknown-mint${UNAME_RELEASE}
670 + echo m68k-unknown-mint"$UNAME_RELEASE"
671 exit ;;
672 m68k:machten:*:*)
673 - echo m68k-apple-machten${UNAME_RELEASE}
674 + echo m68k-apple-machten"$UNAME_RELEASE"
675 exit ;;
676 powerpc:machten:*:*)
677 - echo powerpc-apple-machten${UNAME_RELEASE}
678 + echo powerpc-apple-machten"$UNAME_RELEASE"
679 exit ;;
680 RISC*:Mach:*:*)
681 echo mips-dec-mach_bsd4.3
682 exit ;;
683 RISC*:ULTRIX:*:*)
684 - echo mips-dec-ultrix${UNAME_RELEASE}
685 + echo mips-dec-ultrix"$UNAME_RELEASE"
686 exit ;;
687 VAX*:ULTRIX*:*:*)
688 - echo vax-dec-ultrix${UNAME_RELEASE}
689 + echo vax-dec-ultrix"$UNAME_RELEASE"
690 exit ;;
691 2020:CLIX:*:* | 2430:CLIX:*:*)
692 - echo clipper-intergraph-clix${UNAME_RELEASE}
693 + echo clipper-intergraph-clix"$UNAME_RELEASE"
694 exit ;;
695 mips:*:*:UMIPS | mips:*:*:RISCos)
696 - eval $set_cc_for_build
697 - sed 's/^ //' << EOF >$dummy.c
698 + eval "$set_cc_for_build"
699 + sed 's/^ //' << EOF > "$dummy.c"
700 #ifdef __cplusplus
701 #include <stdio.h> /* for printf() prototype */
702 int main (int argc, char *argv[]) {
703 @@ -444,23 +492,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
704 #endif
705 #if defined (host_mips) && defined (MIPSEB)
706 #if defined (SYSTYPE_SYSV)
707 - printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
708 + printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0);
709 #endif
710 #if defined (SYSTYPE_SVR4)
711 - printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
712 + printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0);
713 #endif
714 #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
715 - printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
716 + printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0);
717 #endif
718 #endif
719 exit (-1);
720 }
721 EOF
722 - $CC_FOR_BUILD -o $dummy $dummy.c &&
723 - dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
724 - SYSTEM_NAME=`$dummy $dummyarg` &&
725 + $CC_FOR_BUILD -o "$dummy" "$dummy.c" &&
726 + dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` &&
727 + SYSTEM_NAME=`"$dummy" "$dummyarg"` &&
728 { echo "$SYSTEM_NAME"; exit; }
729 - echo mips-mips-riscos${UNAME_RELEASE}
730 + echo mips-mips-riscos"$UNAME_RELEASE"
731 exit ;;
732 Motorola:PowerMAX_OS:*:*)
733 echo powerpc-motorola-powermax
734 @@ -486,17 +534,17 @@ EOF
735 AViiON:dgux:*:*)
736 # DG/UX returns AViiON for all architectures
737 UNAME_PROCESSOR=`/usr/bin/uname -p`
738 - if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
739 + if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ]
740 then
741 - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
742 - [ ${TARGET_BINARY_INTERFACE}x = x ]
743 + if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \
744 + [ "$TARGET_BINARY_INTERFACE"x = x ]
745 then
746 - echo m88k-dg-dgux${UNAME_RELEASE}
747 + echo m88k-dg-dgux"$UNAME_RELEASE"
748 else
749 - echo m88k-dg-dguxbcs${UNAME_RELEASE}
750 + echo m88k-dg-dguxbcs"$UNAME_RELEASE"
751 fi
752 else
753 - echo i586-dg-dgux${UNAME_RELEASE}
754 + echo i586-dg-dgux"$UNAME_RELEASE"
755 fi
756 exit ;;
757 M88*:DolphinOS:*:*) # DolphinOS (SVR3)
758 @@ -513,7 +561,7 @@ EOF
759 echo m68k-tektronix-bsd
760 exit ;;
761 *:IRIX*:*:*)
762 - echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
763 + echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`"
764 exit ;;
765 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
766 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
767 @@ -525,14 +573,14 @@ EOF
768 if [ -x /usr/bin/oslevel ] ; then
769 IBM_REV=`/usr/bin/oslevel`
770 else
771 - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
772 + IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
773 fi
774 - echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
775 + echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV"
776 exit ;;
777 *:AIX:2:3)
778 if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
779 - eval $set_cc_for_build
780 - sed 's/^ //' << EOF >$dummy.c
781 + eval "$set_cc_for_build"
782 + sed 's/^ //' << EOF > "$dummy.c"
783 #include <sys/systemcfg.h>
784
785 main()
786 @@ -543,7 +591,7 @@ EOF
787 exit(0);
788 }
789 EOF
790 - if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
791 + if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"`
792 then
793 echo "$SYSTEM_NAME"
794 else
795 @@ -557,26 +605,27 @@ EOF
796 exit ;;
797 *:AIX:*:[4567])
798 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
799 - if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
800 + if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then
801 IBM_ARCH=rs6000
802 else
803 IBM_ARCH=powerpc
804 fi
805 - if [ -x /usr/bin/oslevel ] ; then
806 - IBM_REV=`/usr/bin/oslevel`
807 + if [ -x /usr/bin/lslpp ] ; then
808 + IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
809 + awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
810 else
811 - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
812 + IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
813 fi
814 - echo ${IBM_ARCH}-ibm-aix${IBM_REV}
815 + echo "$IBM_ARCH"-ibm-aix"$IBM_REV"
816 exit ;;
817 *:AIX:*:*)
818 echo rs6000-ibm-aix
819 exit ;;
820 - ibmrt:4.4BSD:*|romp-ibm:BSD:*)
821 + ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*)
822 echo romp-ibm-bsd4.4
823 exit ;;
824 ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
825 - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
826 + echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to
827 exit ;; # report: romp-ibm BSD 4.3
828 *:BOSX:*:*)
829 echo rs6000-bull-bosx
830 @@ -591,28 +640,28 @@ EOF
831 echo m68k-hp-bsd4.4
832 exit ;;
833 9000/[34678]??:HP-UX:*:*)
834 - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
835 - case "${UNAME_MACHINE}" in
836 - 9000/31? ) HP_ARCH=m68000 ;;
837 - 9000/[34]?? ) HP_ARCH=m68k ;;
838 + HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
839 + case "$UNAME_MACHINE" in
840 + 9000/31?) HP_ARCH=m68000 ;;
841 + 9000/[34]??) HP_ARCH=m68k ;;
842 9000/[678][0-9][0-9])
843 if [ -x /usr/bin/getconf ]; then
844 sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
845 sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
846 - case "${sc_cpu_version}" in
847 - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
848 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
849 + case "$sc_cpu_version" in
850 + 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
851 + 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
852 532) # CPU_PA_RISC2_0
853 - case "${sc_kernel_bits}" in
854 - 32) HP_ARCH="hppa2.0n" ;;
855 - 64) HP_ARCH="hppa2.0w" ;;
856 - '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
857 + case "$sc_kernel_bits" in
858 + 32) HP_ARCH=hppa2.0n ;;
859 + 64) HP_ARCH=hppa2.0w ;;
860 + '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20
861 esac ;;
862 esac
863 fi
864 - if [ "${HP_ARCH}" = "" ]; then
865 - eval $set_cc_for_build
866 - sed 's/^ //' << EOF >$dummy.c
867 + if [ "$HP_ARCH" = "" ]; then
868 + eval "$set_cc_for_build"
869 + sed 's/^ //' << EOF > "$dummy.c"
870
871 #define _HPUX_SOURCE
872 #include <stdlib.h>
873 @@ -645,13 +694,13 @@ EOF
874 exit (0);
875 }
876 EOF
877 - (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
878 + (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"`
879 test -z "$HP_ARCH" && HP_ARCH=hppa
880 fi ;;
881 esac
882 - if [ ${HP_ARCH} = "hppa2.0w" ]
883 + if [ "$HP_ARCH" = hppa2.0w ]
884 then
885 - eval $set_cc_for_build
886 + eval "$set_cc_for_build"
887
888 # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
889 # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
890 @@ -662,23 +711,23 @@ EOF
891 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
892 # => hppa64-hp-hpux11.23
893
894 - if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
895 + if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) |
896 grep -q __LP64__
897 then
898 - HP_ARCH="hppa2.0w"
899 + HP_ARCH=hppa2.0w
900 else
901 - HP_ARCH="hppa64"
902 + HP_ARCH=hppa64
903 fi
904 fi
905 - echo ${HP_ARCH}-hp-hpux${HPUX_REV}
906 + echo "$HP_ARCH"-hp-hpux"$HPUX_REV"
907 exit ;;
908 ia64:HP-UX:*:*)
909 - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
910 - echo ia64-hp-hpux${HPUX_REV}
911 + HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
912 + echo ia64-hp-hpux"$HPUX_REV"
913 exit ;;
914 3050*:HI-UX:*:*)
915 - eval $set_cc_for_build
916 - sed 's/^ //' << EOF >$dummy.c
917 + eval "$set_cc_for_build"
918 + sed 's/^ //' << EOF > "$dummy.c"
919 #include <unistd.h>
920 int
921 main ()
922 @@ -703,11 +752,11 @@ EOF
923 exit (0);
924 }
925 EOF
926 - $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
927 + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` &&
928 { echo "$SYSTEM_NAME"; exit; }
929 echo unknown-hitachi-hiuxwe2
930 exit ;;
931 - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
932 + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*)
933 echo hppa1.1-hp-bsd
934 exit ;;
935 9000/8??:4.3bsd:*:*)
936 @@ -716,7 +765,7 @@ EOF
937 *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
938 echo hppa1.0-hp-mpeix
939 exit ;;
940 - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
941 + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*)
942 echo hppa1.1-hp-osf
943 exit ;;
944 hp8??:OSF1:*:*)
945 @@ -724,9 +773,9 @@ EOF
946 exit ;;
947 i*86:OSF1:*:*)
948 if [ -x /usr/sbin/sysversion ] ; then
949 - echo ${UNAME_MACHINE}-unknown-osf1mk
950 + echo "$UNAME_MACHINE"-unknown-osf1mk
951 else
952 - echo ${UNAME_MACHINE}-unknown-osf1
953 + echo "$UNAME_MACHINE"-unknown-osf1
954 fi
955 exit ;;
956 parisc*:Lites*:*:*)
957 @@ -751,127 +800,109 @@ EOF
958 echo c4-convex-bsd
959 exit ;;
960 CRAY*Y-MP:*:*:*)
961 - echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
962 + echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
963 exit ;;
964 CRAY*[A-Z]90:*:*:*)
965 - echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
966 + echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \
967 | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
968 -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
969 -e 's/\.[^.]*$/.X/'
970 exit ;;
971 CRAY*TS:*:*:*)
972 - echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
973 + echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
974 exit ;;
975 CRAY*T3E:*:*:*)
976 - echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
977 + echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
978 exit ;;
979 CRAY*SV1:*:*:*)
980 - echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
981 + echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
982 exit ;;
983 *:UNICOS/mp:*:*)
984 - echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
985 + echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
986 exit ;;
987 F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
988 - FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
989 - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
990 - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
991 + FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
992 + FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
993 + FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'`
994 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
995 exit ;;
996 5000:UNIX_System_V:4.*:*)
997 - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
998 - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
999 + FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
1000 + FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
1001 echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
1002 exit ;;
1003 i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
1004 - echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
1005 + echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE"
1006 exit ;;
1007 sparc*:BSD/OS:*:*)
1008 - echo sparc-unknown-bsdi${UNAME_RELEASE}
1009 + echo sparc-unknown-bsdi"$UNAME_RELEASE"
1010 exit ;;
1011 *:BSD/OS:*:*)
1012 - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
1013 + echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
1014 exit ;;
1015 *:FreeBSD:*:*)
1016 UNAME_PROCESSOR=`/usr/bin/uname -p`
1017 - case ${UNAME_PROCESSOR} in
1018 + case "$UNAME_PROCESSOR" in
1019 amd64)
1020 - echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
1021 - *)
1022 - echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
1023 + UNAME_PROCESSOR=x86_64 ;;
1024 + i386)
1025 + UNAME_PROCESSOR=i586 ;;
1026 esac
1027 + echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
1028 exit ;;
1029 i*:CYGWIN*:*)
1030 - echo ${UNAME_MACHINE}-pc-cygwin
1031 + echo "$UNAME_MACHINE"-pc-cygwin
1032 exit ;;
1033 *:MINGW64*:*)
1034 - echo ${UNAME_MACHINE}-pc-mingw64
1035 + echo "$UNAME_MACHINE"-pc-mingw64
1036 exit ;;
1037 *:MINGW*:*)
1038 - echo ${UNAME_MACHINE}-pc-mingw32
1039 + echo "$UNAME_MACHINE"-pc-mingw32
1040 exit ;;
1041 - i*:MSYS*:*)
1042 - echo ${UNAME_MACHINE}-pc-msys
1043 - exit ;;
1044 - i*:windows32*:*)
1045 - # uname -m includes "-pc" on this system.
1046 - echo ${UNAME_MACHINE}-mingw32
1047 + *:MSYS*:*)
1048 + echo "$UNAME_MACHINE"-pc-msys
1049 exit ;;
1050 i*:PW*:*)
1051 - echo ${UNAME_MACHINE}-pc-pw32
1052 + echo "$UNAME_MACHINE"-pc-pw32
1053 exit ;;
1054 *:Interix*:*)
1055 - case ${UNAME_MACHINE} in
1056 + case "$UNAME_MACHINE" in
1057 x86)
1058 - echo i586-pc-interix${UNAME_RELEASE}
1059 + echo i586-pc-interix"$UNAME_RELEASE"
1060 exit ;;
1061 authenticamd | genuineintel | EM64T)
1062 - echo x86_64-unknown-interix${UNAME_RELEASE}
1063 + echo x86_64-unknown-interix"$UNAME_RELEASE"
1064 exit ;;
1065 IA64)
1066 - echo ia64-unknown-interix${UNAME_RELEASE}
1067 + echo ia64-unknown-interix"$UNAME_RELEASE"
1068 exit ;;
1069 esac ;;
1070 - [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
1071 - echo i${UNAME_MACHINE}-pc-mks
1072 - exit ;;
1073 - 8664:Windows_NT:*)
1074 - echo x86_64-pc-mks
1075 - exit ;;
1076 - i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
1077 - # How do we know it's Interix rather than the generic POSIX subsystem?
1078 - # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
1079 - # UNAME_MACHINE based on the output of uname instead of i386?
1080 - echo i586-pc-interix
1081 - exit ;;
1082 i*:UWIN*:*)
1083 - echo ${UNAME_MACHINE}-pc-uwin
1084 + echo "$UNAME_MACHINE"-pc-uwin
1085 exit ;;
1086 amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
1087 echo x86_64-unknown-cygwin
1088 exit ;;
1089 - p*:CYGWIN*:*)
1090 - echo powerpcle-unknown-cygwin
1091 - exit ;;
1092 prep*:SunOS:5.*:*)
1093 - echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
1094 + echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
1095 exit ;;
1096 *:GNU:*:*)
1097 # the GNU system
1098 - echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
1099 + echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`"
1100 exit ;;
1101 *:GNU/*:*:*)
1102 # other systems with GNU libc and userland
1103 - echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
1104 + echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
1105 exit ;;
1106 i*86:Minix:*:*)
1107 - echo ${UNAME_MACHINE}-pc-minix
1108 + echo "$UNAME_MACHINE"-pc-minix
1109 exit ;;
1110 aarch64:Linux:*:*)
1111 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1112 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1113 exit ;;
1114 aarch64_be:Linux:*:*)
1115 UNAME_MACHINE=aarch64_be
1116 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1117 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1118 exit ;;
1119 alpha:Linux:*:*)
1120 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
1121 @@ -884,63 +915,64 @@ EOF
1122 EV68*) UNAME_MACHINE=alphaev68 ;;
1123 esac
1124 objdump --private-headers /bin/sh | grep -q ld.so.1
1125 - if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
1126 - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
1127 + if test "$?" = 0 ; then LIBC=gnulibc1 ; fi
1128 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1129 + exit ;;
1130 + arc:Linux:*:* | arceb:Linux:*:*)
1131 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1132 exit ;;
1133 arm*:Linux:*:*)
1134 - eval $set_cc_for_build
1135 + eval "$set_cc_for_build"
1136 if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
1137 | grep -q __ARM_EABI__
1138 then
1139 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1140 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1141 else
1142 if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
1143 | grep -q __ARM_PCS_VFP
1144 then
1145 - echo ${UNAME_MACHINE}-unknown-linux-gnueabi
1146 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi
1147 else
1148 - echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
1149 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf
1150 fi
1151 fi
1152 exit ;;
1153 avr32*:Linux:*:*)
1154 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1155 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1156 exit ;;
1157 cris:Linux:*:*)
1158 - echo ${UNAME_MACHINE}-axis-linux-gnu
1159 + echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
1160 exit ;;
1161 crisv32:Linux:*:*)
1162 - echo ${UNAME_MACHINE}-axis-linux-gnu
1163 + echo "$UNAME_MACHINE"-axis-linux-"$LIBC"
1164 + exit ;;
1165 + e2k:Linux:*:*)
1166 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1167 exit ;;
1168 frv:Linux:*:*)
1169 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1170 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1171 exit ;;
1172 hexagon:Linux:*:*)
1173 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1174 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1175 exit ;;
1176 i*86:Linux:*:*)
1177 - LIBC=gnu
1178 - eval $set_cc_for_build
1179 - sed 's/^ //' << EOF >$dummy.c
1180 - #ifdef __dietlibc__
1181 - LIBC=dietlibc
1182 - #endif
1183 -EOF
1184 - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
1185 - echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
1186 + echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
1187 exit ;;
1188 ia64:Linux:*:*)
1189 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1190 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1191 + exit ;;
1192 + k1om:Linux:*:*)
1193 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1194 exit ;;
1195 m32r*:Linux:*:*)
1196 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1197 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1198 exit ;;
1199 m68*:Linux:*:*)
1200 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1201 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1202 exit ;;
1203 mips:Linux:*:* | mips64:Linux:*:*)
1204 - eval $set_cc_for_build
1205 - sed 's/^ //' << EOF >$dummy.c
1206 + eval "$set_cc_for_build"
1207 + sed 's/^ //' << EOF > "$dummy.c"
1208 #undef CPU
1209 #undef ${UNAME_MACHINE}
1210 #undef ${UNAME_MACHINE}el
1211 @@ -954,55 +986,74 @@ EOF
1212 #endif
1213 #endif
1214 EOF
1215 - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
1216 - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
1217 + eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`"
1218 + test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; }
1219 ;;
1220 - or32:Linux:*:*)
1221 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1222 + mips64el:Linux:*:*)
1223 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1224 + exit ;;
1225 + openrisc*:Linux:*:*)
1226 + echo or1k-unknown-linux-"$LIBC"
1227 + exit ;;
1228 + or32:Linux:*:* | or1k*:Linux:*:*)
1229 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1230 exit ;;
1231 padre:Linux:*:*)
1232 - echo sparc-unknown-linux-gnu
1233 + echo sparc-unknown-linux-"$LIBC"
1234 exit ;;
1235 parisc64:Linux:*:* | hppa64:Linux:*:*)
1236 - echo hppa64-unknown-linux-gnu
1237 + echo hppa64-unknown-linux-"$LIBC"
1238 exit ;;
1239 parisc:Linux:*:* | hppa:Linux:*:*)
1240 # Look for CPU level
1241 case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
1242 - PA7*) echo hppa1.1-unknown-linux-gnu ;;
1243 - PA8*) echo hppa2.0-unknown-linux-gnu ;;
1244 - *) echo hppa-unknown-linux-gnu ;;
1245 + PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;;
1246 + PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;;
1247 + *) echo hppa-unknown-linux-"$LIBC" ;;
1248 esac
1249 exit ;;
1250 ppc64:Linux:*:*)
1251 - echo powerpc64-unknown-linux-gnu
1252 + echo powerpc64-unknown-linux-"$LIBC"
1253 exit ;;
1254 ppc:Linux:*:*)
1255 - echo powerpc-unknown-linux-gnu
1256 + echo powerpc-unknown-linux-"$LIBC"
1257 + exit ;;
1258 + ppc64le:Linux:*:*)
1259 + echo powerpc64le-unknown-linux-"$LIBC"
1260 + exit ;;
1261 + ppcle:Linux:*:*)
1262 + echo powerpcle-unknown-linux-"$LIBC"
1263 + exit ;;
1264 + riscv32:Linux:*:* | riscv64:Linux:*:*)
1265 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1266 exit ;;
1267 s390:Linux:*:* | s390x:Linux:*:*)
1268 - echo ${UNAME_MACHINE}-ibm-linux
1269 + echo "$UNAME_MACHINE"-ibm-linux-"$LIBC"
1270 exit ;;
1271 sh64*:Linux:*:*)
1272 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1273 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1274 exit ;;
1275 sh*:Linux:*:*)
1276 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1277 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1278 exit ;;
1279 sparc:Linux:*:* | sparc64:Linux:*:*)
1280 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1281 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1282 exit ;;
1283 tile*:Linux:*:*)
1284 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1285 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1286 exit ;;
1287 vax:Linux:*:*)
1288 - echo ${UNAME_MACHINE}-dec-linux-gnu
1289 + echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
1290 exit ;;
1291 x86_64:Linux:*:*)
1292 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1293 + if objdump -f /bin/sh | grep -q elf32-x86-64; then
1294 + echo "$UNAME_MACHINE"-pc-linux-"$LIBC"x32
1295 + else
1296 + echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
1297 + fi
1298 exit ;;
1299 xtensa*:Linux:*:*)
1300 - echo ${UNAME_MACHINE}-unknown-linux-gnu
1301 + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
1302 exit ;;
1303 i*86:DYNIX/ptx:4*:*)
1304 # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
1305 @@ -1016,34 +1067,34 @@ EOF
1306 # I am not positive that other SVR4 systems won't match this,
1307 # I just have to hope. -- rms.
1308 # Use sysv4.2uw... so that sysv4* matches it.
1309 - echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
1310 + echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION"
1311 exit ;;
1312 i*86:OS/2:*:*)
1313 # If we were able to find `uname', then EMX Unix compatibility
1314 # is probably installed.
1315 - echo ${UNAME_MACHINE}-pc-os2-emx
1316 + echo "$UNAME_MACHINE"-pc-os2-emx
1317 exit ;;
1318 i*86:XTS-300:*:STOP)
1319 - echo ${UNAME_MACHINE}-unknown-stop
1320 + echo "$UNAME_MACHINE"-unknown-stop
1321 exit ;;
1322 i*86:atheos:*:*)
1323 - echo ${UNAME_MACHINE}-unknown-atheos
1324 + echo "$UNAME_MACHINE"-unknown-atheos
1325 exit ;;
1326 i*86:syllable:*:*)
1327 - echo ${UNAME_MACHINE}-pc-syllable
1328 + echo "$UNAME_MACHINE"-pc-syllable
1329 exit ;;
1330 i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
1331 - echo i386-unknown-lynxos${UNAME_RELEASE}
1332 + echo i386-unknown-lynxos"$UNAME_RELEASE"
1333 exit ;;
1334 i*86:*DOS:*:*)
1335 - echo ${UNAME_MACHINE}-pc-msdosdjgpp
1336 + echo "$UNAME_MACHINE"-pc-msdosdjgpp
1337 exit ;;
1338 - i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
1339 - UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
1340 + i*86:*:4.*:*)
1341 + UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'`
1342 if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
1343 - echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
1344 + echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL"
1345 else
1346 - echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
1347 + echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL"
1348 fi
1349 exit ;;
1350 i*86:*:5:[678]*)
1351 @@ -1053,12 +1104,12 @@ EOF
1352 *Pentium) UNAME_MACHINE=i586 ;;
1353 *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
1354 esac
1355 - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
1356 + echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}"
1357 exit ;;
1358 i*86:*:3.2:*)
1359 if test -f /usr/options/cb.name; then
1360 UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
1361 - echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
1362 + echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL"
1363 elif /bin/uname -X 2>/dev/null >/dev/null ; then
1364 UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
1365 (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
1366 @@ -1068,9 +1119,9 @@ EOF
1367 && UNAME_MACHINE=i686
1368 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
1369 && UNAME_MACHINE=i686
1370 - echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
1371 + echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL"
1372 else
1373 - echo ${UNAME_MACHINE}-pc-sysv32
1374 + echo "$UNAME_MACHINE"-pc-sysv32
1375 fi
1376 exit ;;
1377 pc:*:*:*)
1378 @@ -1078,7 +1129,7 @@ EOF
1379 # uname -m prints for DJGPP always 'pc', but it prints nothing about
1380 # the processor, so we play safe by assuming i586.
1381 # Note: whatever this is, it MUST be the same as what config.sub
1382 - # prints for the "djgpp" host, or else GDB configury will decide that
1383 + # prints for the "djgpp" host, or else GDB configure will decide that
1384 # this is a cross-build.
1385 echo i586-pc-msdosdjgpp
1386 exit ;;
1387 @@ -1090,9 +1141,9 @@ EOF
1388 exit ;;
1389 i860:*:4.*:*) # i860-SVR4
1390 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
1391 - echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
1392 + echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4
1393 else # Add other i860-SVR4 vendors below as they are discovered.
1394 - echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
1395 + echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4
1396 fi
1397 exit ;;
1398 mini*:CTIX:SYS*5:*)
1399 @@ -1112,9 +1163,9 @@ EOF
1400 test -r /etc/.relid \
1401 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1402 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1403 - && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
1404 + && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
1405 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1406 - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
1407 + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;;
1408 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
1409 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1410 && { echo i486-ncr-sysv4; exit; } ;;
1411 @@ -1123,28 +1174,28 @@ EOF
1412 test -r /etc/.relid \
1413 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1414 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1415 - && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
1416 + && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
1417 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1418 - && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
1419 + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; }
1420 /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
1421 - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
1422 + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;;
1423 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
1424 - echo m68k-unknown-lynxos${UNAME_RELEASE}
1425 + echo m68k-unknown-lynxos"$UNAME_RELEASE"
1426 exit ;;
1427 mc68030:UNIX_System_V:4.*:*)
1428 echo m68k-atari-sysv4
1429 exit ;;
1430 TSUNAMI:LynxOS:2.*:*)
1431 - echo sparc-unknown-lynxos${UNAME_RELEASE}
1432 + echo sparc-unknown-lynxos"$UNAME_RELEASE"
1433 exit ;;
1434 rs6000:LynxOS:2.*:*)
1435 - echo rs6000-unknown-lynxos${UNAME_RELEASE}
1436 + echo rs6000-unknown-lynxos"$UNAME_RELEASE"
1437 exit ;;
1438 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
1439 - echo powerpc-unknown-lynxos${UNAME_RELEASE}
1440 + echo powerpc-unknown-lynxos"$UNAME_RELEASE"
1441 exit ;;
1442 SM[BE]S:UNIX_SV:*:*)
1443 - echo mips-dde-sysv${UNAME_RELEASE}
1444 + echo mips-dde-sysv"$UNAME_RELEASE"
1445 exit ;;
1446 RM*:ReliantUNIX-*:*:*)
1447 echo mips-sni-sysv4
1448 @@ -1155,7 +1206,7 @@ EOF
1449 *:SINIX-*:*:*)
1450 if uname -p 2>/dev/null >/dev/null ; then
1451 UNAME_MACHINE=`(uname -p) 2>/dev/null`
1452 - echo ${UNAME_MACHINE}-sni-sysv4
1453 + echo "$UNAME_MACHINE"-sni-sysv4
1454 else
1455 echo ns32k-sni-sysv
1456 fi
1457 @@ -1175,23 +1226,23 @@ EOF
1458 exit ;;
1459 i*86:VOS:*:*)
1460 # From Paul.Green@stratus.com.
1461 - echo ${UNAME_MACHINE}-stratus-vos
1462 + echo "$UNAME_MACHINE"-stratus-vos
1463 exit ;;
1464 *:VOS:*:*)
1465 # From Paul.Green@stratus.com.
1466 echo hppa1.1-stratus-vos
1467 exit ;;
1468 mc68*:A/UX:*:*)
1469 - echo m68k-apple-aux${UNAME_RELEASE}
1470 + echo m68k-apple-aux"$UNAME_RELEASE"
1471 exit ;;
1472 news*:NEWS-OS:6*:*)
1473 echo mips-sony-newsos6
1474 exit ;;
1475 R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
1476 if [ -d /usr/nec ]; then
1477 - echo mips-nec-sysv${UNAME_RELEASE}
1478 + echo mips-nec-sysv"$UNAME_RELEASE"
1479 else
1480 - echo mips-unknown-sysv${UNAME_RELEASE}
1481 + echo mips-unknown-sysv"$UNAME_RELEASE"
1482 fi
1483 exit ;;
1484 BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
1485 @@ -1210,65 +1261,93 @@ EOF
1486 echo x86_64-unknown-haiku
1487 exit ;;
1488 SX-4:SUPER-UX:*:*)
1489 - echo sx4-nec-superux${UNAME_RELEASE}
1490 + echo sx4-nec-superux"$UNAME_RELEASE"
1491 exit ;;
1492 SX-5:SUPER-UX:*:*)
1493 - echo sx5-nec-superux${UNAME_RELEASE}
1494 + echo sx5-nec-superux"$UNAME_RELEASE"
1495 exit ;;
1496 SX-6:SUPER-UX:*:*)
1497 - echo sx6-nec-superux${UNAME_RELEASE}
1498 + echo sx6-nec-superux"$UNAME_RELEASE"
1499 exit ;;
1500 SX-7:SUPER-UX:*:*)
1501 - echo sx7-nec-superux${UNAME_RELEASE}
1502 + echo sx7-nec-superux"$UNAME_RELEASE"
1503 exit ;;
1504 SX-8:SUPER-UX:*:*)
1505 - echo sx8-nec-superux${UNAME_RELEASE}
1506 + echo sx8-nec-superux"$UNAME_RELEASE"
1507 exit ;;
1508 SX-8R:SUPER-UX:*:*)
1509 - echo sx8r-nec-superux${UNAME_RELEASE}
1510 + echo sx8r-nec-superux"$UNAME_RELEASE"
1511 + exit ;;
1512 + SX-ACE:SUPER-UX:*:*)
1513 + echo sxace-nec-superux"$UNAME_RELEASE"
1514 exit ;;
1515 Power*:Rhapsody:*:*)
1516 - echo powerpc-apple-rhapsody${UNAME_RELEASE}
1517 + echo powerpc-apple-rhapsody"$UNAME_RELEASE"
1518 exit ;;
1519 *:Rhapsody:*:*)
1520 - echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
1521 + echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
1522 exit ;;
1523 *:Darwin:*:*)
1524 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
1525 - case $UNAME_PROCESSOR in
1526 - i386)
1527 - eval $set_cc_for_build
1528 - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
1529 - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
1530 - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
1531 - grep IS_64BIT_ARCH >/dev/null
1532 - then
1533 - UNAME_PROCESSOR="x86_64"
1534 - fi
1535 - fi ;;
1536 - unknown) UNAME_PROCESSOR=powerpc ;;
1537 - esac
1538 - echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
1539 + eval "$set_cc_for_build"
1540 + if test "$UNAME_PROCESSOR" = unknown ; then
1541 + UNAME_PROCESSOR=powerpc
1542 + fi
1543 + if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then
1544 + if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
1545 + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
1546 + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
1547 + grep IS_64BIT_ARCH >/dev/null
1548 + then
1549 + case $UNAME_PROCESSOR in
1550 + i386) UNAME_PROCESSOR=x86_64 ;;
1551 + powerpc) UNAME_PROCESSOR=powerpc64 ;;
1552 + esac
1553 + fi
1554 + # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
1555 + if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
1556 + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
1557 + grep IS_PPC >/dev/null
1558 + then
1559 + UNAME_PROCESSOR=powerpc
1560 + fi
1561 + fi
1562 + elif test "$UNAME_PROCESSOR" = i386 ; then
1563 + # Avoid executing cc on OS X 10.9, as it ships with a stub
1564 + # that puts up a graphical alert prompting to install
1565 + # developer tools. Any system running Mac OS X 10.7 or
1566 + # later (Darwin 11 and later) is required to have a 64-bit
1567 + # processor. This is not true of the ARM version of Darwin
1568 + # that Apple uses in portable devices.
1569 + UNAME_PROCESSOR=x86_64
1570 + fi
1571 + echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
1572 exit ;;
1573 *:procnto*:*:* | *:QNX:[0123456789]*:*)
1574 UNAME_PROCESSOR=`uname -p`
1575 - if test "$UNAME_PROCESSOR" = "x86"; then
1576 + if test "$UNAME_PROCESSOR" = x86; then
1577 UNAME_PROCESSOR=i386
1578 UNAME_MACHINE=pc
1579 fi
1580 - echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
1581 + echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE"
1582 exit ;;
1583 *:QNX:*:4*)
1584 echo i386-pc-qnx
1585 exit ;;
1586 - NEO-?:NONSTOP_KERNEL:*:*)
1587 - echo neo-tandem-nsk${UNAME_RELEASE}
1588 + NEO-*:NONSTOP_KERNEL:*:*)
1589 + echo neo-tandem-nsk"$UNAME_RELEASE"
1590 exit ;;
1591 NSE-*:NONSTOP_KERNEL:*:*)
1592 - echo nse-tandem-nsk${UNAME_RELEASE}
1593 + echo nse-tandem-nsk"$UNAME_RELEASE"
1594 exit ;;
1595 - NSR-?:NONSTOP_KERNEL:*:*)
1596 - echo nsr-tandem-nsk${UNAME_RELEASE}
1597 + NSR-*:NONSTOP_KERNEL:*:*)
1598 + echo nsr-tandem-nsk"$UNAME_RELEASE"
1599 + exit ;;
1600 + NSV-*:NONSTOP_KERNEL:*:*)
1601 + echo nsv-tandem-nsk"$UNAME_RELEASE"
1602 + exit ;;
1603 + NSX-*:NONSTOP_KERNEL:*:*)
1604 + echo nsx-tandem-nsk"$UNAME_RELEASE"
1605 exit ;;
1606 *:NonStop-UX:*:*)
1607 echo mips-compaq-nonstopux
1608 @@ -1277,18 +1356,18 @@ EOF
1609 echo bs2000-siemens-sysv
1610 exit ;;
1611 DS/*:UNIX_System_V:*:*)
1612 - echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
1613 + echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE"
1614 exit ;;
1615 *:Plan9:*:*)
1616 # "uname -m" is not consistent, so use $cputype instead. 386
1617 # is converted to i386 for consistency with other x86
1618 # operating systems.
1619 - if test "$cputype" = "386"; then
1620 + if test "$cputype" = 386; then
1621 UNAME_MACHINE=i386
1622 else
1623 UNAME_MACHINE="$cputype"
1624 fi
1625 - echo ${UNAME_MACHINE}-unknown-plan9
1626 + echo "$UNAME_MACHINE"-unknown-plan9
1627 exit ;;
1628 *:TOPS-10:*:*)
1629 echo pdp10-unknown-tops10
1630 @@ -1309,14 +1388,14 @@ EOF
1631 echo pdp10-unknown-its
1632 exit ;;
1633 SEI:*:*:SEIUX)
1634 - echo mips-sei-seiux${UNAME_RELEASE}
1635 + echo mips-sei-seiux"$UNAME_RELEASE"
1636 exit ;;
1637 *:DragonFly:*:*)
1638 - echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
1639 + echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
1640 exit ;;
1641 *:*VMS:*:*)
1642 UNAME_MACHINE=`(uname -p) 2>/dev/null`
1643 - case "${UNAME_MACHINE}" in
1644 + case "$UNAME_MACHINE" in
1645 A*) echo alpha-dec-vms ; exit ;;
1646 I*) echo ia64-dec-vms ; exit ;;
1647 V*) echo vax-dec-vms ; exit ;;
1648 @@ -1325,182 +1404,48 @@ EOF
1649 echo i386-pc-xenix
1650 exit ;;
1651 i*86:skyos:*:*)
1652 - echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
1653 + echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`"
1654 exit ;;
1655 i*86:rdos:*:*)
1656 - echo ${UNAME_MACHINE}-pc-rdos
1657 + echo "$UNAME_MACHINE"-pc-rdos
1658 exit ;;
1659 i*86:AROS:*:*)
1660 - echo ${UNAME_MACHINE}-pc-aros
1661 + echo "$UNAME_MACHINE"-pc-aros
1662 exit ;;
1663 x86_64:VMkernel:*:*)
1664 - echo ${UNAME_MACHINE}-unknown-esx
1665 + echo "$UNAME_MACHINE"-unknown-esx
1666 + exit ;;
1667 + amd64:Isilon\ OneFS:*:*)
1668 + echo x86_64-unknown-onefs
1669 exit ;;
1670 esac
1671
1672 -eval $set_cc_for_build
1673 -cat >$dummy.c <<EOF
1674 -#ifdef _SEQUENT_
1675 -# include <sys/types.h>
1676 -# include <sys/utsname.h>
1677 -#endif
1678 -main ()
1679 -{
1680 -#if defined (sony)
1681 -#if defined (MIPSEB)
1682 - /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
1683 - I don't know.... */
1684 - printf ("mips-sony-bsd\n"); exit (0);
1685 -#else
1686 -#include <sys/param.h>
1687 - printf ("m68k-sony-newsos%s\n",
1688 -#ifdef NEWSOS4
1689 - "4"
1690 -#else
1691 - ""
1692 -#endif
1693 - ); exit (0);
1694 -#endif
1695 -#endif
1696 -
1697 -#if defined (__arm) && defined (__acorn) && defined (__unix)
1698 - printf ("arm-acorn-riscix\n"); exit (0);
1699 -#endif
1700 -
1701 -#if defined (hp300) && !defined (hpux)
1702 - printf ("m68k-hp-bsd\n"); exit (0);
1703 -#endif
1704 -
1705 -#if defined (NeXT)
1706 -#if !defined (__ARCHITECTURE__)
1707 -#define __ARCHITECTURE__ "m68k"
1708 -#endif
1709 - int version;
1710 - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
1711 - if (version < 4)
1712 - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
1713 - else
1714 - printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
1715 - exit (0);
1716 -#endif
1717 -
1718 -#if defined (MULTIMAX) || defined (n16)
1719 -#if defined (UMAXV)
1720 - printf ("ns32k-encore-sysv\n"); exit (0);
1721 -#else
1722 -#if defined (CMU)
1723 - printf ("ns32k-encore-mach\n"); exit (0);
1724 -#else
1725 - printf ("ns32k-encore-bsd\n"); exit (0);
1726 -#endif
1727 -#endif
1728 -#endif
1729 -
1730 -#if defined (__386BSD__)
1731 - printf ("i386-pc-bsd\n"); exit (0);
1732 -#endif
1733 -
1734 -#if defined (sequent)
1735 -#if defined (i386)
1736 - printf ("i386-sequent-dynix\n"); exit (0);
1737 -#endif
1738 -#if defined (ns32000)
1739 - printf ("ns32k-sequent-dynix\n"); exit (0);
1740 -#endif
1741 -#endif
1742 -
1743 -#if defined (_SEQUENT_)
1744 - struct utsname un;
1745 +echo "$0: unable to guess system type" >&2
1746
1747 - uname(&un);
1748 +case "$UNAME_MACHINE:$UNAME_SYSTEM" in
1749 + mips:Linux | mips64:Linux)
1750 + # If we got here on MIPS GNU/Linux, output extra information.
1751 + cat >&2 <<EOF
1752
1753 - if (strncmp(un.version, "V2", 2) == 0) {
1754 - printf ("i386-sequent-ptx2\n"); exit (0);
1755 - }
1756 - if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
1757 - printf ("i386-sequent-ptx1\n"); exit (0);
1758 - }
1759 - printf ("i386-sequent-ptx\n"); exit (0);
1760 -
1761 -#endif
1762 -
1763 -#if defined (vax)
1764 -# if !defined (ultrix)
1765 -# include <sys/param.h>
1766 -# if defined (BSD)
1767 -# if BSD == 43
1768 - printf ("vax-dec-bsd4.3\n"); exit (0);
1769 -# else
1770 -# if BSD == 199006
1771 - printf ("vax-dec-bsd4.3reno\n"); exit (0);
1772 -# else
1773 - printf ("vax-dec-bsd\n"); exit (0);
1774 -# endif
1775 -# endif
1776 -# else
1777 - printf ("vax-dec-bsd\n"); exit (0);
1778 -# endif
1779 -# else
1780 - printf ("vax-dec-ultrix\n"); exit (0);
1781 -# endif
1782 -#endif
1783 -
1784 -#if defined (alliant) && defined (i860)
1785 - printf ("i860-alliant-bsd\n"); exit (0);
1786 -#endif
1787 -
1788 - exit (1);
1789 -}
1790 +NOTE: MIPS GNU/Linux systems require a C compiler to fully recognize
1791 +the system type. Please install a C compiler and try again.
1792 EOF
1793 -
1794 -$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
1795 - { echo "$SYSTEM_NAME"; exit; }
1796 -
1797 -# Apollos put the system type in the environment.
1798 -
1799 -test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
1800 -
1801 -# Convex versions that predate uname can use getsysinfo(1)
1802 -
1803 -if [ -x /usr/convex/getsysinfo ]
1804 -then
1805 - case `getsysinfo -f cpu_type` in
1806 - c1*)
1807 - echo c1-convex-bsd
1808 - exit ;;
1809 - c2*)
1810 - if getsysinfo -f scalar_acc
1811 - then echo c32-convex-bsd
1812 - else echo c2-convex-bsd
1813 - fi
1814 - exit ;;
1815 - c34*)
1816 - echo c34-convex-bsd
1817 - exit ;;
1818 - c38*)
1819 - echo c38-convex-bsd
1820 - exit ;;
1821 - c4*)
1822 - echo c4-convex-bsd
1823 - exit ;;
1824 - esac
1825 -fi
1826 + ;;
1827 +esac
1828
1829 cat >&2 <<EOF
1830 -$0: unable to guess system type
1831
1832 -This script, last modified $timestamp, has failed to recognize
1833 -the operating system you are using. It is advised that you
1834 -download the most up to date version of the config scripts from
1835 +This script (version $timestamp), has failed to recognize the
1836 +operating system you are using. If your script is old, overwrite *all*
1837 +copies of config.guess and config.sub with the latest versions from:
1838
1839 - http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
1840 + https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
1841 and
1842 - http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
1843 + https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
1844
1845 -If the version you run ($0) is already up to date, please
1846 -send the following data and any information you think might be
1847 -pertinent to <config-patches@gnu.org> in order to provide the needed
1848 -information to handle your system.
1849 +If $0 has already been updated, send the following data and any
1850 +information you think might be pertinent to config-patches@gnu.org to
1851 +provide the necessary information to handle your system.
1852
1853 config.guess timestamp = $timestamp
1854
1855 @@ -1519,16 +1464,16 @@ hostinfo = `(hostinfo) 2>/dev/null`
1856 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
1857 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
1858
1859 -UNAME_MACHINE = ${UNAME_MACHINE}
1860 -UNAME_RELEASE = ${UNAME_RELEASE}
1861 -UNAME_SYSTEM = ${UNAME_SYSTEM}
1862 -UNAME_VERSION = ${UNAME_VERSION}
1863 +UNAME_MACHINE = "$UNAME_MACHINE"
1864 +UNAME_RELEASE = "$UNAME_RELEASE"
1865 +UNAME_SYSTEM = "$UNAME_SYSTEM"
1866 +UNAME_VERSION = "$UNAME_VERSION"
1867 EOF
1868
1869 exit 1
1870
1871 # Local variables:
1872 -# eval: (add-hook 'write-file-hooks 'time-stamp)
1873 +# eval: (add-hook 'write-file-functions 'time-stamp)
1874 # time-stamp-start: "timestamp='"
1875 # time-stamp-format: "%:y-%02m-%02d"
1876 # time-stamp-end: "'"
1877 diff --git a/config.sub b/config.sub
1878 index 52f04bc..1d8e98b 100755
1879 --- a/config.sub
1880 +++ b/config.sub
1881 @@ -1,10 +1,8 @@
1882 #! /bin/sh
1883 # Configuration validation subroutine script.
1884 -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
1885 -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
1886 -# 2011, 2012, 2013 Free Software Foundation, Inc.
1887 +# Copyright 1992-2018 Free Software Foundation, Inc.
1888
1889 -timestamp='2012-12-29'
1890 +timestamp='2018-02-22'
1891
1892 # This file is free software; you can redistribute it and/or modify it
1893 # under the terms of the GNU General Public License as published by
1894 @@ -17,7 +15,7 @@ timestamp='2012-12-29'
1895 # General Public License for more details.
1896 #
1897 # You should have received a copy of the GNU General Public License
1898 -# along with this program; if not, see <http://www.gnu.org/licenses/>.
1899 +# along with this program; if not, see <https://www.gnu.org/licenses/>.
1900 #
1901 # As a special exception to the GNU General Public License, if you
1902 # distribute this file as part of a program that contains a
1903 @@ -27,7 +25,7 @@ timestamp='2012-12-29'
1904 # of the GNU General Public License, version 3 ("GPLv3").
1905
1906
1907 -# Please send patches with a ChangeLog entry to config-patches@gnu.org.
1908 +# Please send patches to <config-patches@gnu.org>.
1909 #
1910 # Configuration subroutine to validate and canonicalize a configuration type.
1911 # Supply the specified configuration type as an argument.
1912 @@ -35,7 +33,7 @@ timestamp='2012-12-29'
1913 # Otherwise, we print the canonical config type on stdout and succeed.
1914
1915 # You can get the latest version of this script from:
1916 -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
1917 +# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
1918
1919 # This file is supposed to be the same for all GNU packages
1920 # and recognize all the CPU types, system types and aliases
1921 @@ -55,12 +53,11 @@ timestamp='2012-12-29'
1922 me=`echo "$0" | sed -e 's,.*/,,'`
1923
1924 usage="\
1925 -Usage: $0 [OPTION] CPU-MFR-OPSYS
1926 - $0 [OPTION] ALIAS
1927 +Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS
1928
1929 Canonicalize a configuration name.
1930
1931 -Operation modes:
1932 +Options:
1933 -h, --help print this help, then exit
1934 -t, --time-stamp print date of last modification, then exit
1935 -v, --version print version number, then exit
1936 @@ -70,9 +67,7 @@ Report bugs and patches to <config-patches@gnu.org>."
1937 version="\
1938 GNU config.sub ($timestamp)
1939
1940 -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
1941 -2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011,
1942 -2012, 2013 Free Software Foundation, Inc.
1943 +Copyright 1992-2018 Free Software Foundation, Inc.
1944
1945 This is free software; see the source for copying conditions. There is NO
1946 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
1947 @@ -99,7 +94,7 @@ while test $# -gt 0 ; do
1948
1949 *local*)
1950 # First pass through any local machine types.
1951 - echo $1
1952 + echo "$1"
1953 exit ;;
1954
1955 * )
1956 @@ -117,24 +112,24 @@ esac
1957
1958 # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
1959 # Here we must recognize all the valid KERNEL-OS combinations.
1960 -maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
1961 +maybe_os=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
1962 case $maybe_os in
1963 nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
1964 linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
1965 - knetbsd*-gnu* | netbsd*-gnu* | \
1966 - kopensolaris*-gnu* | \
1967 + knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \
1968 + kopensolaris*-gnu* | cloudabi*-eabi* | \
1969 storm-chaos* | os2-emx* | rtmk-nova*)
1970 os=-$maybe_os
1971 - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
1972 + basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
1973 ;;
1974 android-linux)
1975 os=-linux-android
1976 - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown
1977 + basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown
1978 ;;
1979 *)
1980 - basic_machine=`echo $1 | sed 's/-[^-]*$//'`
1981 - if [ $basic_machine != $1 ]
1982 - then os=`echo $1 | sed 's/.*-/-/'`
1983 + basic_machine=`echo "$1" | sed 's/-[^-]*$//'`
1984 + if [ "$basic_machine" != "$1" ]
1985 + then os=`echo "$1" | sed 's/.*-/-/'`
1986 else os=; fi
1987 ;;
1988 esac
1989 @@ -183,44 +178,44 @@ case $os in
1990 ;;
1991 -sco6)
1992 os=-sco5v6
1993 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1994 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
1995 ;;
1996 -sco5)
1997 os=-sco3.2v5
1998 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
1999 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2000 ;;
2001 -sco4)
2002 os=-sco3.2v4
2003 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2004 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2005 ;;
2006 -sco3.2.[4-9]*)
2007 os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
2008 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2009 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2010 ;;
2011 -sco3.2v[4-9]*)
2012 # Don't forget version if it is 3.2v4 or newer.
2013 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2014 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2015 ;;
2016 -sco5v6*)
2017 # Don't forget version if it is 3.2v4 or newer.
2018 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2019 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2020 ;;
2021 -sco*)
2022 os=-sco3.2v2
2023 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2024 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2025 ;;
2026 -udk*)
2027 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2028 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2029 ;;
2030 -isc)
2031 os=-isc2.2
2032 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2033 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2034 ;;
2035 -clix*)
2036 basic_machine=clipper-intergraph
2037 ;;
2038 -isc*)
2039 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
2040 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
2041 ;;
2042 -lynx*178)
2043 os=-lynxos178
2044 @@ -232,10 +227,7 @@ case $os in
2045 os=-lynxos
2046 ;;
2047 -ptx*)
2048 - basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
2049 - ;;
2050 - -windowsnt*)
2051 - os=`echo $os | sed -e 's/windowsnt/winnt/'`
2052 + basic_machine=`echo "$1" | sed -e 's/86-.*/86-sequent/'`
2053 ;;
2054 -psos*)
2055 os=-psos
2056 @@ -256,19 +248,21 @@ case $basic_machine in
2057 | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
2058 | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
2059 | am33_2.0 \
2060 - | arc \
2061 + | arc | arceb \
2062 | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \
2063 | avr | avr32 \
2064 + | ba \
2065 | be32 | be64 \
2066 | bfin \
2067 - | c4x | clipper \
2068 + | c4x | c8051 | clipper \
2069 | d10v | d30v | dlx | dsp16xx \
2070 - | epiphany \
2071 - | fido | fr30 | frv \
2072 + | e2k | epiphany \
2073 + | fido | fr30 | frv | ft32 \
2074 | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
2075 | hexagon \
2076 - | i370 | i860 | i960 | ia64 \
2077 + | i370 | i860 | i960 | ia16 | ia64 \
2078 | ip2k | iq2000 \
2079 + | k1om \
2080 | le32 | le64 \
2081 | lm32 \
2082 | m32c | m32r | m32rle | m68000 | m68k | m88k \
2083 @@ -286,26 +280,30 @@ case $basic_machine in
2084 | mips64vr5900 | mips64vr5900el \
2085 | mipsisa32 | mipsisa32el \
2086 | mipsisa32r2 | mipsisa32r2el \
2087 + | mipsisa32r6 | mipsisa32r6el \
2088 | mipsisa64 | mipsisa64el \
2089 | mipsisa64r2 | mipsisa64r2el \
2090 + | mipsisa64r6 | mipsisa64r6el \
2091 | mipsisa64sb1 | mipsisa64sb1el \
2092 | mipsisa64sr71k | mipsisa64sr71kel \
2093 + | mipsr5900 | mipsr5900el \
2094 | mipstx39 | mipstx39el \
2095 | mn10200 | mn10300 \
2096 | moxie \
2097 | mt \
2098 | msp430 \
2099 | nds32 | nds32le | nds32be \
2100 - | nios | nios2 \
2101 + | nios | nios2 | nios2eb | nios2el \
2102 | ns16k | ns32k \
2103 - | open8 \
2104 - | or32 \
2105 - | pdp10 | pdp11 | pj | pjl \
2106 + | open8 | or1k | or1knd | or32 \
2107 + | pdp10 | pj | pjl \
2108 | powerpc | powerpc64 | powerpc64le | powerpcle \
2109 + | pru \
2110 | pyramid \
2111 + | riscv32 | riscv64 \
2112 | rl78 | rx \
2113 | score \
2114 - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
2115 + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
2116 | sh64 | sh64le \
2117 | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
2118 | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
2119 @@ -313,7 +311,8 @@ case $basic_machine in
2120 | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
2121 | ubicom32 \
2122 | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
2123 - | we32k \
2124 + | visium \
2125 + | wasm32 \
2126 | x86 | xc16x | xstormy16 | xtensa \
2127 | z8k | z80)
2128 basic_machine=$basic_machine-unknown
2129 @@ -327,11 +326,14 @@ case $basic_machine in
2130 c6x)
2131 basic_machine=tic6x-unknown
2132 ;;
2133 - m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip)
2134 + leon|leon[3-9])
2135 + basic_machine=sparc-$basic_machine
2136 + ;;
2137 + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip)
2138 basic_machine=$basic_machine-unknown
2139 os=-none
2140 ;;
2141 - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
2142 + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65)
2143 ;;
2144 ms1)
2145 basic_machine=mt-unknown
2146 @@ -360,7 +362,7 @@ case $basic_machine in
2147 ;;
2148 # Object if more than one company name word.
2149 *-*-*)
2150 - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
2151 + echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2
2152 exit 1
2153 ;;
2154 # Recognize the basic CPU types with company name.
2155 @@ -369,21 +371,23 @@ case $basic_machine in
2156 | aarch64-* | aarch64_be-* \
2157 | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
2158 | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
2159 - | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
2160 + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \
2161 | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
2162 | avr-* | avr32-* \
2163 + | ba-* \
2164 | be32-* | be64-* \
2165 | bfin-* | bs2000-* \
2166 | c[123]* | c30-* | [cjt]90-* | c4x-* \
2167 - | clipper-* | craynv-* | cydra-* \
2168 + | c8051-* | clipper-* | craynv-* | cydra-* \
2169 | d10v-* | d30v-* | dlx-* \
2170 - | elxsi-* \
2171 + | e2k-* | elxsi-* \
2172 | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
2173 | h8300-* | h8500-* \
2174 | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
2175 | hexagon-* \
2176 - | i*86-* | i860-* | i960-* | ia64-* \
2177 + | i*86-* | i860-* | i960-* | ia16-* | ia64-* \
2178 | ip2k-* | iq2000-* \
2179 + | k1om-* \
2180 | le32-* | le64-* \
2181 | lm32-* \
2182 | m32c-* | m32r-* | m32rle-* \
2183 @@ -403,28 +407,34 @@ case $basic_machine in
2184 | mips64vr5900-* | mips64vr5900el-* \
2185 | mipsisa32-* | mipsisa32el-* \
2186 | mipsisa32r2-* | mipsisa32r2el-* \
2187 + | mipsisa32r6-* | mipsisa32r6el-* \
2188 | mipsisa64-* | mipsisa64el-* \
2189 | mipsisa64r2-* | mipsisa64r2el-* \
2190 + | mipsisa64r6-* | mipsisa64r6el-* \
2191 | mipsisa64sb1-* | mipsisa64sb1el-* \
2192 | mipsisa64sr71k-* | mipsisa64sr71kel-* \
2193 + | mipsr5900-* | mipsr5900el-* \
2194 | mipstx39-* | mipstx39el-* \
2195 | mmix-* \
2196 | mt-* \
2197 | msp430-* \
2198 | nds32-* | nds32le-* | nds32be-* \
2199 - | nios-* | nios2-* \
2200 + | nios-* | nios2-* | nios2eb-* | nios2el-* \
2201 | none-* | np1-* | ns16k-* | ns32k-* \
2202 | open8-* \
2203 + | or1k*-* \
2204 | orion-* \
2205 | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
2206 | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
2207 + | pru-* \
2208 | pyramid-* \
2209 + | riscv32-* | riscv64-* \
2210 | rl78-* | romp-* | rs6000-* | rx-* \
2211 | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
2212 | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
2213 | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
2214 | sparclite-* \
2215 - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \
2216 + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \
2217 | tahoe-* \
2218 | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
2219 | tile*-* \
2220 @@ -432,6 +442,8 @@ case $basic_machine in
2221 | ubicom32-* \
2222 | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
2223 | vax-* \
2224 + | visium-* \
2225 + | wasm32-* \
2226 | we32k-* \
2227 | x86-* | x86_64-* | xc16x-* | xps100-* \
2228 | xstormy16-* | xtensa*-* \
2229 @@ -445,7 +457,7 @@ case $basic_machine in
2230 # Recognize the various machine names and aliases which stand
2231 # for a CPU type and a company and sometimes even an OS.
2232 386bsd)
2233 - basic_machine=i386-unknown
2234 + basic_machine=i386-pc
2235 os=-bsd
2236 ;;
2237 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
2238 @@ -479,7 +491,7 @@ case $basic_machine in
2239 basic_machine=x86_64-pc
2240 ;;
2241 amd64-*)
2242 - basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
2243 + basic_machine=x86_64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2244 ;;
2245 amdahl)
2246 basic_machine=580-amdahl
2247 @@ -508,6 +520,9 @@ case $basic_machine in
2248 basic_machine=i386-pc
2249 os=-aros
2250 ;;
2251 + asmjs)
2252 + basic_machine=asmjs-unknown
2253 + ;;
2254 aux)
2255 basic_machine=m68k-apple
2256 os=-aux
2257 @@ -521,7 +536,7 @@ case $basic_machine in
2258 os=-linux
2259 ;;
2260 blackfin-*)
2261 - basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
2262 + basic_machine=bfin-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2263 os=-linux
2264 ;;
2265 bluegene*)
2266 @@ -529,13 +544,13 @@ case $basic_machine in
2267 os=-cnk
2268 ;;
2269 c54x-*)
2270 - basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'`
2271 + basic_machine=tic54x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2272 ;;
2273 c55x-*)
2274 - basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'`
2275 + basic_machine=tic55x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2276 ;;
2277 c6x-*)
2278 - basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'`
2279 + basic_machine=tic6x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2280 ;;
2281 c90)
2282 basic_machine=c90-cray
2283 @@ -624,10 +639,18 @@ case $basic_machine in
2284 basic_machine=rs6000-bull
2285 os=-bosx
2286 ;;
2287 - dpx2* | dpx2*-bull)
2288 + dpx2*)
2289 basic_machine=m68k-bull
2290 os=-sysv3
2291 ;;
2292 + e500v[12])
2293 + basic_machine=powerpc-unknown
2294 + os=$os"spe"
2295 + ;;
2296 + e500v[12]-*)
2297 + basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2298 + os=$os"spe"
2299 + ;;
2300 ebmon29k)
2301 basic_machine=a29k-amd
2302 os=-ebmon
2303 @@ -717,9 +740,6 @@ case $basic_machine in
2304 hp9k8[0-9][0-9] | hp8[0-9][0-9])
2305 basic_machine=hppa1.0-hp
2306 ;;
2307 - hppa-next)
2308 - os=-nextstep3
2309 - ;;
2310 hppaosf)
2311 basic_machine=hppa1.1-hp
2312 os=-osf
2313 @@ -732,26 +752,26 @@ case $basic_machine in
2314 basic_machine=i370-ibm
2315 ;;
2316 i*86v32)
2317 - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2318 + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
2319 os=-sysv32
2320 ;;
2321 i*86v4*)
2322 - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2323 + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
2324 os=-sysv4
2325 ;;
2326 i*86v)
2327 - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2328 + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
2329 os=-sysv
2330 ;;
2331 i*86sol2)
2332 - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
2333 + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
2334 os=-solaris2
2335 ;;
2336 i386mach)
2337 basic_machine=i386-mach
2338 os=-mach
2339 ;;
2340 - i386-vsta | vsta)
2341 + vsta)
2342 basic_machine=i386-unknown
2343 os=-vsta
2344 ;;
2345 @@ -769,17 +789,17 @@ case $basic_machine in
2346 basic_machine=m68k-isi
2347 os=-sysv
2348 ;;
2349 + leon-*|leon[3-9]-*)
2350 + basic_machine=sparc-`echo "$basic_machine" | sed 's/-.*//'`
2351 + ;;
2352 m68knommu)
2353 basic_machine=m68k-unknown
2354 os=-linux
2355 ;;
2356 m68knommu-*)
2357 - basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
2358 + basic_machine=m68k-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2359 os=-linux
2360 ;;
2361 - m88k-omron*)
2362 - basic_machine=m88k-omron
2363 - ;;
2364 magnum | m3230)
2365 basic_machine=mips-mips
2366 os=-sysv
2367 @@ -796,7 +816,7 @@ case $basic_machine in
2368 os=-mingw64
2369 ;;
2370 mingw32)
2371 - basic_machine=i386-pc
2372 + basic_machine=i686-pc
2373 os=-mingw32
2374 ;;
2375 mingw32ce)
2376 @@ -811,10 +831,10 @@ case $basic_machine in
2377 os=-mint
2378 ;;
2379 mips3*-*)
2380 - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
2381 + basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`
2382 ;;
2383 mips3*)
2384 - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
2385 + basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`-unknown
2386 ;;
2387 monitor)
2388 basic_machine=m68k-rom68k
2389 @@ -824,15 +844,19 @@ case $basic_machine in
2390 basic_machine=powerpc-unknown
2391 os=-morphos
2392 ;;
2393 + moxiebox)
2394 + basic_machine=moxie-unknown
2395 + os=-moxiebox
2396 + ;;
2397 msdos)
2398 basic_machine=i386-pc
2399 os=-msdos
2400 ;;
2401 ms1-*)
2402 - basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
2403 + basic_machine=`echo "$basic_machine" | sed -e 's/ms1-/mt-/'`
2404 ;;
2405 msys)
2406 - basic_machine=i386-pc
2407 + basic_machine=i686-pc
2408 os=-msys
2409 ;;
2410 mvs)
2411 @@ -871,7 +895,7 @@ case $basic_machine in
2412 basic_machine=v70-nec
2413 os=-sysv
2414 ;;
2415 - next | m*-next )
2416 + next | m*-next)
2417 basic_machine=m68k-next
2418 case $os in
2419 -nextstep* )
2420 @@ -916,6 +940,12 @@ case $basic_machine in
2421 nsr-tandem)
2422 basic_machine=nsr-tandem
2423 ;;
2424 + nsv-tandem)
2425 + basic_machine=nsv-tandem
2426 + ;;
2427 + nsx-tandem)
2428 + basic_machine=nsx-tandem
2429 + ;;
2430 op50n-* | op60c-*)
2431 basic_machine=hppa1.1-oki
2432 os=-proelf
2433 @@ -948,7 +978,7 @@ case $basic_machine in
2434 os=-linux
2435 ;;
2436 parisc-*)
2437 - basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
2438 + basic_machine=hppa-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2439 os=-linux
2440 ;;
2441 pbd)
2442 @@ -964,7 +994,7 @@ case $basic_machine in
2443 basic_machine=i386-pc
2444 ;;
2445 pc98-*)
2446 - basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
2447 + basic_machine=i386-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2448 ;;
2449 pentium | p5 | k5 | k6 | nexgen | viac3)
2450 basic_machine=i586-pc
2451 @@ -979,16 +1009,16 @@ case $basic_machine in
2452 basic_machine=i786-pc
2453 ;;
2454 pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
2455 - basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
2456 + basic_machine=i586-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2457 ;;
2458 pentiumpro-* | p6-* | 6x86-* | athlon-*)
2459 - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
2460 + basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2461 ;;
2462 pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
2463 - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
2464 + basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2465 ;;
2466 pentium4-*)
2467 - basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
2468 + basic_machine=i786-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2469 ;;
2470 pn)
2471 basic_machine=pn-gould
2472 @@ -998,23 +1028,23 @@ case $basic_machine in
2473 ppc | ppcbe) basic_machine=powerpc-unknown
2474 ;;
2475 ppc-* | ppcbe-*)
2476 - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
2477 + basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2478 ;;
2479 - ppcle | powerpclittle | ppc-le | powerpc-little)
2480 + ppcle | powerpclittle)
2481 basic_machine=powerpcle-unknown
2482 ;;
2483 ppcle-* | powerpclittle-*)
2484 - basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
2485 + basic_machine=powerpcle-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2486 ;;
2487 ppc64) basic_machine=powerpc64-unknown
2488 ;;
2489 - ppc64-* | ppc64p7-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
2490 + ppc64-*) basic_machine=powerpc64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2491 ;;
2492 - ppc64le | powerpc64little | ppc64-le | powerpc64-little)
2493 + ppc64le | powerpc64little)
2494 basic_machine=powerpc64le-unknown
2495 ;;
2496 ppc64le-* | powerpc64little-*)
2497 - basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
2498 + basic_machine=powerpc64le-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2499 ;;
2500 ps2)
2501 basic_machine=i386-ibm
2502 @@ -1068,17 +1098,10 @@ case $basic_machine in
2503 sequent)
2504 basic_machine=i386-sequent
2505 ;;
2506 - sh)
2507 - basic_machine=sh-hitachi
2508 - os=-hms
2509 - ;;
2510 sh5el)
2511 basic_machine=sh5le-unknown
2512 ;;
2513 - sh64)
2514 - basic_machine=sh64-unknown
2515 - ;;
2516 - sparclite-wrs | simso-wrs)
2517 + simso-wrs)
2518 basic_machine=sparclite-wrs
2519 os=-vxworks
2520 ;;
2521 @@ -1097,7 +1120,7 @@ case $basic_machine in
2522 os=-sysv4
2523 ;;
2524 strongarm-* | thumb-*)
2525 - basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'`
2526 + basic_machine=arm-`echo "$basic_machine" | sed 's/^[^-]*-//'`
2527 ;;
2528 sun2)
2529 basic_machine=m68000-sun
2530 @@ -1219,6 +1242,9 @@ case $basic_machine in
2531 basic_machine=hppa1.1-winbond
2532 os=-proelf
2533 ;;
2534 + x64)
2535 + basic_machine=x86_64-pc
2536 + ;;
2537 xbox)
2538 basic_machine=i686-pc
2539 os=-mingw32
2540 @@ -1227,20 +1253,12 @@ case $basic_machine in
2541 basic_machine=xps100-honeywell
2542 ;;
2543 xscale-* | xscalee[bl]-*)
2544 - basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'`
2545 + basic_machine=`echo "$basic_machine" | sed 's/^xscale/arm/'`
2546 ;;
2547 ymp)
2548 basic_machine=ymp-cray
2549 os=-unicos
2550 ;;
2551 - z8k-*-coff)
2552 - basic_machine=z8k-unknown
2553 - os=-sim
2554 - ;;
2555 - z80-*-coff)
2556 - basic_machine=z80-unknown
2557 - os=-sim
2558 - ;;
2559 none)
2560 basic_machine=none-none
2561 os=-none
2562 @@ -1269,10 +1287,6 @@ case $basic_machine in
2563 vax)
2564 basic_machine=vax-dec
2565 ;;
2566 - pdp10)
2567 - # there are many clones, so DEC is not a safe bet
2568 - basic_machine=pdp10-unknown
2569 - ;;
2570 pdp11)
2571 basic_machine=pdp11-dec
2572 ;;
2573 @@ -1282,9 +1296,6 @@ case $basic_machine in
2574 sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
2575 basic_machine=sh-unknown
2576 ;;
2577 - sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
2578 - basic_machine=sparc-sun
2579 - ;;
2580 cydra)
2581 basic_machine=cydra-cydrome
2582 ;;
2583 @@ -1304,7 +1315,7 @@ case $basic_machine in
2584 # Make sure to match an already-canonicalized machine name.
2585 ;;
2586 *)
2587 - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
2588 + echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2
2589 exit 1
2590 ;;
2591 esac
2592 @@ -1312,10 +1323,10 @@ esac
2593 # Here we canonicalize certain aliases for manufacturers.
2594 case $basic_machine in
2595 *-digital*)
2596 - basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
2597 + basic_machine=`echo "$basic_machine" | sed 's/digital.*/dec/'`
2598 ;;
2599 *-commodore*)
2600 - basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
2601 + basic_machine=`echo "$basic_machine" | sed 's/commodore.*/cbm/'`
2602 ;;
2603 *)
2604 ;;
2605 @@ -1326,8 +1337,8 @@ esac
2606 if [ x"$os" != x"" ]
2607 then
2608 case $os in
2609 - # First match some system type aliases
2610 - # that might get confused with valid system types.
2611 + # First match some system type aliases that might get confused
2612 + # with valid system types.
2613 # -solaris* is a basic system type, with this one exception.
2614 -auroraux)
2615 os=-auroraux
2616 @@ -1338,45 +1349,48 @@ case $os in
2617 -solaris)
2618 os=-solaris2
2619 ;;
2620 - -svr4*)
2621 - os=-sysv4
2622 - ;;
2623 -unixware*)
2624 os=-sysv4.2uw
2625 ;;
2626 -gnu/linux*)
2627 os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
2628 ;;
2629 - # First accept the basic system types.
2630 + # es1800 is here to avoid being matched by es* (a different OS)
2631 + -es1800*)
2632 + os=-ose
2633 + ;;
2634 + # Now accept the basic system types.
2635 # The portable systems comes first.
2636 - # Each alternative MUST END IN A *, to match a version number.
2637 + # Each alternative MUST end in a * to match a version number.
2638 # -sysv* is not here because it comes later, after sysvr4.
2639 -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
2640 | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
2641 | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
2642 - | -sym* | -kopensolaris* \
2643 + | -sym* | -kopensolaris* | -plan9* \
2644 | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
2645 - | -aos* | -aros* \
2646 + | -aos* | -aros* | -cloudabi* | -sortix* \
2647 | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
2648 | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
2649 - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
2650 - | -bitrig* | -openbsd* | -solidbsd* \
2651 + | -hiux* | -knetbsd* | -mirbsd* | -netbsd* \
2652 + | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \
2653 | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
2654 | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
2655 | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
2656 | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
2657 - | -chorusos* | -chorusrdb* | -cegcc* \
2658 + | -chorusos* | -chorusrdb* | -cegcc* | -glidix* \
2659 | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
2660 - | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
2661 + | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
2662 | -linux-newlib* | -linux-musl* | -linux-uclibc* \
2663 - | -uxpv* | -beos* | -mpeix* | -udk* \
2664 - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
2665 + | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \
2666 + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* \
2667 | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
2668 | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
2669 | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
2670 - | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
2671 + | -morphos* | -superux* | -rtmk* | -windiss* \
2672 | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
2673 - | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
2674 + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \
2675 + | -onefs* | -tirtos* | -phoenix* | -fuchsia* | -redox* | -bme* \
2676 + | -midnightbsd*)
2677 # Remember, each alternative MUST END IN *, to match a version number.
2678 ;;
2679 -qnx*)
2680 @@ -1393,12 +1407,12 @@ case $os in
2681 -nto*)
2682 os=`echo $os | sed -e 's|nto|nto-qnx|'`
2683 ;;
2684 - -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
2685 - | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
2686 + -sim | -xray | -os68k* | -v88r* \
2687 + | -windows* | -osx | -abug | -netware* | -os9* \
2688 | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
2689 ;;
2690 -mac*)
2691 - os=`echo $os | sed -e 's|mac|macos|'`
2692 + os=`echo "$os" | sed -e 's|mac|macos|'`
2693 ;;
2694 -linux-dietlibc)
2695 os=-linux-dietlibc
2696 @@ -1407,10 +1421,10 @@ case $os in
2697 os=`echo $os | sed -e 's|linux|linux-gnu|'`
2698 ;;
2699 -sunos5*)
2700 - os=`echo $os | sed -e 's|sunos5|solaris2|'`
2701 + os=`echo "$os" | sed -e 's|sunos5|solaris2|'`
2702 ;;
2703 -sunos6*)
2704 - os=`echo $os | sed -e 's|sunos6|solaris3|'`
2705 + os=`echo "$os" | sed -e 's|sunos6|solaris3|'`
2706 ;;
2707 -opened*)
2708 os=-openedition
2709 @@ -1421,12 +1435,6 @@ case $os in
2710 -wince*)
2711 os=-wince
2712 ;;
2713 - -osfrose*)
2714 - os=-osfrose
2715 - ;;
2716 - -osf*)
2717 - os=-osf
2718 - ;;
2719 -utek*)
2720 os=-bsd
2721 ;;
2722 @@ -1451,7 +1459,7 @@ case $os in
2723 -nova*)
2724 os=-rtmk-nova
2725 ;;
2726 - -ns2 )
2727 + -ns2)
2728 os=-nextstep2
2729 ;;
2730 -nsk*)
2731 @@ -1473,7 +1481,7 @@ case $os in
2732 -oss*)
2733 os=-sysv3
2734 ;;
2735 - -svr4)
2736 + -svr4*)
2737 os=-sysv4
2738 ;;
2739 -svr3)
2740 @@ -1488,35 +1496,38 @@ case $os in
2741 -ose*)
2742 os=-ose
2743 ;;
2744 - -es1800*)
2745 - os=-ose
2746 - ;;
2747 - -xenix)
2748 - os=-xenix
2749 - ;;
2750 -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
2751 os=-mint
2752 ;;
2753 - -aros*)
2754 - os=-aros
2755 - ;;
2756 - -kaos*)
2757 - os=-kaos
2758 - ;;
2759 -zvmoe)
2760 os=-zvmoe
2761 ;;
2762 -dicos*)
2763 os=-dicos
2764 ;;
2765 + -pikeos*)
2766 + # Until real need of OS specific support for
2767 + # particular features comes up, bare metal
2768 + # configurations are quite functional.
2769 + case $basic_machine in
2770 + arm*)
2771 + os=-eabi
2772 + ;;
2773 + *)
2774 + os=-elf
2775 + ;;
2776 + esac
2777 + ;;
2778 -nacl*)
2779 ;;
2780 + -ios)
2781 + ;;
2782 -none)
2783 ;;
2784 *)
2785 # Get rid of the `-' at the beginning of $os.
2786 os=`echo $os | sed 's/[^-]*-//'`
2787 - echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
2788 + echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2
2789 exit 1
2790 ;;
2791 esac
2792 @@ -1551,6 +1562,9 @@ case $basic_machine in
2793 c4x-* | tic4x-*)
2794 os=-coff
2795 ;;
2796 + c8051-*)
2797 + os=-elf
2798 + ;;
2799 hexagon-*)
2800 os=-elf
2801 ;;
2802 @@ -1603,12 +1617,12 @@ case $basic_machine in
2803 sparc-* | *-sun)
2804 os=-sunos4.1.1
2805 ;;
2806 + pru-*)
2807 + os=-elf
2808 + ;;
2809 *-be)
2810 os=-beos
2811 ;;
2812 - *-haiku)
2813 - os=-haiku
2814 - ;;
2815 *-ibm)
2816 os=-aix
2817 ;;
2818 @@ -1648,7 +1662,7 @@ case $basic_machine in
2819 m88k-omron*)
2820 os=-luna
2821 ;;
2822 - *-next )
2823 + *-next)
2824 os=-nextstep
2825 ;;
2826 *-sequent)
2827 @@ -1663,9 +1677,6 @@ case $basic_machine in
2828 i370-*)
2829 os=-mvs
2830 ;;
2831 - *-next)
2832 - os=-nextstep3
2833 - ;;
2834 *-gould)
2835 os=-sysv
2836 ;;
2837 @@ -1775,15 +1786,15 @@ case $basic_machine in
2838 vendor=stratus
2839 ;;
2840 esac
2841 - basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
2842 + basic_machine=`echo "$basic_machine" | sed "s/unknown/$vendor/"`
2843 ;;
2844 esac
2845
2846 -echo $basic_machine$os
2847 +echo "$basic_machine$os"
2848 exit
2849
2850 # Local variables:
2851 -# eval: (add-hook 'write-file-hooks 'time-stamp)
2852 +# eval: (add-hook 'write-file-functions 'time-stamp)
2853 # time-stamp-start: "timestamp='"
2854 # time-stamp-format: "%:y-%02m-%02d"
2855 # time-stamp-end: "'"
2856 diff --git a/configure b/configure
2857 index c5e55b7..0ac7657 100755
2858 --- a/configure
2859 +++ b/configure
2860 @@ -792,6 +792,7 @@ infodir
2861 docdir
2862 oldincludedir
2863 includedir
2864 +runstatedir
2865 localstatedir
2866 sharedstatedir
2867 sysconfdir
2868 @@ -907,6 +908,7 @@ datadir='${datarootdir}'
2869 sysconfdir='${prefix}/etc'
2870 sharedstatedir='${prefix}/com'
2871 localstatedir='${prefix}/var'
2872 +runstatedir='${localstatedir}/run'
2873 includedir='${prefix}/include'
2874 oldincludedir='/usr/include'
2875 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
2876 @@ -1159,6 +1161,15 @@ do
2877 | -silent | --silent | --silen | --sile | --sil)
2878 silent=yes ;;
2879
2880 + -runstatedir | --runstatedir | --runstatedi | --runstated \
2881 + | --runstate | --runstat | --runsta | --runst | --runs \
2882 + | --run | --ru | --r)
2883 + ac_prev=runstatedir ;;
2884 + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
2885 + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
2886 + | --run=* | --ru=* | --r=*)
2887 + runstatedir=$ac_optarg ;;
2888 +
2889 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
2890 ac_prev=sbindir ;;
2891 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
2892 @@ -1296,7 +1307,7 @@ fi
2893 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2894 datadir sysconfdir sharedstatedir localstatedir includedir \
2895 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2896 - libdir localedir mandir
2897 + libdir localedir mandir runstatedir
2898 do
2899 eval ac_val=\$$ac_var
2900 # Remove trailing slashes.
2901 @@ -1449,6 +1460,7 @@ Fine tuning of the installation directories:
2902 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2903 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2904 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2905 + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
2906 --libdir=DIR object code libraries [EPREFIX/lib]
2907 --includedir=DIR C header files [PREFIX/include]
2908 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2909 @@ -6970,7 +6982,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
2910 lt_cv_deplibs_check_method=pass_all
2911 ;;
2912
2913 -netbsd*)
2914 +netbsd* | netbsdelf*-gnu)
2915 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
2916 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
2917 else
2918 @@ -7831,11 +7843,8 @@ _LT_EOF
2919 test $ac_status = 0; }; then
2920 # Now try to grab the symbols.
2921 nlist=conftest.nm
2922 - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
2923 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
2924 - ac_status=$?
2925 - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2926 - test $ac_status = 0; } && test -s "$nlist"; then
2927 + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5
2928 + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&5 && test -s "$nlist"; then
2929 # Try sorting and uniquifying the output.
2930 if sort "$nlist" | uniq > "$nlist"T; then
2931 mv -f "$nlist"T "$nlist"
2932 @@ -10353,6 +10362,12 @@ lt_prog_compiler_static=
2933 lt_prog_compiler_pic='-KPIC'
2934 lt_prog_compiler_static='-static'
2935 ;;
2936 + # flang / f18. f95 an alias for gfortran or flang on Debian
2937 + flang* | f18* | f95*)
2938 + lt_prog_compiler_wl='-Wl,'
2939 + lt_prog_compiler_pic='-fPIC'
2940 + lt_prog_compiler_static='-static'
2941 + ;;
2942 # icc used to be incompatible with GCC.
2943 # ICC 10 doesn't accept -KPIC any more.
2944 icc* | ifort*)
2945 @@ -10829,6 +10844,9 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
2946 openbsd* | bitrig*)
2947 with_gnu_ld=no
2948 ;;
2949 + linux* | k*bsd*-gnu | gnu*)
2950 + link_all_deplibs=no
2951 + ;;
2952 esac
2953
2954 ld_shlibs=yes
2955 @@ -11083,7 +11101,7 @@ _LT_EOF
2956 fi
2957 ;;
2958
2959 - netbsd*)
2960 + netbsd* | netbsdelf*-gnu)
2961 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2962 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
2963 wlarc=
2964 @@ -11753,6 +11771,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; }
2965 if test yes = "$lt_cv_irix_exported_symbol"; then
2966 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
2967 fi
2968 + link_all_deplibs=no
2969 else
2970 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
2971 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
2972 @@ -11774,7 +11793,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; }
2973 esac
2974 ;;
2975
2976 - netbsd*)
2977 + netbsd* | netbsdelf*-gnu)
2978 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2979 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
2980 else
2981 @@ -12869,9 +12888,6 @@ fi
2982 # before this can be enabled.
2983 hardcode_into_libs=yes
2984
2985 - # Add ABI-specific directories to the system library path.
2986 - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
2987 -
2988 # Ideally, we could use ldconfig to report *all* directores which are
2989 # searched for libraries, however this is still not possible. Aside from not
2990 # being certain /sbin/ldconfig is available, command
2991 @@ -12880,7 +12896,7 @@ fi
2992 # appending ld.so.conf contents (and includes) to the search path.
2993 if test -f /etc/ld.so.conf; then
2994 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
2995 - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
2996 + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2997 fi
2998
2999 # We used to test for /lib/ld.so.1 and disable shared libraries on
3000 @@ -12892,6 +12908,18 @@ fi
3001 dynamic_linker='GNU/Linux ld.so'
3002 ;;
3003
3004 +netbsdelf*-gnu)
3005 + version_type=linux
3006 + need_lib_prefix=no
3007 + need_version=no
3008 + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3009 + soname_spec='${libname}${release}${shared_ext}$major'
3010 + shlibpath_var=LD_LIBRARY_PATH
3011 + shlibpath_overrides_runpath=no
3012 + hardcode_into_libs=yes
3013 + dynamic_linker='NetBSD ld.elf_so'
3014 + ;;
3015 +
3016 netbsd*)
3017 version_type=sunos
3018 need_lib_prefix=no
3019 @@ -14282,7 +14310,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
3020 # Commands to make compiler produce verbose output that lists
3021 # what "hidden" libraries, object files and flags are used when
3022 # linking a shared library.
3023 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
3024 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
3025
3026 else
3027 GXX=no
3028 @@ -14774,7 +14802,7 @@ fi
3029 # explicitly linking system object files so we need to strip them
3030 # from the output so that they don't get included in the library
3031 # dependencies.
3032 - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
3033 + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
3034 ;;
3035 *)
3036 if test yes = "$GXX"; then
3037 @@ -14839,7 +14867,7 @@ fi
3038 # explicitly linking system object files so we need to strip them
3039 # from the output so that they don't get included in the library
3040 # dependencies.
3041 - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
3042 + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
3043 ;;
3044 *)
3045 if test yes = "$GXX"; then
3046 @@ -15178,7 +15206,7 @@ fi
3047 # Commands to make compiler produce verbose output that lists
3048 # what "hidden" libraries, object files and flags are used when
3049 # linking a shared library.
3050 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
3051 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
3052
3053 else
3054 # FIXME: insert proper C++ library support
3055 @@ -15262,7 +15290,7 @@ fi
3056 # Commands to make compiler produce verbose output that lists
3057 # what "hidden" libraries, object files and flags are used when
3058 # linking a shared library.
3059 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
3060 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
3061 else
3062 # g++ 2.7 appears to require '-G' NOT '-shared' on this
3063 # platform.
3064 @@ -15273,7 +15301,7 @@ fi
3065 # Commands to make compiler produce verbose output that lists
3066 # what "hidden" libraries, object files and flags are used when
3067 # linking a shared library.
3068 - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
3069 + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
3070 fi
3071
3072 hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir'
3073 @@ -15786,7 +15814,7 @@ lt_prog_compiler_static_CXX=
3074 ;;
3075 esac
3076 ;;
3077 - netbsd*)
3078 + netbsd* | netbsdelf*-gnu)
3079 ;;
3080 *qnx* | *nto*)
3081 # QNX uses GNU C++, but need to define -shared option too, otherwise
3082 @@ -16161,6 +16189,9 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
3083 ;;
3084 esac
3085 ;;
3086 + linux* | k*bsd*-gnu | gnu*)
3087 + link_all_deplibs_CXX=no
3088 + ;;
3089 *)
3090 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
3091 ;;
3092 @@ -16834,9 +16865,6 @@ fi
3093 # before this can be enabled.
3094 hardcode_into_libs=yes
3095
3096 - # Add ABI-specific directories to the system library path.
3097 - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
3098 -
3099 # Ideally, we could use ldconfig to report *all* directores which are
3100 # searched for libraries, however this is still not possible. Aside from not
3101 # being certain /sbin/ldconfig is available, command
3102 @@ -16845,7 +16873,7 @@ fi
3103 # appending ld.so.conf contents (and includes) to the search path.
3104 if test -f /etc/ld.so.conf; then
3105 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
3106 - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
3107 + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
3108 fi
3109
3110 # We used to test for /lib/ld.so.1 and disable shared libraries on
3111 @@ -16857,6 +16885,18 @@ fi
3112 dynamic_linker='GNU/Linux ld.so'
3113 ;;
3114
3115 +netbsdelf*-gnu)
3116 + version_type=linux
3117 + need_lib_prefix=no
3118 + need_version=no
3119 + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
3120 + soname_spec='${libname}${release}${shared_ext}$major'
3121 + shlibpath_var=LD_LIBRARY_PATH
3122 + shlibpath_overrides_runpath=no
3123 + hardcode_into_libs=yes
3124 + dynamic_linker='NetBSD ld.elf_so'
3125 + ;;
3126 +
3127 netbsd*)
3128 version_type=sunos
3129 need_lib_prefix=no
3130 @@ -22133,7 +22173,6 @@ See \`config.log' for more details" "$LINENO" 5; }
3131 cat <<_LT_EOF >> "$cfgfile"
3132 #! $SHELL
3133 # Generated automatically by $as_me ($PACKAGE) $VERSION
3134 -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3135 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
3136
3137 # Provide generalized library-building support services.
3138 diff --git a/docs/Makefile.in b/docs/Makefile.in
3139 index d66bc19..4601752 100644
3140 --- a/docs/Makefile.in
3141 +++ b/docs/Makefile.in
3142 @@ -341,6 +341,7 @@ pdfdir = @pdfdir@
3143 prefix = @prefix@
3144 program_transform_name = @program_transform_name@
3145 psdir = @psdir@
3146 +runstatedir = @runstatedir@
3147 sbindir = @sbindir@
3148 sharedstatedir = @sharedstatedir@
3149 srcdir = @srcdir@
3150 diff --git a/docs/doxygen/Makefile.in b/docs/doxygen/Makefile.in
3151 index 14aa78e..17f41d4 100644
3152 --- a/docs/doxygen/Makefile.in
3153 +++ b/docs/doxygen/Makefile.in
3154 @@ -281,6 +281,7 @@ pdfdir = @pdfdir@
3155 prefix = @prefix@
3156 program_transform_name = @program_transform_name@
3157 psdir = @psdir@
3158 +runstatedir = @runstatedir@
3159 sbindir = @sbindir@
3160 sharedstatedir = @sharedstatedir@
3161 srcdir = @srcdir@
3162 diff --git a/inc/Makefile.in b/inc/Makefile.in
3163 index 3181c9d..bb92038 100644
3164 --- a/inc/Makefile.in
3165 +++ b/inc/Makefile.in
3166 @@ -341,6 +341,7 @@ pdfdir = @pdfdir@
3167 prefix = @prefix@
3168 program_transform_name = @program_transform_name@
3169 psdir = @psdir@
3170 +runstatedir = @runstatedir@
3171 sbindir = @sbindir@
3172 sharedstatedir = @sharedstatedir@
3173 srcdir = @srcdir@
3174 diff --git a/inc/libetonyek/Makefile.in b/inc/libetonyek/Makefile.in
3175 index 8a619cc..d854b52 100644
3176 --- a/inc/libetonyek/Makefile.in
3177 +++ b/inc/libetonyek/Makefile.in
3178 @@ -330,6 +330,7 @@ pdfdir = @pdfdir@
3179 prefix = @prefix@
3180 program_transform_name = @program_transform_name@
3181 psdir = @psdir@
3182 +runstatedir = @runstatedir@
3183 sbindir = @sbindir@
3184 sharedstatedir = @sharedstatedir@
3185 srcdir = @srcdir@
3186 diff --git a/install-sh b/install-sh
3187 index 377bb86..8175c64 100755
3188 --- a/install-sh
3189 +++ b/install-sh
3190 @@ -1,7 +1,7 @@
3191 #!/bin/sh
3192 # install - install a program, script, or datafile
3193
3194 -scriptversion=2011-11-20.07; # UTC
3195 +scriptversion=2018-03-11.20; # UTC
3196
3197 # This originates from X11R5 (mit/util/scripts/install.sh), which was
3198 # later released in X11R6 (xc/config/util/install.sh) with the
3199 @@ -41,19 +41,15 @@ scriptversion=2011-11-20.07; # UTC
3200 # This script is compatible with the BSD install script, but was written
3201 # from scratch.
3202
3203 +tab=' '
3204 nl='
3205 '
3206 -IFS=" "" $nl"
3207 +IFS=" $tab$nl"
3208
3209 -# set DOITPROG to echo to test this script
3210 +# Set DOITPROG to "echo" to test this script.
3211
3212 -# Don't use :- since 4.3BSD and earlier shells don't like it.
3213 doit=${DOITPROG-}
3214 -if test -z "$doit"; then
3215 - doit_exec=exec
3216 -else
3217 - doit_exec=$doit
3218 -fi
3219 +doit_exec=${doit:-exec}
3220
3221 # Put in absolute file names if you don't have them in your path;
3222 # or use environment vars.
3223 @@ -68,17 +64,6 @@ mvprog=${MVPROG-mv}
3224 rmprog=${RMPROG-rm}
3225 stripprog=${STRIPPROG-strip}
3226
3227 -posix_glob='?'
3228 -initialize_posix_glob='
3229 - test "$posix_glob" != "?" || {
3230 - if (set -f) 2>/dev/null; then
3231 - posix_glob=
3232 - else
3233 - posix_glob=:
3234 - fi
3235 - }
3236 -'
3237 -
3238 posix_mkdir=
3239
3240 # Desired mode of installed file.
3241 @@ -97,7 +82,7 @@ dir_arg=
3242 dst_arg=
3243
3244 copy_on_change=false
3245 -no_target_directory=
3246 +is_target_a_directory=possibly
3247
3248 usage="\
3249 Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
3250 @@ -137,46 +122,57 @@ while test $# -ne 0; do
3251 -d) dir_arg=true;;
3252
3253 -g) chgrpcmd="$chgrpprog $2"
3254 - shift;;
3255 + shift;;
3256
3257 --help) echo "$usage"; exit $?;;
3258
3259 -m) mode=$2
3260 - case $mode in
3261 - *' '* | *' '* | *'
3262 -'* | *'*'* | *'?'* | *'['*)
3263 - echo "$0: invalid mode: $mode" >&2
3264 - exit 1;;
3265 - esac
3266 - shift;;
3267 + case $mode in
3268 + *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*)
3269 + echo "$0: invalid mode: $mode" >&2
3270 + exit 1;;
3271 + esac
3272 + shift;;
3273
3274 -o) chowncmd="$chownprog $2"
3275 - shift;;
3276 + shift;;
3277
3278 -s) stripcmd=$stripprog;;
3279
3280 - -t) dst_arg=$2
3281 - # Protect names problematic for 'test' and other utilities.
3282 - case $dst_arg in
3283 - -* | [=\(\)!]) dst_arg=./$dst_arg;;
3284 - esac
3285 - shift;;
3286 + -t)
3287 + is_target_a_directory=always
3288 + dst_arg=$2
3289 + # Protect names problematic for 'test' and other utilities.
3290 + case $dst_arg in
3291 + -* | [=\(\)!]) dst_arg=./$dst_arg;;
3292 + esac
3293 + shift;;
3294
3295 - -T) no_target_directory=true;;
3296 + -T) is_target_a_directory=never;;
3297
3298 --version) echo "$0 $scriptversion"; exit $?;;
3299
3300 - --) shift
3301 - break;;
3302 + --) shift
3303 + break;;
3304
3305 - -*) echo "$0: invalid option: $1" >&2
3306 - exit 1;;
3307 + -*) echo "$0: invalid option: $1" >&2
3308 + exit 1;;
3309
3310 *) break;;
3311 esac
3312 shift
3313 done
3314
3315 +# We allow the use of options -d and -T together, by making -d
3316 +# take the precedence; this is for compatibility with GNU install.
3317 +
3318 +if test -n "$dir_arg"; then
3319 + if test -n "$dst_arg"; then
3320 + echo "$0: target directory not allowed when installing a directory." >&2
3321 + exit 1
3322 + fi
3323 +fi
3324 +
3325 if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
3326 # When -d is used, all remaining arguments are directories to create.
3327 # When -t is used, the destination is already specified.
3328 @@ -207,6 +203,15 @@ if test $# -eq 0; then
3329 exit 0
3330 fi
3331
3332 +if test -z "$dir_arg"; then
3333 + if test $# -gt 1 || test "$is_target_a_directory" = always; then
3334 + if test ! -d "$dst_arg"; then
3335 + echo "$0: $dst_arg: Is not a directory." >&2
3336 + exit 1
3337 + fi
3338 + fi
3339 +fi
3340 +
3341 if test -z "$dir_arg"; then
3342 do_exit='(exit $ret); exit $ret'
3343 trap "ret=129; $do_exit" 1
3344 @@ -223,16 +228,16 @@ if test -z "$dir_arg"; then
3345
3346 *[0-7])
3347 if test -z "$stripcmd"; then
3348 - u_plus_rw=
3349 + u_plus_rw=
3350 else
3351 - u_plus_rw='% 200'
3352 + u_plus_rw='% 200'
3353 fi
3354 cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;;
3355 *)
3356 if test -z "$stripcmd"; then
3357 - u_plus_rw=
3358 + u_plus_rw=
3359 else
3360 - u_plus_rw=,u+rw
3361 + u_plus_rw=,u+rw
3362 fi
3363 cp_umask=$mode$u_plus_rw;;
3364 esac
3365 @@ -266,122 +271,113 @@ do
3366 fi
3367 dst=$dst_arg
3368
3369 - # If destination is a directory, append the input filename; won't work
3370 - # if double slashes aren't ignored.
3371 + # If destination is a directory, append the input filename.
3372 if test -d "$dst"; then
3373 - if test -n "$no_target_directory"; then
3374 - echo "$0: $dst_arg: Is a directory" >&2
3375 - exit 1
3376 + if test "$is_target_a_directory" = never; then
3377 + echo "$0: $dst_arg: Is a directory" >&2
3378 + exit 1
3379 fi
3380 dstdir=$dst
3381 - dst=$dstdir/`basename "$src"`
3382 + dstbase=`basename "$src"`
3383 + case $dst in
3384 + */) dst=$dst$dstbase;;
3385 + *) dst=$dst/$dstbase;;
3386 + esac
3387 dstdir_status=0
3388 else
3389 - # Prefer dirname, but fall back on a substitute if dirname fails.
3390 - dstdir=`
3391 - (dirname "$dst") 2>/dev/null ||
3392 - expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
3393 - X"$dst" : 'X\(//\)[^/]' \| \
3394 - X"$dst" : 'X\(//\)$' \| \
3395 - X"$dst" : 'X\(/\)' \| . 2>/dev/null ||
3396 - echo X"$dst" |
3397 - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
3398 - s//\1/
3399 - q
3400 - }
3401 - /^X\(\/\/\)[^/].*/{
3402 - s//\1/
3403 - q
3404 - }
3405 - /^X\(\/\/\)$/{
3406 - s//\1/
3407 - q
3408 - }
3409 - /^X\(\/\).*/{
3410 - s//\1/
3411 - q
3412 - }
3413 - s/.*/./; q'
3414 - `
3415 -
3416 + dstdir=`dirname "$dst"`
3417 test -d "$dstdir"
3418 dstdir_status=$?
3419 fi
3420 fi
3421
3422 + case $dstdir in
3423 + */) dstdirslash=$dstdir;;
3424 + *) dstdirslash=$dstdir/;;
3425 + esac
3426 +
3427 obsolete_mkdir_used=false
3428
3429 if test $dstdir_status != 0; then
3430 case $posix_mkdir in
3431 '')
3432 - # Create intermediate dirs using mode 755 as modified by the umask.
3433 - # This is like FreeBSD 'install' as of 1997-10-28.
3434 - umask=`umask`
3435 - case $stripcmd.$umask in
3436 - # Optimize common cases.
3437 - *[2367][2367]) mkdir_umask=$umask;;
3438 - .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
3439 -
3440 - *[0-7])
3441 - mkdir_umask=`expr $umask + 22 \
3442 - - $umask % 100 % 40 + $umask % 20 \
3443 - - $umask % 10 % 4 + $umask % 2
3444 - `;;
3445 - *) mkdir_umask=$umask,go-w;;
3446 - esac
3447 -
3448 - # With -d, create the new directory with the user-specified mode.
3449 - # Otherwise, rely on $mkdir_umask.
3450 - if test -n "$dir_arg"; then
3451 - mkdir_mode=-m$mode
3452 - else
3453 - mkdir_mode=
3454 - fi
3455 -
3456 - posix_mkdir=false
3457 - case $umask in
3458 - *[123567][0-7][0-7])
3459 - # POSIX mkdir -p sets u+wx bits regardless of umask, which
3460 - # is incompatible with FreeBSD 'install' when (umask & 300) != 0.
3461 - ;;
3462 - *)
3463 - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
3464 - trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
3465 -
3466 - if (umask $mkdir_umask &&
3467 - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
3468 - then
3469 - if test -z "$dir_arg" || {
3470 - # Check for POSIX incompatibilities with -m.
3471 - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
3472 - # other-writable bit of parent directory when it shouldn't.
3473 - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
3474 - ls_ld_tmpdir=`ls -ld "$tmpdir"`
3475 - case $ls_ld_tmpdir in
3476 - d????-?r-*) different_mode=700;;
3477 - d????-?--*) different_mode=755;;
3478 - *) false;;
3479 - esac &&
3480 - $mkdirprog -m$different_mode -p -- "$tmpdir" && {
3481 - ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
3482 - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
3483 - }
3484 - }
3485 - then posix_mkdir=:
3486 - fi
3487 - rmdir "$tmpdir/d" "$tmpdir"
3488 - else
3489 - # Remove any dirs left behind by ancient mkdir implementations.
3490 - rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
3491 - fi
3492 - trap '' 0;;
3493 - esac;;
3494 + # Create intermediate dirs using mode 755 as modified by the umask.
3495 + # This is like FreeBSD 'install' as of 1997-10-28.
3496 + umask=`umask`
3497 + case $stripcmd.$umask in
3498 + # Optimize common cases.
3499 + *[2367][2367]) mkdir_umask=$umask;;
3500 + .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
3501 +
3502 + *[0-7])
3503 + mkdir_umask=`expr $umask + 22 \
3504 + - $umask % 100 % 40 + $umask % 20 \
3505 + - $umask % 10 % 4 + $umask % 2
3506 + `;;
3507 + *) mkdir_umask=$umask,go-w;;
3508 + esac
3509 +
3510 + # With -d, create the new directory with the user-specified mode.
3511 + # Otherwise, rely on $mkdir_umask.
3512 + if test -n "$dir_arg"; then
3513 + mkdir_mode=-m$mode
3514 + else
3515 + mkdir_mode=
3516 + fi
3517 +
3518 + posix_mkdir=false
3519 + case $umask in
3520 + *[123567][0-7][0-7])
3521 + # POSIX mkdir -p sets u+wx bits regardless of umask, which
3522 + # is incompatible with FreeBSD 'install' when (umask & 300) != 0.
3523 + ;;
3524 + *)
3525 + # Note that $RANDOM variable is not portable (e.g. dash); Use it
3526 + # here however when possible just to lower collision chance.
3527 + tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
3528 +
3529 + trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0
3530 +
3531 + # Because "mkdir -p" follows existing symlinks and we likely work
3532 + # directly in world-writeable /tmp, make sure that the '$tmpdir'
3533 + # directory is successfully created first before we actually test
3534 + # 'mkdir -p' feature.
3535 + if (umask $mkdir_umask &&
3536 + $mkdirprog $mkdir_mode "$tmpdir" &&
3537 + exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
3538 + then
3539 + if test -z "$dir_arg" || {
3540 + # Check for POSIX incompatibilities with -m.
3541 + # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
3542 + # other-writable bit of parent directory when it shouldn't.
3543 + # FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
3544 + test_tmpdir="$tmpdir/a"
3545 + ls_ld_tmpdir=`ls -ld "$test_tmpdir"`
3546 + case $ls_ld_tmpdir in
3547 + d????-?r-*) different_mode=700;;
3548 + d????-?--*) different_mode=755;;
3549 + *) false;;
3550 + esac &&
3551 + $mkdirprog -m$different_mode -p -- "$test_tmpdir" && {
3552 + ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"`
3553 + test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
3554 + }
3555 + }
3556 + then posix_mkdir=:
3557 + fi
3558 + rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir"
3559 + else
3560 + # Remove any dirs left behind by ancient mkdir implementations.
3561 + rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null
3562 + fi
3563 + trap '' 0;;
3564 + esac;;
3565 esac
3566
3567 if
3568 $posix_mkdir && (
3569 - umask $mkdir_umask &&
3570 - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
3571 + umask $mkdir_umask &&
3572 + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
3573 )
3574 then :
3575 else
3576 @@ -391,53 +387,51 @@ do
3577 # directory the slow way, step by step, checking for races as we go.
3578
3579 case $dstdir in
3580 - /*) prefix='/';;
3581 - [-=\(\)!]*) prefix='./';;
3582 - *) prefix='';;
3583 + /*) prefix='/';;
3584 + [-=\(\)!]*) prefix='./';;
3585 + *) prefix='';;
3586 esac
3587
3588 - eval "$initialize_posix_glob"
3589 -
3590 oIFS=$IFS
3591 IFS=/
3592 - $posix_glob set -f
3593 + set -f
3594 set fnord $dstdir
3595 shift
3596 - $posix_glob set +f
3597 + set +f
3598 IFS=$oIFS
3599
3600 prefixes=
3601
3602 for d
3603 do
3604 - test X"$d" = X && continue
3605 -
3606 - prefix=$prefix$d
3607 - if test -d "$prefix"; then
3608 - prefixes=
3609 - else
3610 - if $posix_mkdir; then
3611 - (umask=$mkdir_umask &&
3612 - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
3613 - # Don't fail if two instances are running concurrently.
3614 - test -d "$prefix" || exit 1
3615 - else
3616 - case $prefix in
3617 - *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
3618 - *) qprefix=$prefix;;
3619 - esac
3620 - prefixes="$prefixes '$qprefix'"
3621 - fi
3622 - fi
3623 - prefix=$prefix/
3624 + test X"$d" = X && continue
3625 +
3626 + prefix=$prefix$d
3627 + if test -d "$prefix"; then
3628 + prefixes=
3629 + else
3630 + if $posix_mkdir; then
3631 + (umask=$mkdir_umask &&
3632 + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
3633 + # Don't fail if two instances are running concurrently.
3634 + test -d "$prefix" || exit 1
3635 + else
3636 + case $prefix in
3637 + *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
3638 + *) qprefix=$prefix;;
3639 + esac
3640 + prefixes="$prefixes '$qprefix'"
3641 + fi
3642 + fi
3643 + prefix=$prefix/
3644 done
3645
3646 if test -n "$prefixes"; then
3647 - # Don't fail if two instances are running concurrently.
3648 - (umask $mkdir_umask &&
3649 - eval "\$doit_exec \$mkdirprog $prefixes") ||
3650 - test -d "$dstdir" || exit 1
3651 - obsolete_mkdir_used=true
3652 + # Don't fail if two instances are running concurrently.
3653 + (umask $mkdir_umask &&
3654 + eval "\$doit_exec \$mkdirprog $prefixes") ||
3655 + test -d "$dstdir" || exit 1
3656 + obsolete_mkdir_used=true
3657 fi
3658 fi
3659 fi
3660 @@ -450,8 +444,8 @@ do
3661 else
3662
3663 # Make a couple of temp file names in the proper directory.
3664 - dsttmp=$dstdir/_inst.$$_
3665 - rmtmp=$dstdir/_rm.$$_
3666 + dsttmp=${dstdirslash}_inst.$$_
3667 + rmtmp=${dstdirslash}_rm.$$_
3668
3669 # Trap to clean up those temp files at exit.
3670 trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
3671 @@ -472,15 +466,12 @@ do
3672
3673 # If -C, don't bother to copy if it wouldn't change the file.
3674 if $copy_on_change &&
3675 - old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` &&
3676 - new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` &&
3677 -
3678 - eval "$initialize_posix_glob" &&
3679 - $posix_glob set -f &&
3680 + old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` &&
3681 + new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` &&
3682 + set -f &&
3683 set X $old && old=:$2:$4:$5:$6 &&
3684 set X $new && new=:$2:$4:$5:$6 &&
3685 - $posix_glob set +f &&
3686 -
3687 + set +f &&
3688 test "$old" = "$new" &&
3689 $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1
3690 then
3691 @@ -493,24 +484,24 @@ do
3692 # to itself, or perhaps because mv is so ancient that it does not
3693 # support -f.
3694 {
3695 - # Now remove or move aside any old file at destination location.
3696 - # We try this two ways since rm can't unlink itself on some
3697 - # systems and the destination file might be busy for other
3698 - # reasons. In this case, the final cleanup might fail but the new
3699 - # file should still install successfully.
3700 - {
3701 - test ! -f "$dst" ||
3702 - $doit $rmcmd -f "$dst" 2>/dev/null ||
3703 - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
3704 - { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
3705 - } ||
3706 - { echo "$0: cannot unlink or rename $dst" >&2
3707 - (exit 1); exit 1
3708 - }
3709 - } &&
3710 -
3711 - # Now rename the file to the real destination.
3712 - $doit $mvcmd "$dsttmp" "$dst"
3713 + # Now remove or move aside any old file at destination location.
3714 + # We try this two ways since rm can't unlink itself on some
3715 + # systems and the destination file might be busy for other
3716 + # reasons. In this case, the final cleanup might fail but the new
3717 + # file should still install successfully.
3718 + {
3719 + test ! -f "$dst" ||
3720 + $doit $rmcmd -f "$dst" 2>/dev/null ||
3721 + { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
3722 + { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
3723 + } ||
3724 + { echo "$0: cannot unlink or rename $dst" >&2
3725 + (exit 1); exit 1
3726 + }
3727 + } &&
3728 +
3729 + # Now rename the file to the real destination.
3730 + $doit $mvcmd "$dsttmp" "$dst"
3731 }
3732 fi || exit 1
3733
3734 @@ -519,9 +510,9 @@ do
3735 done
3736
3737 # Local variables:
3738 -# eval: (add-hook 'write-file-hooks 'time-stamp)
3739 +# eval: (add-hook 'before-save-hook 'time-stamp)
3740 # time-stamp-start: "scriptversion="
3741 # time-stamp-format: "%:y-%02m-%02d.%02H"
3742 -# time-stamp-time-zone: "UTC"
3743 +# time-stamp-time-zone: "UTC0"
3744 # time-stamp-end: "; # UTC"
3745 # End:
3746 diff --git a/ltmain.sh b/ltmain.sh
3747 index 7f3523d..d11f1e0 100644
3748 --- a/ltmain.sh
3749 +++ b/ltmain.sh
3750 @@ -31,7 +31,7 @@
3751
3752 PROGRAM=libtool
3753 PACKAGE=libtool
3754 -VERSION=2.4.6
3755 +VERSION="2.4.6 Debian-2.4.6-11"
3756 package_revision=2.4.6
3757
3758
3759 @@ -1370,7 +1370,7 @@ func_lt_ver ()
3760 #! /bin/sh
3761
3762 # Set a version string for this script.
3763 -scriptversion=2014-01-07.03; # UTC
3764 +scriptversion=2015-10-07.11; # UTC
3765
3766 # A portable, pluggable option parser for Bourne shell.
3767 # Written by Gary V. Vaughan, 2010
3768 @@ -1530,6 +1530,8 @@ func_run_hooks ()
3769 {
3770 $debug_cmd
3771
3772 + _G_rc_run_hooks=false
3773 +
3774 case " $hookable_fns " in
3775 *" $1 "*) ;;
3776 *) func_fatal_error "'$1' does not support hook funcions.n" ;;
3777 @@ -1538,16 +1540,16 @@ func_run_hooks ()
3778 eval _G_hook_fns=\$$1_hooks; shift
3779
3780 for _G_hook in $_G_hook_fns; do
3781 - eval $_G_hook '"$@"'
3782 -
3783 - # store returned options list back into positional
3784 - # parameters for next 'cmd' execution.
3785 - eval _G_hook_result=\$${_G_hook}_result
3786 - eval set dummy "$_G_hook_result"; shift
3787 + if eval $_G_hook '"$@"'; then
3788 + # store returned options list back into positional
3789 + # parameters for next 'cmd' execution.
3790 + eval _G_hook_result=\$${_G_hook}_result
3791 + eval set dummy "$_G_hook_result"; shift
3792 + _G_rc_run_hooks=:
3793 + fi
3794 done
3795
3796 - func_quote_for_eval ${1+"$@"}
3797 - func_run_hooks_result=$func_quote_for_eval_result
3798 + $_G_rc_run_hooks && func_run_hooks_result=$_G_hook_result
3799 }
3800
3801
3802 @@ -1557,10 +1559,16 @@ func_run_hooks ()
3803 ## --------------- ##
3804
3805 # In order to add your own option parsing hooks, you must accept the
3806 -# full positional parameter list in your hook function, remove any
3807 -# options that you action, and then pass back the remaining unprocessed
3808 +# full positional parameter list in your hook function, you may remove/edit
3809 +# any options that you action, and then pass back the remaining unprocessed
3810 # options in '<hooked_function_name>_result', escaped suitably for
3811 -# 'eval'. Like this:
3812 +# 'eval'. In this case you also must return $EXIT_SUCCESS to let the
3813 +# hook's caller know that it should pay attention to
3814 +# '<hooked_function_name>_result'. Returning $EXIT_FAILURE signalizes that
3815 +# arguments are left untouched by the hook and therefore caller will ignore the
3816 +# result variable.
3817 +#
3818 +# Like this:
3819 #
3820 # my_options_prep ()
3821 # {
3822 @@ -1570,9 +1578,11 @@ func_run_hooks ()
3823 # usage_message=$usage_message'
3824 # -s, --silent don'\''t print informational messages
3825 # '
3826 -#
3827 -# func_quote_for_eval ${1+"$@"}
3828 -# my_options_prep_result=$func_quote_for_eval_result
3829 +# # No change in '$@' (ignored completely by this hook). There is
3830 +# # no need to do the equivalent (but slower) action:
3831 +# # func_quote_for_eval ${1+"$@"}
3832 +# # my_options_prep_result=$func_quote_for_eval_result
3833 +# false
3834 # }
3835 # func_add_hook func_options_prep my_options_prep
3836 #
3837 @@ -1581,25 +1591,37 @@ func_run_hooks ()
3838 # {
3839 # $debug_cmd
3840 #
3841 +# args_changed=false
3842 +#
3843 # # Note that for efficiency, we parse as many options as we can
3844 # # recognise in a loop before passing the remainder back to the
3845 # # caller on the first unrecognised argument we encounter.
3846 # while test $# -gt 0; do
3847 # opt=$1; shift
3848 # case $opt in
3849 -# --silent|-s) opt_silent=: ;;
3850 +# --silent|-s) opt_silent=:
3851 +# args_changed=:
3852 +# ;;
3853 # # Separate non-argument short options:
3854 # -s*) func_split_short_opt "$_G_opt"
3855 # set dummy "$func_split_short_opt_name" \
3856 # "-$func_split_short_opt_arg" ${1+"$@"}
3857 # shift
3858 +# args_changed=:
3859 # ;;
3860 -# *) set dummy "$_G_opt" "$*"; shift; break ;;
3861 +# *) # Make sure the first unrecognised option "$_G_opt"
3862 +# # is added back to "$@", we could need that later
3863 +# # if $args_changed is true.
3864 +# set dummy "$_G_opt" ${1+"$@"}; shift; break ;;
3865 # esac
3866 # done
3867 #
3868 -# func_quote_for_eval ${1+"$@"}
3869 -# my_silent_option_result=$func_quote_for_eval_result
3870 +# if $args_changed; then
3871 +# func_quote_for_eval ${1+"$@"}
3872 +# my_silent_option_result=$func_quote_for_eval_result
3873 +# fi
3874 +#
3875 +# $args_changed
3876 # }
3877 # func_add_hook func_parse_options my_silent_option
3878 #
3879 @@ -1611,16 +1633,32 @@ func_run_hooks ()
3880 # $opt_silent && $opt_verbose && func_fatal_help "\
3881 # '--silent' and '--verbose' options are mutually exclusive."
3882 #
3883 -# func_quote_for_eval ${1+"$@"}
3884 -# my_option_validation_result=$func_quote_for_eval_result
3885 +# false
3886 # }
3887 # func_add_hook func_validate_options my_option_validation
3888 #
3889 -# You'll alse need to manually amend $usage_message to reflect the extra
3890 +# You'll also need to manually amend $usage_message to reflect the extra
3891 # options you parse. It's preferable to append if you can, so that
3892 # multiple option parsing hooks can be added safely.
3893
3894
3895 +# func_options_finish [ARG]...
3896 +# ----------------------------
3897 +# Finishing the option parse loop (call 'func_options' hooks ATM).
3898 +func_options_finish ()
3899 +{
3900 + $debug_cmd
3901 +
3902 + _G_func_options_finish_exit=false
3903 + if func_run_hooks func_options ${1+"$@"}; then
3904 + func_options_finish_result=$func_run_hooks_result
3905 + _G_func_options_finish_exit=:
3906 + fi
3907 +
3908 + $_G_func_options_finish_exit
3909 +}
3910 +
3911 +
3912 # func_options [ARG]...
3913 # ---------------------
3914 # All the functions called inside func_options are hookable. See the
3915 @@ -1630,17 +1668,28 @@ func_options ()
3916 {
3917 $debug_cmd
3918
3919 - func_options_prep ${1+"$@"}
3920 - eval func_parse_options \
3921 - ${func_options_prep_result+"$func_options_prep_result"}
3922 - eval func_validate_options \
3923 - ${func_parse_options_result+"$func_parse_options_result"}
3924 + _G_rc_options=false
3925 +
3926 + for my_func in options_prep parse_options validate_options options_finish
3927 + do
3928 + if eval func_$my_func '${1+"$@"}'; then
3929 + eval _G_res_var='$'"func_${my_func}_result"
3930 + eval set dummy "$_G_res_var" ; shift
3931 + _G_rc_options=:
3932 + fi
3933 + done
3934
3935 - eval func_run_hooks func_options \
3936 - ${func_validate_options_result+"$func_validate_options_result"}
3937 + # Save modified positional parameters for caller. As a top-level
3938 + # options-parser function we always need to set the 'func_options_result'
3939 + # variable (regardless the $_G_rc_options value).
3940 + if $_G_rc_options; then
3941 + func_options_result=$_G_res_var
3942 + else
3943 + func_quote_for_eval ${1+"$@"}
3944 + func_options_result=$func_quote_for_eval_result
3945 + fi
3946
3947 - # save modified positional parameters for caller
3948 - func_options_result=$func_run_hooks_result
3949 + $_G_rc_options
3950 }
3951
3952
3953 @@ -1649,9 +1698,9 @@ func_options ()
3954 # All initialisations required before starting the option parse loop.
3955 # Note that when calling hook functions, we pass through the list of
3956 # positional parameters. If a hook function modifies that list, and
3957 -# needs to propogate that back to rest of this script, then the complete
3958 +# needs to propagate that back to rest of this script, then the complete
3959 # modified list must be put in 'func_run_hooks_result' before
3960 -# returning.
3961 +# returning $EXIT_SUCCESS (otherwise $EXIT_FAILURE is returned).
3962 func_hookable func_options_prep
3963 func_options_prep ()
3964 {
3965 @@ -1661,10 +1710,14 @@ func_options_prep ()
3966 opt_verbose=false
3967 opt_warning_types=
3968
3969 - func_run_hooks func_options_prep ${1+"$@"}
3970 + _G_rc_options_prep=false
3971 + if func_run_hooks func_options_prep ${1+"$@"}; then
3972 + _G_rc_options_prep=:
3973 + # save modified positional parameters for caller
3974 + func_options_prep_result=$func_run_hooks_result
3975 + fi
3976
3977 - # save modified positional parameters for caller
3978 - func_options_prep_result=$func_run_hooks_result
3979 + $_G_rc_options_prep
3980 }
3981
3982
3983 @@ -1678,18 +1731,20 @@ func_parse_options ()
3984
3985 func_parse_options_result=
3986
3987 + _G_rc_parse_options=false
3988 # this just eases exit handling
3989 while test $# -gt 0; do
3990 # Defer to hook functions for initial option parsing, so they
3991 # get priority in the event of reusing an option name.
3992 - func_run_hooks func_parse_options ${1+"$@"}
3993 -
3994 - # Adjust func_parse_options positional parameters to match
3995 - eval set dummy "$func_run_hooks_result"; shift
3996 + if func_run_hooks func_parse_options ${1+"$@"}; then
3997 + eval set dummy "$func_run_hooks_result"; shift
3998 + _G_rc_parse_options=:
3999 + fi
4000
4001 # Break out of the loop if we already parsed every option.
4002 test $# -gt 0 || break
4003
4004 + _G_match_parse_options=:
4005 _G_opt=$1
4006 shift
4007 case $_G_opt in
4008 @@ -1704,7 +1759,10 @@ func_parse_options ()
4009 ;;
4010
4011 --warnings|--warning|-W)
4012 - test $# = 0 && func_missing_arg $_G_opt && break
4013 + if test $# = 0 && func_missing_arg $_G_opt; then
4014 + _G_rc_parse_options=:
4015 + break
4016 + fi
4017 case " $warning_categories $1" in
4018 *" $1 "*)
4019 # trailing space prevents matching last $1 above
4020 @@ -1757,15 +1815,25 @@ func_parse_options ()
4021 shift
4022 ;;
4023
4024 - --) break ;;
4025 + --) _G_rc_parse_options=: ; break ;;
4026 -*) func_fatal_help "unrecognised option: '$_G_opt'" ;;
4027 - *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;;
4028 + *) set dummy "$_G_opt" ${1+"$@"}; shift
4029 + _G_match_parse_options=false
4030 + break
4031 + ;;
4032 esac
4033 +
4034 + $_G_match_parse_options && _G_rc_parse_options=:
4035 done
4036
4037 - # save modified positional parameters for caller
4038 - func_quote_for_eval ${1+"$@"}
4039 - func_parse_options_result=$func_quote_for_eval_result
4040 +
4041 + if $_G_rc_parse_options; then
4042 + # save modified positional parameters for caller
4043 + func_quote_for_eval ${1+"$@"}
4044 + func_parse_options_result=$func_quote_for_eval_result
4045 + fi
4046 +
4047 + $_G_rc_parse_options
4048 }
4049
4050
4051 @@ -1778,16 +1846,21 @@ func_validate_options ()
4052 {
4053 $debug_cmd
4054
4055 + _G_rc_validate_options=false
4056 +
4057 # Display all warnings if -W was not given.
4058 test -n "$opt_warning_types" || opt_warning_types=" $warning_categories"
4059
4060 - func_run_hooks func_validate_options ${1+"$@"}
4061 + if func_run_hooks func_validate_options ${1+"$@"}; then
4062 + # save modified positional parameters for caller
4063 + func_validate_options_result=$func_run_hooks_result
4064 + _G_rc_validate_options=:
4065 + fi
4066
4067 # Bail if the options were screwed!
4068 $exit_cmd $EXIT_FAILURE
4069
4070 - # save modified positional parameters for caller
4071 - func_validate_options_result=$func_run_hooks_result
4072 + $_G_rc_validate_options
4073 }
4074
4075
4076 @@ -2068,12 +2141,12 @@ include the following information:
4077 compiler: $LTCC
4078 compiler flags: $LTCFLAGS
4079 linker: $LD (gnu? $with_gnu_ld)
4080 - version: $progname (GNU libtool) 2.4.6
4081 + version: $progname $scriptversion Debian-2.4.6-11
4082 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q`
4083 autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q`
4084
4085 Report bugs to <bug-libtool@gnu.org>.
4086 -GNU libtool home page: <http://www.gnu.org/software/libtool/>.
4087 +GNU libtool home page: <http://www.gnu.org/s/libtool/>.
4088 General help using GNU software: <http://www.gnu.org/gethelp/>."
4089 exit 0
4090 }
4091 @@ -2124,7 +2197,7 @@ fi
4092 # a configuration failure hint, and exit.
4093 func_fatal_configuration ()
4094 {
4095 - func_fatal_error ${1+"$@"} \
4096 + func__fatal_error ${1+"$@"} \
4097 "See the $PACKAGE documentation for more information." \
4098 "Fatal configuration error."
4099 }
4100 @@ -2270,6 +2343,8 @@ libtool_options_prep ()
4101 nonopt=
4102 preserve_args=
4103
4104 + _G_rc_lt_options_prep=:
4105 +
4106 # Shorthand for --mode=foo, only valid as the first argument
4107 case $1 in
4108 clean|clea|cle|cl)
4109 @@ -2293,11 +2368,18 @@ libtool_options_prep ()
4110 uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
4111 shift; set dummy --mode uninstall ${1+"$@"}; shift
4112 ;;
4113 + *)
4114 + _G_rc_lt_options_prep=false
4115 + ;;
4116 esac
4117
4118 - # Pass back the list of options.
4119 - func_quote_for_eval ${1+"$@"}
4120 - libtool_options_prep_result=$func_quote_for_eval_result
4121 + if $_G_rc_lt_options_prep; then
4122 + # Pass back the list of options.
4123 + func_quote_for_eval ${1+"$@"}
4124 + libtool_options_prep_result=$func_quote_for_eval_result
4125 + fi
4126 +
4127 + $_G_rc_lt_options_prep
4128 }
4129 func_add_hook func_options_prep libtool_options_prep
4130
4131 @@ -2309,9 +2391,12 @@ libtool_parse_options ()
4132 {
4133 $debug_cmd
4134
4135 + _G_rc_lt_parse_options=false
4136 +
4137 # Perform our own loop to consume as many options as possible in
4138 # each iteration.
4139 while test $# -gt 0; do
4140 + _G_match_lt_parse_options=:
4141 _G_opt=$1
4142 shift
4143 case $_G_opt in
4144 @@ -2386,15 +2471,22 @@ libtool_parse_options ()
4145 func_append preserve_args " $_G_opt"
4146 ;;
4147
4148 - # An option not handled by this hook function:
4149 - *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;;
4150 + # An option not handled by this hook function:
4151 + *) set dummy "$_G_opt" ${1+"$@"} ; shift
4152 + _G_match_lt_parse_options=false
4153 + break
4154 + ;;
4155 esac
4156 + $_G_match_lt_parse_options && _G_rc_lt_parse_options=:
4157 done
4158
4159 + if $_G_rc_lt_parse_options; then
4160 + # save modified positional parameters for caller
4161 + func_quote_for_eval ${1+"$@"}
4162 + libtool_parse_options_result=$func_quote_for_eval_result
4163 + fi
4164
4165 - # save modified positional parameters for caller
4166 - func_quote_for_eval ${1+"$@"}
4167 - libtool_parse_options_result=$func_quote_for_eval_result
4168 + $_G_rc_lt_parse_options
4169 }
4170 func_add_hook func_parse_options libtool_parse_options
4171
4172 @@ -7274,10 +7366,12 @@ func_mode_link ()
4173 # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
4174 # -specs=* GCC specs files
4175 # -stdlib=* select c++ std lib with clang
4176 + # -fsanitize=* Clang/GCC memory and address sanitizer
4177 + # -fuse-ld=* Linker select flags for GCC
4178 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
4179 -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
4180 -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
4181 - -specs=*)
4182 + -specs=*|-fsanitize=*|-fuse-ld=*)
4183 func_quote_for_eval "$arg"
4184 arg=$func_quote_for_eval_result
4185 func_append compile_command " $arg"
4186 @@ -7570,7 +7664,10 @@ func_mode_link ()
4187 case $pass in
4188 dlopen) libs=$dlfiles ;;
4189 dlpreopen) libs=$dlprefiles ;;
4190 - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;;
4191 + link)
4192 + libs="$deplibs %DEPLIBS%"
4193 + test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs"
4194 + ;;
4195 esac
4196 fi
4197 if test lib,dlpreopen = "$linkmode,$pass"; then
4198 @@ -7889,19 +7986,19 @@ func_mode_link ()
4199 # It is a libtool convenience library, so add in its objects.
4200 func_append convenience " $ladir/$objdir/$old_library"
4201 func_append old_convenience " $ladir/$objdir/$old_library"
4202 + tmp_libs=
4203 + for deplib in $dependency_libs; do
4204 + deplibs="$deplib $deplibs"
4205 + if $opt_preserve_dup_deps; then
4206 + case "$tmp_libs " in
4207 + *" $deplib "*) func_append specialdeplibs " $deplib" ;;
4208 + esac
4209 + fi
4210 + func_append tmp_libs " $deplib"
4211 + done
4212 elif test prog != "$linkmode" && test lib != "$linkmode"; then
4213 func_fatal_error "'$lib' is not a convenience library"
4214 fi
4215 - tmp_libs=
4216 - for deplib in $dependency_libs; do
4217 - deplibs="$deplib $deplibs"
4218 - if $opt_preserve_dup_deps; then
4219 - case "$tmp_libs " in
4220 - *" $deplib "*) func_append specialdeplibs " $deplib" ;;
4221 - esac
4222 - fi
4223 - func_append tmp_libs " $deplib"
4224 - done
4225 continue
4226 fi # $pass = conv
4227
4228 @@ -8825,6 +8922,9 @@ func_mode_link ()
4229 revision=$number_minor
4230 lt_irix_increment=no
4231 ;;
4232 + *)
4233 + func_fatal_configuration "$modename: unknown library version type '$version_type'"
4234 + ;;
4235 esac
4236 ;;
4237 no)
4238 diff --git a/m4/libtool.m4 b/m4/libtool.m4
4239 index a644432..9d6dd9f 100644
4240 --- a/m4/libtool.m4
4241 +++ b/m4/libtool.m4
4242 @@ -728,7 +728,6 @@ _LT_CONFIG_SAVE_COMMANDS([
4243 cat <<_LT_EOF >> "$cfgfile"
4244 #! $SHELL
4245 # Generated automatically by $as_me ($PACKAGE) $VERSION
4246 -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4247 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
4248
4249 # Provide generalized library-building support services.
4250 @@ -2867,9 +2866,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4251 # before this can be enabled.
4252 hardcode_into_libs=yes
4253
4254 - # Add ABI-specific directories to the system library path.
4255 - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
4256 -
4257 # Ideally, we could use ldconfig to report *all* directores which are
4258 # searched for libraries, however this is still not possible. Aside from not
4259 # being certain /sbin/ldconfig is available, command
4260 @@ -2878,7 +2874,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4261 # appending ld.so.conf contents (and includes) to the search path.
4262 if test -f /etc/ld.so.conf; then
4263 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
4264 - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
4265 + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
4266 fi
4267
4268 # We used to test for /lib/ld.so.1 and disable shared libraries on
4269 @@ -2890,6 +2886,18 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4270 dynamic_linker='GNU/Linux ld.so'
4271 ;;
4272
4273 +netbsdelf*-gnu)
4274 + version_type=linux
4275 + need_lib_prefix=no
4276 + need_version=no
4277 + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
4278 + soname_spec='${libname}${release}${shared_ext}$major'
4279 + shlibpath_var=LD_LIBRARY_PATH
4280 + shlibpath_overrides_runpath=no
4281 + hardcode_into_libs=yes
4282 + dynamic_linker='NetBSD ld.elf_so'
4283 + ;;
4284 +
4285 netbsd*)
4286 version_type=sunos
4287 need_lib_prefix=no
4288 @@ -3549,7 +3557,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
4289 lt_cv_deplibs_check_method=pass_all
4290 ;;
4291
4292 -netbsd*)
4293 +netbsd* | netbsdelf*-gnu)
4294 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
4295 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
4296 else
4297 @@ -4055,7 +4063,8 @@ _LT_EOF
4298 if AC_TRY_EVAL(ac_compile); then
4299 # Now try to grab the symbols.
4300 nlist=conftest.nm
4301 - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
4302 + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD
4303 + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then
4304 # Try sorting and uniquifying the output.
4305 if sort "$nlist" | uniq > "$nlist"T; then
4306 mv -f "$nlist"T "$nlist"
4307 @@ -4427,7 +4436,7 @@ m4_if([$1], [CXX], [
4308 ;;
4309 esac
4310 ;;
4311 - netbsd*)
4312 + netbsd* | netbsdelf*-gnu)
4313 ;;
4314 *qnx* | *nto*)
4315 # QNX uses GNU C++, but need to define -shared option too, otherwise
4316 @@ -4695,6 +4704,12 @@ m4_if([$1], [CXX], [
4317 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
4318 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4319 ;;
4320 + # flang / f18. f95 an alias for gfortran or flang on Debian
4321 + flang* | f18* | f95*)
4322 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4323 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4324 + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
4325 + ;;
4326 # icc used to be incompatible with GCC.
4327 # ICC 10 doesn't accept -KPIC any more.
4328 icc* | ifort*)
4329 @@ -4939,6 +4954,9 @@ m4_if([$1], [CXX], [
4330 ;;
4331 esac
4332 ;;
4333 + linux* | k*bsd*-gnu | gnu*)
4334 + _LT_TAGVAR(link_all_deplibs, $1)=no
4335 + ;;
4336 *)
4337 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
4338 ;;
4339 @@ -5001,6 +5019,9 @@ dnl Note also adjust exclude_expsyms for C++ above.
4340 openbsd* | bitrig*)
4341 with_gnu_ld=no
4342 ;;
4343 + linux* | k*bsd*-gnu | gnu*)
4344 + _LT_TAGVAR(link_all_deplibs, $1)=no
4345 + ;;
4346 esac
4347
4348 _LT_TAGVAR(ld_shlibs, $1)=yes
4349 @@ -5255,7 +5276,7 @@ _LT_EOF
4350 fi
4351 ;;
4352
4353 - netbsd*)
4354 + netbsd* | netbsdelf*-gnu)
4355 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4356 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4357 wlarc=
4358 @@ -5776,6 +5797,7 @@ _LT_EOF
4359 if test yes = "$lt_cv_irix_exported_symbol"; then
4360 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
4361 fi
4362 + _LT_TAGVAR(link_all_deplibs, $1)=no
4363 else
4364 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
4365 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
4366 @@ -5797,7 +5819,7 @@ _LT_EOF
4367 esac
4368 ;;
4369
4370 - netbsd*)
4371 + netbsd* | netbsdelf*-gnu)
4372 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
4373 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
4374 else
4375 @@ -6423,7 +6445,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4376 # Commands to make compiler produce verbose output that lists
4377 # what "hidden" libraries, object files and flags are used when
4378 # linking a shared library.
4379 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
4380 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
4381
4382 else
4383 GXX=no
4384 @@ -6798,7 +6820,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4385 # explicitly linking system object files so we need to strip them
4386 # from the output so that they don't get included in the library
4387 # dependencies.
4388 - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
4389 + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
4390 ;;
4391 *)
4392 if test yes = "$GXX"; then
4393 @@ -6863,7 +6885,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4394 # explicitly linking system object files so we need to strip them
4395 # from the output so that they don't get included in the library
4396 # dependencies.
4397 - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
4398 + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
4399 ;;
4400 *)
4401 if test yes = "$GXX"; then
4402 @@ -7202,7 +7224,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4403 # Commands to make compiler produce verbose output that lists
4404 # what "hidden" libraries, object files and flags are used when
4405 # linking a shared library.
4406 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
4407 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
4408
4409 else
4410 # FIXME: insert proper C++ library support
4411 @@ -7286,7 +7308,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4412 # Commands to make compiler produce verbose output that lists
4413 # what "hidden" libraries, object files and flags are used when
4414 # linking a shared library.
4415 - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
4416 + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
4417 else
4418 # g++ 2.7 appears to require '-G' NOT '-shared' on this
4419 # platform.
4420 @@ -7297,7 +7319,7 @@ if test yes != "$_lt_caught_CXX_error"; then
4421 # Commands to make compiler produce verbose output that lists
4422 # what "hidden" libraries, object files and flags are used when
4423 # linking a shared library.
4424 - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
4425 + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"'
4426 fi
4427
4428 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir'
4429 diff --git a/src/Makefile.in b/src/Makefile.in
4430 index 3d84797..3e4ac59 100644
4431 --- a/src/Makefile.in
4432 +++ b/src/Makefile.in
4433 @@ -343,6 +343,7 @@ pdfdir = @pdfdir@
4434 prefix = @prefix@
4435 program_transform_name = @program_transform_name@
4436 psdir = @psdir@
4437 +runstatedir = @runstatedir@
4438 sbindir = @sbindir@
4439 sharedstatedir = @sharedstatedir@
4440 srcdir = @srcdir@
4441 diff --git a/src/conv/Makefile.in b/src/conv/Makefile.in
4442 index 9a88e9d..d0d9593 100644
4443 --- a/src/conv/Makefile.in
4444 +++ b/src/conv/Makefile.in
4445 @@ -341,6 +341,7 @@ pdfdir = @pdfdir@
4446 prefix = @prefix@
4447 program_transform_name = @program_transform_name@
4448 psdir = @psdir@
4449 +runstatedir = @runstatedir@
4450 sbindir = @sbindir@
4451 sharedstatedir = @sharedstatedir@
4452 srcdir = @srcdir@
4453 diff --git a/src/conv/csv/Makefile.in b/src/conv/csv/Makefile.in
4454 index 5358d0a..9c7d432 100644
4455 --- a/src/conv/csv/Makefile.in
4456 +++ b/src/conv/csv/Makefile.in
4457 @@ -337,6 +337,7 @@ pdfdir = @pdfdir@
4458 prefix = @prefix@
4459 program_transform_name = @program_transform_name@
4460 psdir = @psdir@
4461 +runstatedir = @runstatedir@
4462 sbindir = @sbindir@
4463 sharedstatedir = @sharedstatedir@
4464 srcdir = @srcdir@
4465 diff --git a/src/conv/html/Makefile.in b/src/conv/html/Makefile.in
4466 index e40de75..85113f9 100644
4467 --- a/src/conv/html/Makefile.in
4468 +++ b/src/conv/html/Makefile.in
4469 @@ -337,6 +337,7 @@ pdfdir = @pdfdir@
4470 prefix = @prefix@
4471 program_transform_name = @program_transform_name@
4472 psdir = @psdir@
4473 +runstatedir = @runstatedir@
4474 sbindir = @sbindir@
4475 sharedstatedir = @sharedstatedir@
4476 srcdir = @srcdir@
4477 diff --git a/src/conv/raw/Makefile.in b/src/conv/raw/Makefile.in
4478 index 3f57903..e21b931 100644
4479 --- a/src/conv/raw/Makefile.in
4480 +++ b/src/conv/raw/Makefile.in
4481 @@ -352,6 +352,7 @@ pdfdir = @pdfdir@
4482 prefix = @prefix@
4483 program_transform_name = @program_transform_name@
4484 psdir = @psdir@
4485 +runstatedir = @runstatedir@
4486 sbindir = @sbindir@
4487 sharedstatedir = @sharedstatedir@
4488 srcdir = @srcdir@
4489 diff --git a/src/conv/svg/Makefile.in b/src/conv/svg/Makefile.in
4490 index 1700464..05cda30 100644
4491 --- a/src/conv/svg/Makefile.in
4492 +++ b/src/conv/svg/Makefile.in
4493 @@ -337,6 +337,7 @@ pdfdir = @pdfdir@
4494 prefix = @prefix@
4495 program_transform_name = @program_transform_name@
4496 psdir = @psdir@
4497 +runstatedir = @runstatedir@
4498 sbindir = @sbindir@
4499 sharedstatedir = @sharedstatedir@
4500 srcdir = @srcdir@
4501 diff --git a/src/conv/text/Makefile.in b/src/conv/text/Makefile.in
4502 index 70861dd..ad6ce80 100644
4503 --- a/src/conv/text/Makefile.in
4504 +++ b/src/conv/text/Makefile.in
4505 @@ -352,6 +352,7 @@ pdfdir = @pdfdir@
4506 prefix = @prefix@
4507 program_transform_name = @program_transform_name@
4508 psdir = @psdir@
4509 +runstatedir = @runstatedir@
4510 sbindir = @sbindir@
4511 sharedstatedir = @sharedstatedir@
4512 srcdir = @srcdir@
4513 diff --git a/src/fuzz/Makefile.in b/src/fuzz/Makefile.in
4514 index 25faf69..e32687b 100644
4515 --- a/src/fuzz/Makefile.in
4516 +++ b/src/fuzz/Makefile.in
4517 @@ -335,6 +335,7 @@ pdfdir = @pdfdir@
4518 prefix = @prefix@
4519 program_transform_name = @program_transform_name@
4520 psdir = @psdir@
4521 +runstatedir = @runstatedir@
4522 sbindir = @sbindir@
4523 sharedstatedir = @sharedstatedir@
4524 srcdir = @srcdir@
4525 diff --git a/src/lib/Makefile.in b/src/lib/Makefile.in
4526 index 07f103c..40d9b8a 100644
4527 --- a/src/lib/Makefile.in
4528 +++ b/src/lib/Makefile.in
4529 @@ -683,6 +683,7 @@ pdfdir = @pdfdir@
4530 prefix = @prefix@
4531 program_transform_name = @program_transform_name@
4532 psdir = @psdir@
4533 +runstatedir = @runstatedir@
4534 sbindir = @sbindir@
4535 sharedstatedir = @sharedstatedir@
4536 srcdir = @srcdir@
4537 diff --git a/src/test/Makefile.in b/src/test/Makefile.in
4538 index 9d6a7ba..e3f984c 100644
4539 --- a/src/test/Makefile.in
4540 +++ b/src/test/Makefile.in
4541 @@ -633,6 +633,7 @@ pdfdir = @pdfdir@
4542 prefix = @prefix@
4543 program_transform_name = @program_transform_name@
4544 psdir = @psdir@
4545 +runstatedir = @runstatedir@
4546 sbindir = @sbindir@
4547 sharedstatedir = @sharedstatedir@
4548 srcdir = @srcdir@
4549 diff --git a/test-driver b/test-driver
4550 index 32bf39e..b8521a4 100755
4551 --- a/test-driver
4552 +++ b/test-driver
4553 @@ -1,9 +1,9 @@
4554 #! /bin/sh
4555 # test-driver - basic testsuite driver script.
4556
4557 -scriptversion=2012-06-27.10; # UTC
4558 +scriptversion=2018-03-07.03; # UTC
4559
4560 -# Copyright (C) 2011-2013 Free Software Foundation, Inc.
4561 +# Copyright (C) 2011-2018 Free Software Foundation, Inc.
4562 #
4563 # This program is free software; you can redistribute it and/or modify
4564 # it under the terms of the GNU General Public License as published by
4565 @@ -16,7 +16,7 @@ scriptversion=2012-06-27.10; # UTC
4566 # GNU General Public License for more details.
4567 #
4568 # You should have received a copy of the GNU General Public License
4569 -# along with this program. If not, see <http://www.gnu.org/licenses/>.
4570 +# along with this program. If not, see <https://www.gnu.org/licenses/>.
4571
4572 # As a special exception to the GNU General Public License, if you
4573 # distribute this file as part of a program that contains a
4574 @@ -44,13 +44,12 @@ print_usage ()
4575 Usage:
4576 test-driver --test-name=NAME --log-file=PATH --trs-file=PATH
4577 [--expect-failure={yes|no}] [--color-tests={yes|no}]
4578 - [--enable-hard-errors={yes|no}] [--] TEST-SCRIPT
4579 + [--enable-hard-errors={yes|no}] [--]
4580 + TEST-SCRIPT [TEST-SCRIPT-ARGUMENTS]
4581 The '--test-name', '--log-file' and '--trs-file' options are mandatory.
4582 END
4583 }
4584
4585 -# TODO: better error handling in option parsing (in particular, ensure
4586 -# TODO: $log_file, $trs_file and $test_name are defined).
4587 test_name= # Used for reporting.
4588 log_file= # Where to save the output of the test script.
4589 trs_file= # Where to save the metadata of the test run.
4590 @@ -69,10 +68,23 @@ while test $# -gt 0; do
4591 --enable-hard-errors) enable_hard_errors=$2; shift;;
4592 --) shift; break;;
4593 -*) usage_error "invalid option: '$1'";;
4594 + *) break;;
4595 esac
4596 shift
4597 done
4598
4599 +missing_opts=
4600 +test x"$test_name" = x && missing_opts="$missing_opts --test-name"
4601 +test x"$log_file" = x && missing_opts="$missing_opts --log-file"
4602 +test x"$trs_file" = x && missing_opts="$missing_opts --trs-file"
4603 +if test x"$missing_opts" != x; then
4604 + usage_error "the following mandatory options are missing:$missing_opts"
4605 +fi
4606 +
4607 +if test $# -eq 0; then
4608 + usage_error "missing argument"
4609 +fi
4610 +
4611 if test $color_tests = yes; then
4612 # Keep this in sync with 'lib/am/check.am:$(am__tty_colors)'.
4613 red='[0;31m' # Red.
4614 @@ -94,11 +106,14 @@ trap "st=143; $do_exit" 15
4615 # Test script is run here.
4616 "$@" >$log_file 2>&1
4617 estatus=$?
4618 +
4619 if test $enable_hard_errors = no && test $estatus -eq 99; then
4620 - estatus=1
4621 + tweaked_estatus=1
4622 +else
4623 + tweaked_estatus=$estatus
4624 fi
4625
4626 -case $estatus:$expect_failure in
4627 +case $tweaked_estatus:$expect_failure in
4628 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;;
4629 0:*) col=$grn res=PASS recheck=no gcopy=no;;
4630 77:*) col=$blu res=SKIP recheck=no gcopy=yes;;
4631 @@ -107,6 +122,12 @@ case $estatus:$expect_failure in
4632 *:*) col=$red res=FAIL recheck=yes gcopy=yes;;
4633 esac
4634
4635 +# Report the test outcome and exit status in the logs, so that one can
4636 +# know whether the test passed or failed simply by looking at the '.log'
4637 +# file, without the need of also peaking into the corresponding '.trs'
4638 +# file (automake bug#11814).
4639 +echo "$res $test_name (exit status: $estatus)" >>$log_file
4640 +
4641 # Report outcome to console.
4642 echo "${col}${res}${std}: $test_name"
4643
4644 @@ -119,9 +140,9 @@ echo ":copy-in-global-log: $gcopy" >> $trs_file
4645 # Local Variables:
4646 # mode: shell-script
4647 # sh-indentation: 2
4648 -# eval: (add-hook 'write-file-hooks 'time-stamp)
4649 +# eval: (add-hook 'before-save-hook 'time-stamp)
4650 # time-stamp-start: "scriptversion="
4651 # time-stamp-format: "%:y-%02m-%02d.%02H"
4652 -# time-stamp-time-zone: "UTC"
4653 +# time-stamp-time-zone: "UTC0"
4654 # time-stamp-end: "; # UTC"
4655 # End:
4656 --
4657 2.20.1
|