From 49e3eec6426607347f19e0c71e9047c0f56348c5 Mon Sep 17 00:00:00 2001 From: hyung-hwan Date: Wed, 1 Jan 2020 05:20:28 +0000 Subject: [PATCH] consolidated syserr_to_errnum macros to a single hawk_syserr_to_errnum() function --- hawk/Makefile.in | 24 +- hawk/ac/ar-lib | 4 +- hawk/ac/compile | 13 +- hawk/ac/config.guess | 666 +++++----- hawk/ac/config.sub | 2711 ++++++++++++++++++++-------------------- hawk/ac/depcomp | 10 +- hawk/ac/install-sh | 36 +- hawk/ac/ltmain.sh | 39 +- hawk/ac/missing | 16 +- hawk/aclocal.m4 | 191 +-- hawk/bin/Makefile.in | 31 +- hawk/configure | 265 ++-- hawk/lib/Makefile.am | 2 +- hawk/lib/Makefile.in | 332 ++--- hawk/lib/dir.c | 25 +- hawk/lib/err-prv.h | 3 + hawk/lib/err-sys.c | 198 +++ hawk/lib/err.c | 1 + hawk/lib/fio.c | 85 +- hawk/lib/gem-nwif.c | 39 +- hawk/lib/gem-nwif2.c | 23 +- hawk/lib/hawk.c | 2 +- hawk/lib/mtx.c | 33 +- hawk/lib/pio.c | 129 +- hawk/lib/sio.c | 7 +- hawk/lib/syserr.h | 253 ---- hawk/lib/tre.c | 4 +- hawk/m4/libtool.m4 | 33 +- hawk/mod/Makefile.in | 38 +- hawk/t/Makefile.in | 40 +- hawk/tools/Makefile.in | 36 +- 31 files changed, 2553 insertions(+), 2736 deletions(-) create mode 100644 hawk/lib/err-sys.c delete mode 100644 hawk/lib/syserr.h diff --git a/hawk/Makefile.in b/hawk/Makefile.in index dee05b45..4be8f379 100644 --- a/hawk/Makefile.in +++ b/hawk/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -142,7 +142,7 @@ am__recursive_targets = \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - cscope distdir distdir-am dist dist-all distcheck + cscope distdir dist dist-all distcheck am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -356,6 +356,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -393,8 +394,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -521,10 +522,7 @@ distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -rm -f cscope.out cscope.in.out cscope.po.out cscope.files -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) $(am__remove_distdir) test -d "$(distdir)" || mkdir "$(distdir)" @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ @@ -589,7 +587,7 @@ distdir-am: $(DISTFILES) ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r "$(distdir)" dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz + tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__post_remove_distdir) dist-bzip2: distdir @@ -615,7 +613,7 @@ dist-shar: distdir @echo WARNING: "Support for shar distribution archives is" \ "deprecated." >&2 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz + shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__post_remove_distdir) dist-zip: distdir @@ -633,7 +631,7 @@ dist dist-all: distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.lz*) \ @@ -643,7 +641,7 @@ distcheck: dist *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac diff --git a/hawk/ac/ar-lib b/hawk/ac/ar-lib index 0baa4f60..463b9ec0 100755 --- a/hawk/ac/ar-lib +++ b/hawk/ac/ar-lib @@ -4,7 +4,7 @@ me=ar-lib scriptversion=2012-03-01.08; # UTC -# Copyright (C) 2010-2018 Free Software Foundation, Inc. +# Copyright (C) 2010-2014 Free Software Foundation, Inc. # Written by Peter Rosin . # # This program is free software; you can redistribute it and/or modify @@ -18,7 +18,7 @@ scriptversion=2012-03-01.08; # UTC # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a diff --git a/hawk/ac/compile b/hawk/ac/compile index 99e50524..a85b723c 100755 --- a/hawk/ac/compile +++ b/hawk/ac/compile @@ -1,9 +1,9 @@ #! /bin/sh # Wrapper for compilers which do not understand '-c -o'. -scriptversion=2018-03-07.03; # UTC +scriptversion=2012-10-14.11; # UTC -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # Written by Tom Tromey . # # This program is free software; you can redistribute it and/or modify @@ -17,7 +17,7 @@ scriptversion=2018-03-07.03; # UTC # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -255,8 +255,7 @@ EOF echo "compile $scriptversion" exit $? ;; - cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \ - icl | *[/\\]icl | icl.exe | *[/\\]icl.exe ) + cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) func_cl_wrapper "$@" # Doesn't return... ;; esac @@ -340,9 +339,9 @@ exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" +# time-stamp-time-zone: "UTC" # time-stamp-end: "; # UTC" # End: diff --git a/hawk/ac/config.guess b/hawk/ac/config.guess index b33c9e89..2e9ad7fe 100755 --- a/hawk/ac/config.guess +++ b/hawk/ac/config.guess @@ -1,8 +1,8 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2018 Free Software Foundation, Inc. +# Copyright 1992-2016 Free Software Foundation, Inc. -timestamp='2018-08-29' +timestamp='2016-10-02' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -15,7 +15,7 @@ timestamp='2018-08-29' # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, see . +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -27,7 +27,7 @@ timestamp='2018-08-29' # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess # # Please send patches to . @@ -39,7 +39,7 @@ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. -Options: +Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit @@ -50,7 +50,7 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2018 Free Software Foundation, Inc. +Copyright 1992-2016 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -84,6 +84,8 @@ if test $# != 0; then exit 1 fi +trap 'exit 1' 1 2 15 + # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a @@ -94,39 +96,34 @@ fi # Portable tmp directory creation inspired by the Autoconf team. -tmp= -# shellcheck disable=SC2172 -trap 'test -z "$tmp" || rm -fr "$tmp"' 1 2 13 15 -trap 'exitcode=$?; test -z "$tmp" || rm -fr "$tmp"; exit $exitcode' 0 - -set_cc_for_build() { - : "${TMPDIR=/tmp}" - # shellcheck disable=SC2039 - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || - { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || - { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || - { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } - dummy=$tmp/dummy - case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in - ,,) echo "int x;" > "$dummy.c" - for driver in cc gcc c89 c99 ; do - if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then - CC_FOR_BUILD="$driver" - break - fi - done - if test x"$CC_FOR_BUILD" = x ; then - CC_FOR_BUILD=no_compiler_found - fi - ;; - ,,*) CC_FOR_BUILD=$CC ;; - ,*,*) CC_FOR_BUILD=$HOST_CC ;; - esac -} +set_cc_for_build=' +trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; +trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; +: ${TMPDIR=/tmp} ; + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || + { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || + { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; +dummy=$tmp/dummy ; +tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; +case $CC_FOR_BUILD,$HOST_CC,$CC in + ,,) echo "int x;" > $dummy.c ; + for c in cc gcc c89 c99 ; do + if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then + CC_FOR_BUILD="$c"; break ; + fi ; + done ; + if test x"$CC_FOR_BUILD" = x ; then + CC_FOR_BUILD=no_compiler_found ; + fi + ;; + ,,*) CC_FOR_BUILD=$CC ;; + ,*,*) CC_FOR_BUILD=$HOST_CC ;; +esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) -if test -f /.attbin/uname ; then +if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi @@ -135,14 +132,14 @@ UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown -case "$UNAME_SYSTEM" in +case "${UNAME_SYSTEM}" in Linux|GNU|GNU/*) # If the system lacks a compiler, then just pick glibc. # We could probably try harder. LIBC=gnu - set_cc_for_build - cat <<-EOF > "$dummy.c" + eval $set_cc_for_build + cat <<-EOF > $dummy.c #include #if defined(__UCLIBC__) LIBC=uclibc @@ -152,20 +149,13 @@ Linux|GNU|GNU/*) LIBC=gnu #endif EOF - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`" - - # If ldd exists, use it to detect musl libc. - if command -v ldd >/dev/null && \ - ldd --version 2>&1 | grep -q ^musl - then - LIBC=musl - fi + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` ;; esac # Note: order is significant - the case branches are not exclusive. -case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in +case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, @@ -179,30 +169,30 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ - "/sbin/$sysctl" 2>/dev/null || \ - "/usr/sbin/$sysctl" 2>/dev/null || \ + /sbin/$sysctl 2>/dev/null || \ + /usr/sbin/$sysctl 2>/dev/null || \ echo unknown)` - case "$UNAME_MACHINE_ARCH" in + case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) - arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` - endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` - machine="${arch}${endian}"-unknown + arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'` + endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'` + machine=${arch}${endian}-unknown ;; - *) machine="$UNAME_MACHINE_ARCH"-unknown ;; + *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. - case "$UNAME_MACHINE_ARCH" in + case "${UNAME_MACHINE_ARCH}" in earm*) os=netbsdelf ;; arm*|i386|m68k|ns32k|sh3*|sparc|vax) - set_cc_for_build + eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then @@ -218,10 +208,10 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in ;; esac # Determine ABI tags. - case "$UNAME_MACHINE_ARCH" in + case "${UNAME_MACHINE_ARCH}" in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' - abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` + abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"` ;; esac # The OS release @@ -229,55 +219,46 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. - case "$UNAME_VERSION" in + case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) - release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` + release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "$machine-${os}${release}${abi-}" + echo "${machine}-${os}${release}${abi}" exit ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" + echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" + echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} exit ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" - exit ;; - *:MidnightBSD:*:*) - echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" + echo ${UNAME_MACHINE_ARCH}-unknown-libertybsd${UNAME_RELEASE} exit ;; *:ekkoBSD:*:*) - echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; *:SolidBSD:*:*) - echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} exit ;; macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd"$UNAME_RELEASE" + echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) - echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit ;; *:Sortix:*:*) - echo "$UNAME_MACHINE"-unknown-sortix + echo ${UNAME_MACHINE}-unknown-sortix exit ;; - *:Redox:*:*) - echo "$UNAME_MACHINE"-unknown-redox - exit ;; - mips:OSF1:*.*) - echo mips-dec-osf1 - exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) @@ -329,19 +310,28 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. - echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`" + echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` # Reset EXIT trap before exiting to avoid spurious non-zero exit code. exitcode=$? trap '' 0 exit $exitcode ;; + Alpha\ *:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # Should we change UNAME_MACHINE based on the output of uname instead + # of the specific Alpha model? + echo alpha-pc-interix + exit ;; + 21064:Windows_NT:50:3) + echo alpha-dec-winnt3.5 + exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-amigaos + echo ${UNAME_MACHINE}-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-morphos + echo ${UNAME_MACHINE}-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition @@ -353,7 +343,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix"$UNAME_RELEASE" + echo arm-acorn-riscix${UNAME_RELEASE} exit ;; arm*:riscos:*:*|arm*:RISCOS:*:*) echo arm-unknown-riscos @@ -380,33 +370,38 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in sparc) echo sparc-icl-nx7; exit ;; esac ;; s390x:SunOS:*:*) - echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" + echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux"$UNAME_RELEASE" + echo i386-pc-auroraux${UNAME_RELEASE} exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - UNAME_REL="`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" - case `isainfo -b` in - 32) - echo i386-pc-solaris2"$UNAME_REL" - ;; - 64) - echo x86_64-pc-solaris2"$UNAME_REL" - ;; - esac + eval $set_cc_for_build + SUN_ARCH=i386 + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != no_compiler_found ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH=x86_64 + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" + echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in @@ -415,25 +410,25 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`" + echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit ;; sun3*:SunOS:*:*) - echo m68k-sun-sunos"$UNAME_RELEASE" + echo m68k-sun-sunos${UNAME_RELEASE} exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 + test "x${UNAME_RELEASE}" = x && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) - echo m68k-sun-sunos"$UNAME_RELEASE" + echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) - echo sparc-sun-sunos"$UNAME_RELEASE" + echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit ;; aushp:SunOS:*:*) - echo sparc-auspex-sunos"$UNAME_RELEASE" + echo sparc-auspex-sunos${UNAME_RELEASE} exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not @@ -444,44 +439,44 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" + echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" + echo m68k-atari-mint${UNAME_RELEASE} exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" + echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint"$UNAME_RELEASE" + echo m68k-milan-mint${UNAME_RELEASE} exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint"$UNAME_RELEASE" + echo m68k-hades-mint${UNAME_RELEASE} exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint"$UNAME_RELEASE" + echo m68k-unknown-mint${UNAME_RELEASE} exit ;; m68k:machten:*:*) - echo m68k-apple-machten"$UNAME_RELEASE" + echo m68k-apple-machten${UNAME_RELEASE} exit ;; powerpc:machten:*:*) - echo powerpc-apple-machten"$UNAME_RELEASE" + echo powerpc-apple-machten${UNAME_RELEASE} exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) - echo mips-dec-ultrix"$UNAME_RELEASE" + echo mips-dec-ultrix${UNAME_RELEASE} exit ;; VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix"$UNAME_RELEASE" + echo vax-dec-ultrix${UNAME_RELEASE} exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix"$UNAME_RELEASE" + echo clipper-intergraph-clix${UNAME_RELEASE} exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { @@ -490,23 +485,23 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); + printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); + printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); + printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && - dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`"$dummy" "$dummyarg"` && + $CC_FOR_BUILD -o $dummy $dummy.c && + dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`$dummy $dummyarg` && { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos"$UNAME_RELEASE" + echo mips-mips-riscos${UNAME_RELEASE} exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax @@ -532,17 +527,17 @@ EOF AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ] + if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then - if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \ - [ "$TARGET_BINARY_INTERFACE"x = x ] + if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ + [ ${TARGET_BINARY_INTERFACE}x = x ] then - echo m88k-dg-dgux"$UNAME_RELEASE" + echo m88k-dg-dgux${UNAME_RELEASE} else - echo m88k-dg-dguxbcs"$UNAME_RELEASE" + echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else - echo i586-dg-dgux"$UNAME_RELEASE" + echo i586-dg-dgux${UNAME_RELEASE} fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) @@ -559,7 +554,7 @@ EOF echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) - echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`" + echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id @@ -571,14 +566,14 @@ EOF if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi - echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" + echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c #include main() @@ -589,7 +584,7 @@ EOF exit(0); } EOF - if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` + if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` then echo "$SYSTEM_NAME" else @@ -603,7 +598,7 @@ EOF exit ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then + if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc @@ -612,18 +607,18 @@ EOF IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi - echo "$IBM_ARCH"-ibm-aix"$IBM_REV" + echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; - ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) + ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to + echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx @@ -638,28 +633,28 @@ EOF echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` - case "$UNAME_MACHINE" in - 9000/31?) HP_ARCH=m68000 ;; - 9000/[34]??) HP_ARCH=m68k ;; + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + case "${UNAME_MACHINE}" in + 9000/31? ) HP_ARCH=m68000 ;; + 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "$sc_cpu_version" in + case "${sc_cpu_version}" in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 - case "$sc_kernel_bits" in + case "${sc_kernel_bits}" in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi - if [ "$HP_ARCH" = "" ]; then - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" + if [ "${HP_ARCH}" = "" ]; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include @@ -692,13 +687,13 @@ EOF exit (0); } EOF - (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` + (CCOPTS="" $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac - if [ "$HP_ARCH" = hppa2.0w ] + if [ ${HP_ARCH} = hppa2.0w ] then - set_cc_for_build + eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler @@ -717,15 +712,15 @@ EOF HP_ARCH=hppa64 fi fi - echo "$HP_ARCH"-hp-hpux"$HPUX_REV" + echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit ;; ia64:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux"$HPUX_REV" + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + echo ia64-hp-hpux${HPUX_REV} exit ;; 3050*:HI-UX:*:*) - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c #include int main () @@ -750,11 +745,11 @@ EOF exit (0); } EOF - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && + $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) @@ -763,7 +758,7 @@ EOF *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) @@ -771,9 +766,9 @@ EOF exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then - echo "$UNAME_MACHINE"-unknown-osf1mk + echo ${UNAME_MACHINE}-unknown-osf1mk else - echo "$UNAME_MACHINE"-unknown-osf1 + echo ${UNAME_MACHINE}-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) @@ -798,120 +793,127 @@ EOF echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' + echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) - echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ + echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) - echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' + echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' + echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) - echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' + echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' + echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit ;; sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi"$UNAME_RELEASE" + echo sparc-unknown-bsdi${UNAME_RELEASE} exit ;; *:BSD/OS:*:*) - echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" - exit ;; - arm:FreeBSD:*:*) - UNAME_PROCESSOR=`uname -p` - set_cc_for_build - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi - else - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf - fi + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) UNAME_PROCESSOR=`/usr/bin/uname -p` - case "$UNAME_PROCESSOR" in + case ${UNAME_PROCESSOR} in amd64) - UNAME_PROCESSOR=x86_64 ;; - i386) - UNAME_PROCESSOR=i586 ;; + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac - echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" exit ;; i*:CYGWIN*:*) - echo "$UNAME_MACHINE"-pc-cygwin + echo ${UNAME_MACHINE}-pc-cygwin exit ;; *:MINGW64*:*) - echo "$UNAME_MACHINE"-pc-mingw64 + echo ${UNAME_MACHINE}-pc-mingw64 exit ;; *:MINGW*:*) - echo "$UNAME_MACHINE"-pc-mingw32 + echo ${UNAME_MACHINE}-pc-mingw32 exit ;; *:MSYS*:*) - echo "$UNAME_MACHINE"-pc-msys + echo ${UNAME_MACHINE}-pc-msys + exit ;; + i*:windows32*:*) + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) - echo "$UNAME_MACHINE"-pc-pw32 + echo ${UNAME_MACHINE}-pc-pw32 exit ;; *:Interix*:*) - case "$UNAME_MACHINE" in + case ${UNAME_MACHINE} in x86) - echo i586-pc-interix"$UNAME_RELEASE" + echo i586-pc-interix${UNAME_RELEASE} exit ;; authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix"$UNAME_RELEASE" + echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; IA64) - echo ia64-unknown-interix"$UNAME_RELEASE" + echo ia64-unknown-interix${UNAME_RELEASE} exit ;; esac ;; + [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) + echo i${UNAME_MACHINE}-pc-mks + exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; + i*:Windows_NT*:* | Pentium*:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we + # UNAME_MACHINE based on the output of uname instead of i386? + echo i586-pc-interix + exit ;; i*:UWIN*:*) - echo "$UNAME_MACHINE"-pc-uwin + echo ${UNAME_MACHINE}-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; + p*:CYGWIN*:*) + echo powerpcle-unknown-cygwin + exit ;; prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" + echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; *:GNU:*:*) # the GNU system - echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`" + echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland - echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} exit ;; - *:Minix:*:*) - echo "$UNAME_MACHINE"-unknown-minix + i*86:Minix:*:*) + echo ${UNAME_MACHINE}-pc-minix exit ;; aarch64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in @@ -925,63 +927,63 @@ EOF esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; arc:Linux:*:* | arceb:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; arm*:Linux:*:*) - set_cc_for_build + eval $set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi else - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf fi fi exit ;; avr32*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; cris:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" + echo ${UNAME_MACHINE}-axis-linux-${LIBC} exit ;; crisv32:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" + echo ${UNAME_MACHINE}-axis-linux-${LIBC} exit ;; e2k:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; frv:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; hexagon:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; i*86:Linux:*:*) - echo "$UNAME_MACHINE"-pc-linux-"$LIBC" + echo ${UNAME_MACHINE}-pc-linux-${LIBC} exit ;; ia64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; k1om:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; m32r*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; m68*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; mips:Linux:*:* | mips64:Linux:*:*) - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c #undef CPU #undef ${UNAME_MACHINE} #undef ${UNAME_MACHINE}el @@ -995,70 +997,70 @@ EOF #endif #endif EOF - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`" - test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; } + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` + test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } ;; mips64el:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; openrisc*:Linux:*:*) - echo or1k-unknown-linux-"$LIBC" + echo or1k-unknown-linux-${LIBC} exit ;; or32:Linux:*:* | or1k*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; padre:Linux:*:*) - echo sparc-unknown-linux-"$LIBC" + echo sparc-unknown-linux-${LIBC} exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-"$LIBC" + echo hppa64-unknown-linux-${LIBC} exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; - PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; - *) echo hppa-unknown-linux-"$LIBC" ;; + PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; + PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; + *) echo hppa-unknown-linux-${LIBC} ;; esac exit ;; ppc64:Linux:*:*) - echo powerpc64-unknown-linux-"$LIBC" + echo powerpc64-unknown-linux-${LIBC} exit ;; ppc:Linux:*:*) - echo powerpc-unknown-linux-"$LIBC" + echo powerpc-unknown-linux-${LIBC} exit ;; ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-"$LIBC" + echo powerpc64le-unknown-linux-${LIBC} exit ;; ppcle:Linux:*:*) - echo powerpcle-unknown-linux-"$LIBC" + echo powerpcle-unknown-linux-${LIBC} exit ;; riscv32:Linux:*:* | riscv64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; s390:Linux:*:* | s390x:Linux:*:*) - echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" + echo ${UNAME_MACHINE}-ibm-linux-${LIBC} exit ;; sh64*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; sh*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; tile*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; vax:Linux:*:*) - echo "$UNAME_MACHINE"-dec-linux-"$LIBC" + echo ${UNAME_MACHINE}-dec-linux-${LIBC} exit ;; x86_64:Linux:*:*) - echo "$UNAME_MACHINE"-pc-linux-"$LIBC" + echo ${UNAME_MACHINE}-pc-linux-${LIBC} exit ;; xtensa*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} exit ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. @@ -1072,34 +1074,34 @@ EOF # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. - echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" + echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. - echo "$UNAME_MACHINE"-pc-os2-emx + echo ${UNAME_MACHINE}-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) - echo "$UNAME_MACHINE"-unknown-stop + echo ${UNAME_MACHINE}-unknown-stop exit ;; i*86:atheos:*:*) - echo "$UNAME_MACHINE"-unknown-atheos + echo ${UNAME_MACHINE}-unknown-atheos exit ;; i*86:syllable:*:*) - echo "$UNAME_MACHINE"-pc-syllable + echo ${UNAME_MACHINE}-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos"$UNAME_RELEASE" + echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) - echo "$UNAME_MACHINE"-pc-msdosdjgpp + echo ${UNAME_MACHINE}-pc-msdosdjgpp exit ;; - i*86:*:4.*:*) - UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` + i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) + UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" + echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else - echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" + echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit ;; i*86:*:5:[678]*) @@ -1109,12 +1111,12 @@ EOF *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac - echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}" + echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 @@ -1124,9 +1126,9 @@ EOF && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 - echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" + echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else - echo "$UNAME_MACHINE"-pc-sysv32 + echo ${UNAME_MACHINE}-pc-sysv32 fi exit ;; pc:*:*:*) @@ -1146,9 +1148,9 @@ EOF exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 + echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 + echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) @@ -1168,9 +1170,9 @@ EOF test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; @@ -1179,28 +1181,28 @@ EOF test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos"$UNAME_RELEASE" + echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos"$UNAME_RELEASE" + echo sparc-unknown-lynxos${UNAME_RELEASE} exit ;; rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos"$UNAME_RELEASE" + echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos"$UNAME_RELEASE" + echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv"$UNAME_RELEASE" + echo mips-dde-sysv${UNAME_RELEASE} exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 @@ -1211,7 +1213,7 @@ EOF *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo "$UNAME_MACHINE"-sni-sysv4 + echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi @@ -1231,23 +1233,23 @@ EOF exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. - echo "$UNAME_MACHINE"-stratus-vos + echo ${UNAME_MACHINE}-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) - echo m68k-apple-aux"$UNAME_RELEASE" + echo m68k-apple-aux${UNAME_RELEASE} exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv"$UNAME_RELEASE" + echo mips-nec-sysv${UNAME_RELEASE} else - echo mips-unknown-sysv"$UNAME_RELEASE" + echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. @@ -1266,56 +1268,49 @@ EOF echo x86_64-unknown-haiku exit ;; SX-4:SUPER-UX:*:*) - echo sx4-nec-superux"$UNAME_RELEASE" + echo sx4-nec-superux${UNAME_RELEASE} exit ;; SX-5:SUPER-UX:*:*) - echo sx5-nec-superux"$UNAME_RELEASE" + echo sx5-nec-superux${UNAME_RELEASE} exit ;; SX-6:SUPER-UX:*:*) - echo sx6-nec-superux"$UNAME_RELEASE" + echo sx6-nec-superux${UNAME_RELEASE} exit ;; SX-7:SUPER-UX:*:*) - echo sx7-nec-superux"$UNAME_RELEASE" + echo sx7-nec-superux${UNAME_RELEASE} exit ;; SX-8:SUPER-UX:*:*) - echo sx8-nec-superux"$UNAME_RELEASE" + echo sx8-nec-superux${UNAME_RELEASE} exit ;; SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux"$UNAME_RELEASE" + echo sx8r-nec-superux${UNAME_RELEASE} exit ;; SX-ACE:SUPER-UX:*:*) - echo sxace-nec-superux"$UNAME_RELEASE" + echo sxace-nec-superux${UNAME_RELEASE} exit ;; Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody"$UNAME_RELEASE" + echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; *:Rhapsody:*:*) - echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown - set_cc_for_build + eval $set_cc_for_build if test "$UNAME_PROCESSOR" = unknown ; then UNAME_PROCESSOR=powerpc fi - if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then + if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then if [ "$CC_FOR_BUILD" != no_compiler_found ]; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null then case $UNAME_PROCESSOR in i386) UNAME_PROCESSOR=x86_64 ;; powerpc) UNAME_PROCESSOR=powerpc64 ;; esac fi - # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc - if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_PPC >/dev/null - then - UNAME_PROCESSOR=powerpc - fi fi elif test "$UNAME_PROCESSOR" = i386 ; then # Avoid executing cc on OS X 10.9, as it ships with a stub @@ -1326,7 +1321,7 @@ EOF # that Apple uses in portable devices. UNAME_PROCESSOR=x86_64 fi - echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" + echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` @@ -1334,25 +1329,19 @@ EOF UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi - echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" + echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; - NEO-*:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk"$UNAME_RELEASE" + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} exit ;; NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk"$UNAME_RELEASE" + echo nse-tandem-nsk${UNAME_RELEASE} exit ;; - NSR-*:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk"$UNAME_RELEASE" - exit ;; - NSV-*:NONSTOP_KERNEL:*:*) - echo nsv-tandem-nsk"$UNAME_RELEASE" - exit ;; - NSX-*:NONSTOP_KERNEL:*:*) - echo nsx-tandem-nsk"$UNAME_RELEASE" + NSR-?:NONSTOP_KERNEL:*:*) + echo nsr-tandem-nsk${UNAME_RELEASE} exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux @@ -1361,19 +1350,18 @@ EOF echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) - echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" + echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. - # shellcheck disable=SC2154 if test "$cputype" = 386; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi - echo "$UNAME_MACHINE"-unknown-plan9 + echo ${UNAME_MACHINE}-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 @@ -1394,14 +1382,14 @@ EOF echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) - echo mips-sei-seiux"$UNAME_RELEASE" + echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) - echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" + echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "$UNAME_MACHINE" in + case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; @@ -1410,44 +1398,32 @@ EOF echo i386-pc-xenix exit ;; i*86:skyos:*:*) - echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`" + echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE} | sed -e 's/ .*$//'` exit ;; i*86:rdos:*:*) - echo "$UNAME_MACHINE"-pc-rdos + echo ${UNAME_MACHINE}-pc-rdos exit ;; i*86:AROS:*:*) - echo "$UNAME_MACHINE"-pc-aros + echo ${UNAME_MACHINE}-pc-aros exit ;; x86_64:VMkernel:*:*) - echo "$UNAME_MACHINE"-unknown-esx + echo ${UNAME_MACHINE}-unknown-esx exit ;; amd64:Isilon\ OneFS:*:*) echo x86_64-unknown-onefs exit ;; esac -echo "$0: unable to guess system type" >&2 - -case "$UNAME_MACHINE:$UNAME_SYSTEM" in - mips:Linux | mips64:Linux) - # If we got here on MIPS GNU/Linux, output extra information. - cat >&2 <&2 </dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` -UNAME_MACHINE = "$UNAME_MACHINE" -UNAME_RELEASE = "$UNAME_RELEASE" -UNAME_SYSTEM = "$UNAME_SYSTEM" -UNAME_VERSION = "$UNAME_VERSION" +UNAME_MACHINE = ${UNAME_MACHINE} +UNAME_RELEASE = ${UNAME_RELEASE} +UNAME_SYSTEM = ${UNAME_SYSTEM} +UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" diff --git a/hawk/ac/config.sub b/hawk/ac/config.sub index b51fb8cd..dd2ca93c 100755 --- a/hawk/ac/config.sub +++ b/hawk/ac/config.sub @@ -1,8 +1,8 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright 1992-2018 Free Software Foundation, Inc. +# Copyright 1992-2016 Free Software Foundation, Inc. -timestamp='2018-08-29' +timestamp='2016-11-04' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -15,7 +15,7 @@ timestamp='2018-08-29' # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, see . +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -33,7 +33,7 @@ timestamp='2018-08-29' # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases @@ -57,7 +57,7 @@ Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS Canonicalize a configuration name. -Options: +Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit @@ -67,7 +67,7 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright 1992-2018 Free Software Foundation, Inc. +Copyright 1992-2016 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -94,7 +94,7 @@ while test $# -gt 0 ; do *local*) # First pass through any local machine types. - echo "$1" + echo $1 exit ;; * ) @@ -110,1159 +110,1244 @@ case $# in exit 1;; esac -# Split fields of configuration type -IFS="-" read -r field1 field2 field3 field4 <&2 - exit 1 +### Let's recognize common machines as not being operating systems so +### that things like config.sub decstation-3100 work. We also +### recognize some manufacturers as not being operating systems, so we +### can provide default operating systems below. +case $os in + -sun*os*) + # Prevent following clause from handling this invalid input. ;; - *-*-*-*) - basic_machine=$field1-$field2 - os=$field3-$field4 + -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ + -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ + -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ + -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ + -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ + -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ + -apple | -axis | -knuth | -cray | -microblaze*) + os= + basic_machine=$1 ;; - *-*-*) - # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two - # parts - maybe_os=$field2-$field3 - case $maybe_os in - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \ - | linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \ - | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ - | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ - | storm-chaos* | os2-emx* | rtmk-nova*) - basic_machine=$field1 - os=$maybe_os - ;; - android-linux) - basic_machine=$field1-unknown - os=linux-android - ;; - *) - basic_machine=$field1-$field2 - os=$field3 - ;; - esac + -bluegene*) + os=-cnk ;; - *-*) - # A lone config we happen to match not fitting any patern - case $field1-$field2 in - decstation-3100) - basic_machine=mips-dec - os= - ;; - *-*) - # Second component is usually, but not always the OS - case $field2 in - # Prevent following clause from handling this valid os - sun*os*) - basic_machine=$field1 - os=$field2 - ;; - # Manufacturers - dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ - | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ - | unicom* | ibm* | next | hp | isi* | apollo | altos* \ - | convergent* | ncr* | news | 32* | 3600* | 3100* \ - | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ - | ultra | tti* | harris | dolphin | highlevel | gould \ - | cbm | ns | masscomp | apple | axis | knuth | cray \ - | microblaze* | sim | cisco \ - | oki | wec | wrs | winbond) - basic_machine=$field1-$field2 - os= - ;; - *) - basic_machine=$field1 - os=$field2 - ;; - esac - ;; - esac + -sim | -cisco | -oki | -wec | -winbond) + os= + basic_machine=$1 ;; - *) - # Convert single-component short-hands not valid as part of - # multi-component configurations. - case $field1 in - 386bsd) - basic_machine=i386-pc - os=bsd - ;; - a29khif) - basic_machine=a29k-amd - os=udi - ;; - adobe68k) - basic_machine=m68010-adobe - os=scout - ;; - alliant) - basic_machine=fx80-alliant - os= - ;; - altos | altos3068) - basic_machine=m68k-altos - os= - ;; - am29k) - basic_machine=a29k-none - os=bsd - ;; - amdahl) - basic_machine=580-amdahl - os=sysv - ;; - amiga) - basic_machine=m68k-unknown - os= - ;; - amigaos | amigados) - basic_machine=m68k-unknown - os=amigaos - ;; - amigaunix | amix) - basic_machine=m68k-unknown - os=sysv4 - ;; - apollo68) - basic_machine=m68k-apollo - os=sysv - ;; - apollo68bsd) - basic_machine=m68k-apollo - os=bsd - ;; - aros) - basic_machine=i386-pc - os=aros - ;; - aux) - basic_machine=m68k-apple - os=aux - ;; - balance) - basic_machine=ns32k-sequent - os=dynix - ;; - blackfin) - basic_machine=bfin-unknown - os=linux - ;; - cegcc) - basic_machine=arm-unknown - os=cegcc - ;; - convex-c1) - basic_machine=c1-convex - os=bsd - ;; - convex-c2) - basic_machine=c2-convex - os=bsd - ;; - convex-c32) - basic_machine=c32-convex - os=bsd - ;; - convex-c34) - basic_machine=c34-convex - os=bsd - ;; - convex-c38) - basic_machine=c38-convex - os=bsd - ;; - cray) - basic_machine=j90-cray - os=unicos - ;; - crds | unos) - basic_machine=m68k-crds - os= - ;; - da30) - basic_machine=m68k-da30 - os= - ;; - decstation | pmax | pmin | dec3100 | decstatn) - basic_machine=mips-dec - os= - ;; - delta88) - basic_machine=m88k-motorola - os=sysv3 - ;; - dicos) - basic_machine=i686-pc - os=dicos - ;; - djgpp) - basic_machine=i586-pc - os=msdosdjgpp - ;; - ebmon29k) - basic_machine=a29k-amd - os=ebmon - ;; - es1800 | OSE68k | ose68k | ose | OSE) - basic_machine=m68k-ericsson - os=ose - ;; - gmicro) - basic_machine=tron-gmicro - os=sysv - ;; - go32) - basic_machine=i386-pc - os=go32 - ;; - h8300hms) - basic_machine=h8300-hitachi - os=hms - ;; - h8300xray) - basic_machine=h8300-hitachi - os=xray - ;; - h8500hms) - basic_machine=h8500-hitachi - os=hms - ;; - harris) - basic_machine=m88k-harris - os=sysv3 - ;; - hp300) - basic_machine=m68k-hp - ;; - hp300bsd) - basic_machine=m68k-hp - os=bsd - ;; - hp300hpux) - basic_machine=m68k-hp - os=hpux - ;; - hppaosf) - basic_machine=hppa1.1-hp - os=osf - ;; - hppro) - basic_machine=hppa1.1-hp - os=proelf - ;; - i386mach) - basic_machine=i386-mach - os=mach - ;; - vsta) - basic_machine=i386-pc - os=vsta - ;; - isi68 | isi) - basic_machine=m68k-isi - os=sysv - ;; - m68knommu) - basic_machine=m68k-unknown - os=linux - ;; - magnum | m3230) - basic_machine=mips-mips - os=sysv - ;; - merlin) - basic_machine=ns32k-utek - os=sysv - ;; - mingw64) - basic_machine=x86_64-pc - os=mingw64 - ;; - mingw32) - basic_machine=i686-pc - os=mingw32 - ;; - mingw32ce) - basic_machine=arm-unknown - os=mingw32ce - ;; - monitor) - basic_machine=m68k-rom68k - os=coff - ;; - morphos) - basic_machine=powerpc-unknown - os=morphos - ;; - moxiebox) - basic_machine=moxie-unknown - os=moxiebox - ;; - msdos) - basic_machine=i386-pc - os=msdos - ;; - msys) - basic_machine=i686-pc - os=msys - ;; - mvs) - basic_machine=i370-ibm - os=mvs - ;; - nacl) - basic_machine=le32-unknown - os=nacl - ;; - ncr3000) - basic_machine=i486-ncr - os=sysv4 - ;; - netbsd386) - basic_machine=i386-pc - os=netbsd - ;; - netwinder) - basic_machine=armv4l-rebel - os=linux - ;; - news | news700 | news800 | news900) - basic_machine=m68k-sony - os=newsos - ;; - news1000) - basic_machine=m68030-sony - os=newsos - ;; - necv70) - basic_machine=v70-nec - os=sysv - ;; - nh3000) - basic_machine=m68k-harris - os=cxux - ;; - nh[45]000) - basic_machine=m88k-harris - os=cxux - ;; - nindy960) - basic_machine=i960-intel - os=nindy - ;; - mon960) - basic_machine=i960-intel - os=mon960 - ;; - nonstopux) - basic_machine=mips-compaq - os=nonstopux - ;; - os400) - basic_machine=powerpc-ibm - os=os400 - ;; - OSE68000 | ose68000) - basic_machine=m68000-ericsson - os=ose - ;; - os68k) - basic_machine=m68k-none - os=os68k - ;; - paragon) - basic_machine=i860-intel - os=osf - ;; - parisc) - basic_machine=hppa-unknown - os=linux - ;; - pw32) - basic_machine=i586-unknown - os=pw32 - ;; - rdos | rdos64) - basic_machine=x86_64-pc - os=rdos - ;; - rdos32) - basic_machine=i386-pc - os=rdos - ;; - rom68k) - basic_machine=m68k-rom68k - os=coff - ;; - sa29200) - basic_machine=a29k-amd - os=udi - ;; - sei) - basic_machine=mips-sei - os=seiux - ;; - sequent) - basic_machine=i386-sequent - os= - ;; - sps7) - basic_machine=m68k-bull - os=sysv2 - ;; - st2000) - basic_machine=m68k-tandem - os= - ;; - stratus) - basic_machine=i860-stratus - os=sysv4 - ;; - sun2) - basic_machine=m68000-sun - os= - ;; - sun2os3) - basic_machine=m68000-sun - os=sunos3 - ;; - sun2os4) - basic_machine=m68000-sun - os=sunos4 - ;; - sun3) - basic_machine=m68k-sun - os= - ;; - sun3os3) - basic_machine=m68k-sun - os=sunos3 - ;; - sun3os4) - basic_machine=m68k-sun - os=sunos4 - ;; - sun4) - basic_machine=sparc-sun - os= - ;; - sun4os3) - basic_machine=sparc-sun - os=sunos3 - ;; - sun4os4) - basic_machine=sparc-sun - os=sunos4 - ;; - sun4sol2) - basic_machine=sparc-sun - os=solaris2 - ;; - sun386 | sun386i | roadrunner) - basic_machine=i386-sun - os= - ;; - sv1) - basic_machine=sv1-cray - os=unicos - ;; - symmetry) - basic_machine=i386-sequent - os=dynix - ;; - t3e) - basic_machine=alphaev5-cray - os=unicos - ;; - t90) - basic_machine=t90-cray - os=unicos - ;; - toad1) - basic_machine=pdp10-xkl - os=tops20 - ;; - tpf) - basic_machine=s390x-ibm - os=tpf - ;; - udi29k) - basic_machine=a29k-amd - os=udi - ;; - ultra3) - basic_machine=a29k-nyu - os=sym1 - ;; - v810 | necv810) - basic_machine=v810-nec - os=none - ;; - vaxv) - basic_machine=vax-dec - os=sysv - ;; - vms) - basic_machine=vax-dec - os=vms - ;; - vxworks960) - basic_machine=i960-wrs - os=vxworks - ;; - vxworks68) - basic_machine=m68k-wrs - os=vxworks - ;; - vxworks29k) - basic_machine=a29k-wrs - os=vxworks - ;; - xbox) - basic_machine=i686-pc - os=mingw32 - ;; - ymp) - basic_machine=ymp-cray - os=unicos - ;; - *) - basic_machine=$1 - os= - ;; - esac + -scout) + ;; + -wrs) + os=-vxworks + basic_machine=$1 + ;; + -chorusos*) + os=-chorusos + basic_machine=$1 + ;; + -chorusrdb) + os=-chorusrdb + basic_machine=$1 + ;; + -hiux*) + os=-hiuxwe2 + ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5) + os=-sco3.2v5 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco4) + os=-sco3.2v4 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2.[4-9]*) + os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2v[4-9]*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco*) + os=-sco3.2v2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -udk*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -isc) + os=-isc2.2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -clix*) + basic_machine=clipper-intergraph + ;; + -isc*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -lynx*178) + os=-lynxos178 + ;; + -lynx*5) + os=-lynxos5 + ;; + -lynx*) + os=-lynxos + ;; + -ptx*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` + ;; + -windowsnt*) + os=`echo $os | sed -e 's/windowsnt/winnt/'` + ;; + -psos*) + os=-psos + ;; + -mint | -mint[0-9]*) + basic_machine=m68k-atari + os=-mint ;; esac -# Decode 1-component or ad-hoc basic machines +# Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in - # Here we handle the default manufacturer of certain CPU types. It is in - # some cases the only manufacturer, in others, it is the most popular. - w89k) - cpu=hppa1.1 - vendor=winbond + # Recognize the basic CPU types without company name. + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ + | aarch64 | aarch64_be \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ + | arc | arceb \ + | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ + | avr | avr32 \ + | ba \ + | be32 | be64 \ + | bfin \ + | c4x | c8051 | clipper \ + | d10v | d30v | dlx | dsp16xx \ + | e2k | epiphany \ + | fido | fr30 | frv | ft32 \ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | hexagon \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ + | k1om \ + | le32 | le64 \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ + | mips64octeon | mips64octeonel \ + | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ + | mips64vr4100 | mips64vr4100el \ + | mips64vr4300 | mips64vr4300el \ + | mips64vr5000 | mips64vr5000el \ + | mips64vr5900 | mips64vr5900el \ + | mipsisa32 | mipsisa32el \ + | mipsisa32r2 | mipsisa32r2el \ + | mipsisa32r6 | mipsisa32r6el \ + | mipsisa64 | mipsisa64el \ + | mipsisa64r2 | mipsisa64r2el \ + | mipsisa64r6 | mipsisa64r6el \ + | mipsisa64sb1 | mipsisa64sb1el \ + | mipsisa64sr71k | mipsisa64sr71kel \ + | mipsr5900 | mipsr5900el \ + | mipstx39 | mipstx39el \ + | mn10200 | mn10300 \ + | moxie \ + | mt \ + | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 | nios2eb | nios2el \ + | ns16k | ns32k \ + | open8 | or1k | or1knd | or32 \ + | pdp10 | pdp11 | pj | pjl \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ + | pru \ + | pyramid \ + | riscv32 | riscv64 \ + | rl78 | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ + | visium \ + | we32k \ + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) + basic_machine=$basic_machine-unknown ;; - op50n) - cpu=hppa1.1 - vendor=oki + c54x) + basic_machine=tic54x-unknown ;; - op60c) - cpu=hppa1.1 - vendor=oki + c55x) + basic_machine=tic55x-unknown ;; - ibm*) - cpu=i370 - vendor=ibm - ;; - orion105) - cpu=clipper - vendor=highlevel - ;; - mac | mpw | mac-mpw) - cpu=m68k - vendor=apple - ;; - pmac | pmac-mpw) - cpu=powerpc - vendor=apple - ;; - - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) - cpu=m68000 - vendor=att - ;; - 3b*) - cpu=we32k - vendor=att - ;; - bluegene*) - cpu=powerpc - vendor=ibm - os=cnk - ;; - decsystem10* | dec10*) - cpu=pdp10 - vendor=dec - os=tops10 - ;; - decsystem20* | dec20*) - cpu=pdp10 - vendor=dec - os=tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) - cpu=m68k - vendor=motorola - ;; - dpx2*) - cpu=m68k - vendor=bull - os=sysv3 - ;; - encore | umax | mmax) - cpu=ns32k - vendor=encore - ;; - elxsi) - cpu=elxsi - vendor=elxsi - os=${os:-bsd} - ;; - fx2800) - cpu=i860 - vendor=alliant - ;; - genix) - cpu=ns32k - vendor=ns - ;; - h3050r* | hiux*) - cpu=hppa1.1 - vendor=hitachi - os=hiuxwe2 - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) - cpu=m68000 - vendor=hp - ;; - hp9k3[2-9][0-9]) - cpu=m68k - vendor=hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) - cpu=hppa1.1 - vendor=hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) - # FIXME: really hppa2.0-hp - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - i*86v32) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - os=sysv32 - ;; - i*86v4*) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - os=sysv4 - ;; - i*86v) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - os=sysv - ;; - i*86sol2) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - os=solaris2 - ;; - j90 | j90-cray) - cpu=j90 - vendor=cray - os=${os:-unicos} - ;; - iris | iris4d) - cpu=mips - vendor=sgi - case $os in - irix*) - ;; - *) - os=irix4 - ;; - esac - ;; - miniframe) - cpu=m68000 - vendor=convergent - ;; - *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) - cpu=m68k - vendor=atari - os=mint - ;; - news-3600 | risc-news) - cpu=mips - vendor=sony - os=newsos - ;; - next | m*-next) - cpu=m68k - vendor=next - case $os in - nextstep* ) - ;; - ns2*) - os=nextstep2 - ;; - *) - os=nextstep3 - ;; - esac - ;; - np1) - cpu=np1 - vendor=gould - ;; - op50n-* | op60c-*) - cpu=hppa1.1 - vendor=oki - os=proelf - ;; - pa-hitachi) - cpu=hppa1.1 - vendor=hitachi - os=hiuxwe2 - ;; - pbd) - cpu=sparc - vendor=tti - ;; - pbb) - cpu=m68k - vendor=tti - ;; - pc532) - cpu=ns32k - vendor=pc532 - ;; - pn) - cpu=pn - vendor=gould - ;; - power) - cpu=power - vendor=ibm - ;; - ps2) - cpu=i386 - vendor=ibm - ;; - rm[46]00) - cpu=mips - vendor=siemens - ;; - rtpc | rtpc-*) - cpu=romp - vendor=ibm - ;; - sde) - cpu=mipsisa32 - vendor=sde - os=${os:-elf} - ;; - simso-wrs) - cpu=sparclite - vendor=wrs - os=vxworks - ;; - tower | tower-32) - cpu=m68k - vendor=ncr - ;; - vpp*|vx|vx-*) - cpu=f301 - vendor=fujitsu - ;; - w65) - cpu=w65 - vendor=wdc - ;; - w89k-*) - cpu=hppa1.1 - vendor=winbond - os=proelf - ;; - none) - cpu=none - vendor=none + c6x) + basic_machine=tic6x-unknown ;; leon|leon[3-9]) - cpu=sparc - vendor=$basic_machine + basic_machine=sparc-$basic_machine ;; - leon-*|leon[3-9]-*) - cpu=sparc - vendor=`echo "$basic_machine" | sed 's/-.*//'` + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip) + basic_machine=$basic_machine-unknown + os=-none + ;; + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) + ;; + ms1) + basic_machine=mt-unknown ;; - *-*) - IFS="-" read -r cpu vendor <&2 + exit 1 ;; - # These rules are duplicated from below for sake of the special case above; - # i.e. things that normalized to x86 arches should also default to "pc" - pc98) - cpu=i386 - vendor=pc + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ + | aarch64-* | aarch64_be-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ + | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ + | avr-* | avr32-* \ + | ba-* \ + | be32-* | be64-* \ + | bfin-* | bs2000-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ + | c8051-* | clipper-* | craynv-* | cydra-* \ + | d10v-* | d30v-* | dlx-* \ + | e2k-* | elxsi-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ + | h8300-* | h8500-* \ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | hexagon-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ + | k1om-* \ + | le32-* | le64-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ + | microblaze-* | microblazeel-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ + | mips16-* \ + | mips64-* | mips64el-* \ + | mips64octeon-* | mips64octeonel-* \ + | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ + | mips64vr4100-* | mips64vr4100el-* \ + | mips64vr4300-* | mips64vr4300el-* \ + | mips64vr5000-* | mips64vr5000el-* \ + | mips64vr5900-* | mips64vr5900el-* \ + | mipsisa32-* | mipsisa32el-* \ + | mipsisa32r2-* | mipsisa32r2el-* \ + | mipsisa32r6-* | mipsisa32r6el-* \ + | mipsisa64-* | mipsisa64el-* \ + | mipsisa64r2-* | mipsisa64r2el-* \ + | mipsisa64r6-* | mipsisa64r6el-* \ + | mipsisa64sb1-* | mipsisa64sb1el-* \ + | mipsisa64sr71k-* | mipsisa64sr71kel-* \ + | mipsr5900-* | mipsr5900el-* \ + | mipstx39-* | mipstx39el-* \ + | mmix-* \ + | mt-* \ + | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* | nios2eb-* | nios2el-* \ + | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ + | or1k*-* \ + | orion-* \ + | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ + | pru-* \ + | pyramid-* \ + | riscv32-* | riscv64-* \ + | rl78-* | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ + | sparclite-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \ + | tahoe-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ + | tron-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ + | visium-* \ + | we32k-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ + | ymp-* \ + | z8k-* | z80-*) ;; - x64 | amd64) - cpu=x86_64 - vendor=pc + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown ;; - # Recognize the basic CPU types without company name. - *) - cpu=$basic_machine - vendor=unknown + # Recognize the various machine names and aliases which stand + # for a CPU type and a company and sometimes even an OS. + 386bsd) + basic_machine=i386-unknown + os=-bsd ;; -esac - -unset -v basic_machine - -# Decode basic machines in the full and proper CPU-Company form. -case $cpu-$vendor in - # Here we handle the default manufacturer of certain CPU types in cannonical form. It is in - # some cases the only manufacturer, in others, it is the most popular. - craynv-unknown) - vendor=cray - os=${os:-unicosmp} + 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) + basic_machine=m68000-att ;; - c90-unknown | c90-cray) - vendor=cray - os=${os:-unicos} + 3b*) + basic_machine=we32k-att ;; - fx80-unknown) - vendor=alliant + a29khif) + basic_machine=a29k-amd + os=-udi ;; - romp-unknown) - vendor=ibm + abacus) + basic_machine=abacus-unknown ;; - mmix-unknown) - vendor=knuth + adobe68k) + basic_machine=m68010-adobe + os=-scout ;; - microblaze-unknown | microblazeel-unknown) - vendor=xilinx + alliant | fx80) + basic_machine=fx80-alliant ;; - rs6000-unknown) - vendor=ibm + altos | altos3068) + basic_machine=m68k-altos ;; - vax-unknown) - vendor=dec + am29k) + basic_machine=a29k-none + os=-bsd ;; - pdp11-unknown) - vendor=dec + amd64) + basic_machine=x86_64-pc ;; - we32k-unknown) - vendor=att - ;; - cydra-unknown) - vendor=cydrome - ;; - i370-ibm*) - vendor=ibm - ;; - orion-unknown) - vendor=highlevel - ;; - xps-unknown | xps100-unknown) - cpu=xps100 - vendor=honeywell - ;; - - # Here we normalize CPU types with a missing or matching vendor - dpx20-unknown | dpx20-bull) - cpu=rs6000 - vendor=bull - os=${os:-bosx} - ;; - - # Here we normalize CPU types irrespective of the vendor amd64-*) - cpu=x86_64 + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + amdahl) + basic_machine=580-amdahl + os=-sysv + ;; + amiga | amiga-*) + basic_machine=m68k-unknown + ;; + amigaos | amigados) + basic_machine=m68k-unknown + os=-amigaos + ;; + amigaunix | amix) + basic_machine=m68k-unknown + os=-sysv4 + ;; + apollo68) + basic_machine=m68k-apollo + os=-sysv + ;; + apollo68bsd) + basic_machine=m68k-apollo + os=-bsd + ;; + aros) + basic_machine=i386-pc + os=-aros + ;; + asmjs) + basic_machine=asmjs-unknown + ;; + aux) + basic_machine=m68k-apple + os=-aux + ;; + balance) + basic_machine=ns32k-sequent + os=-dynix + ;; + blackfin) + basic_machine=bfin-unknown + os=-linux ;; blackfin-*) - cpu=bfin - os=linux + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk ;; c54x-*) - cpu=tic54x + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` ;; c55x-*) - cpu=tic55x + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` ;; c6x-*) - cpu=tic6x + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` ;; - e500v[12]-*) - cpu=powerpc + c90) + basic_machine=c90-cray + os=-unicos + ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; + convex-c1) + basic_machine=c1-convex + os=-bsd + ;; + convex-c2) + basic_machine=c2-convex + os=-bsd + ;; + convex-c32) + basic_machine=c32-convex + os=-bsd + ;; + convex-c34) + basic_machine=c34-convex + os=-bsd + ;; + convex-c38) + basic_machine=c38-convex + os=-bsd + ;; + cray | j90) + basic_machine=j90-cray + os=-unicos + ;; + craynv) + basic_machine=craynv-cray + os=-unicosmp + ;; + cr16 | cr16-*) + basic_machine=cr16-unknown + os=-elf + ;; + crds | unos) + basic_machine=m68k-crds + ;; + crisv32 | crisv32-* | etraxfs*) + basic_machine=crisv32-axis + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; + crx) + basic_machine=crx-unknown + os=-elf + ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; + decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) + basic_machine=mips-dec + ;; + decsystem10* | dec10*) + basic_machine=pdp10-dec + os=-tops10 + ;; + decsystem20* | dec20*) + basic_machine=pdp10-dec + os=-tops20 + ;; + delta | 3300 | motorola-3300 | motorola-delta \ + | 3300-motorola | delta-motorola) + basic_machine=m68k-motorola + ;; + delta88) + basic_machine=m88k-motorola + os=-sysv3 + ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; + djgpp) + basic_machine=i586-pc + os=-msdosdjgpp + ;; + dpx20 | dpx20-*) + basic_machine=rs6000-bull + os=-bosx + ;; + dpx2* | dpx2*-bull) + basic_machine=m68k-bull + os=-sysv3 + ;; + e500v[12]) + basic_machine=powerpc-unknown os=$os"spe" ;; - mips3*-*) - cpu=mips64 + e500v[12]-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + os=$os"spe" ;; - ms1-*) - cpu=mt + ebmon29k) + basic_machine=a29k-amd + os=-ebmon + ;; + elxsi) + basic_machine=elxsi-elxsi + os=-bsd + ;; + encore | umax | mmax) + basic_machine=ns32k-encore + ;; + es1800 | OSE68k | ose68k | ose | OSE) + basic_machine=m68k-ericsson + os=-ose + ;; + fx2800) + basic_machine=i860-alliant + ;; + genix) + basic_machine=ns32k-ns + ;; + gmicro) + basic_machine=tron-gmicro + os=-sysv + ;; + go32) + basic_machine=i386-pc + os=-go32 + ;; + h3050r* | hiux*) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + h8300hms) + basic_machine=h8300-hitachi + os=-hms + ;; + h8300xray) + basic_machine=h8300-hitachi + os=-xray + ;; + h8500hms) + basic_machine=h8500-hitachi + os=-hms + ;; + harris) + basic_machine=m88k-harris + os=-sysv3 + ;; + hp300-*) + basic_machine=m68k-hp + ;; + hp300bsd) + basic_machine=m68k-hp + os=-bsd + ;; + hp300hpux) + basic_machine=m68k-hp + os=-hpux + ;; + hp3k9[0-9][0-9] | hp9[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k2[0-9][0-9] | hp9k31[0-9]) + basic_machine=m68000-hp + ;; + hp9k3[2-9][0-9]) + basic_machine=m68k-hp + ;; + hp9k6[0-9][0-9] | hp6[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k7[0-79][0-9] | hp7[0-79][0-9]) + basic_machine=hppa1.1-hp + ;; + hp9k78[0-9] | hp78[0-9]) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][13679] | hp8[0-9][13679]) + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][0-9] | hp8[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hppa-next) + os=-nextstep3 + ;; + hppaosf) + basic_machine=hppa1.1-hp + os=-osf + ;; + hppro) + basic_machine=hppa1.1-hp + os=-proelf + ;; + i370-ibm* | ibm*) + basic_machine=i370-ibm + ;; + i*86v32) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv32 + ;; + i*86v4*) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv4 + ;; + i*86v) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv + ;; + i*86sol2) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-solaris2 + ;; + i386mach) + basic_machine=i386-mach + os=-mach + ;; + i386-vsta | vsta) + basic_machine=i386-unknown + os=-vsta + ;; + iris | iris4d) + basic_machine=mips-sgi + case $os in + -irix*) + ;; + *) + os=-irix4 + ;; + esac + ;; + isi68 | isi) + basic_machine=m68k-isi + os=-sysv + ;; + leon-*|leon[3-9]-*) + basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'` + ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux ;; m68knommu-*) - cpu=m68k - os=linux + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux ;; - m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*) - cpu=s12z + m88k-omron*) + basic_machine=m88k-omron ;; - openrisc-*) - cpu=or32 + magnum | m3230) + basic_machine=mips-mips + os=-sysv ;; - parisc-*) - cpu=hppa - os=linux + merlin) + basic_machine=ns32k-utek + os=-sysv ;; - pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) - cpu=i586 + microblaze*) + basic_machine=microblaze-xilinx ;; - pentiumpro-* | p6-* | 6x86-* | athlon-* | athalon_*-*) - cpu=i686 + mingw64) + basic_machine=x86_64-pc + os=-mingw64 ;; - pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) - cpu=i686 + mingw32) + basic_machine=i686-pc + os=-mingw32 ;; - pentium4-*) - cpu=i786 + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce ;; - pc98-*) - cpu=i386 + miniframe) + basic_machine=m68000-convergent ;; - ppc-* | ppcbe-*) - cpu=powerpc + *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) + basic_machine=m68k-atari + os=-mint ;; - ppcle-* | powerpclittle-*) - cpu=powerpcle + mips3*-*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; - ppc64-*) - cpu=powerpc64 + mips3*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; - ppc64le-* | powerpc64little-*) - cpu=powerpc64le + monitor) + basic_machine=m68k-rom68k + os=-coff ;; - sb1-*) - cpu=mipsisa64sb1 + morphos) + basic_machine=powerpc-unknown + os=-morphos ;; - sb1el-*) - cpu=mipsisa64sb1el + moxiebox) + basic_machine=moxie-unknown + os=-moxiebox ;; - sh5e[lb]-*) - cpu=`echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/'` + msdos) + basic_machine=i386-pc + os=-msdos ;; - spur-*) - cpu=spur + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; - strongarm-* | thumb-*) - cpu=arm + msys) + basic_machine=i686-pc + os=-msys ;; - tx39-*) - cpu=mipstx39 + mvs) + basic_machine=i370-ibm + os=-mvs ;; - tx39el-*) - cpu=mipstx39el + nacl) + basic_machine=le32-unknown + os=-nacl ;; - x64-*) - cpu=x86_64 + ncr3000) + basic_machine=i486-ncr + os=-sysv4 ;; - xscale-* | xscalee[bl]-*) - cpu=`echo "$cpu" | sed 's/^xscale/arm/'` + netbsd386) + basic_machine=i386-unknown + os=-netbsd ;; - - # Recognize the cannonical CPU Types that limit and/or modify the - # company names they are paired with. - cr16-*) - os=${os:-elf} + netwinder) + basic_machine=armv4l-rebel + os=-linux ;; - crisv32-* | etraxfs*-*) - cpu=crisv32 - vendor=axis + news | news700 | news800 | news900) + basic_machine=m68k-sony + os=-newsos ;; - cris-* | etrax*-*) - cpu=cris - vendor=axis + news1000) + basic_machine=m68030-sony + os=-newsos ;; - crx-*) - os=${os:-elf} + news-3600 | risc-news) + basic_machine=mips-sony + os=-newsos + ;; + necv70) + basic_machine=v70-nec + os=-sysv + ;; + next | m*-next ) + basic_machine=m68k-next + case $os in + -nextstep* ) + ;; + -ns2*) + os=-nextstep2 + ;; + *) + os=-nextstep3 + ;; + esac + ;; + nh3000) + basic_machine=m68k-harris + os=-cxux + ;; + nh[45]000) + basic_machine=m88k-harris + os=-cxux + ;; + nindy960) + basic_machine=i960-intel + os=-nindy + ;; + mon960) + basic_machine=i960-intel + os=-mon960 + ;; + nonstopux) + basic_machine=mips-compaq + os=-nonstopux + ;; + np1) + basic_machine=np1-gould ;; neo-tandem) - cpu=neo - vendor=tandem + basic_machine=neo-tandem ;; nse-tandem) - cpu=nse - vendor=tandem + basic_machine=nse-tandem ;; nsr-tandem) - cpu=nsr - vendor=tandem + basic_machine=nsr-tandem ;; - nsv-tandem) - cpu=nsv - vendor=tandem + op50n-* | op60c-*) + basic_machine=hppa1.1-oki + os=-proelf ;; - nsx-tandem) - cpu=nsx - vendor=tandem + openrisc | openrisc-*) + basic_machine=or32-unknown ;; - s390-*) - cpu=s390 - vendor=ibm + os400) + basic_machine=powerpc-ibm + os=-os400 ;; - s390x-*) - cpu=s390x - vendor=ibm + OSE68000 | ose68000) + basic_machine=m68000-ericsson + os=-ose ;; - tile*-*) - os=${os:-linux-gnu} + os68k) + basic_machine=m68k-none + os=-os68k + ;; + pa-hitachi) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + paragon) + basic_machine=i860-intel + os=-osf + ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + pbd) + basic_machine=sparc-tti + ;; + pbb) + basic_machine=m68k-tti + ;; + pc532 | pc532-*) + basic_machine=ns32k-pc532 + ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium | p5 | k5 | k6 | nexgen | viac3) + basic_machine=i586-pc + ;; + pentiumpro | p6 | 6x86 | athlon | athlon_*) + basic_machine=i686-pc + ;; + pentiumii | pentium2 | pentiumiii | pentium3) + basic_machine=i686-pc + ;; + pentium4) + basic_machine=i786-pc + ;; + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) + basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumpro-* | p6-* | 6x86-* | athlon-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium4-*) + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pn) + basic_machine=pn-gould + ;; + power) basic_machine=power-ibm + ;; + ppc | ppcbe) basic_machine=powerpc-unknown + ;; + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppcle | powerpclittle) + basic_machine=powerpcle-unknown + ;; + ppcle-* | powerpclittle-*) + basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64) basic_machine=powerpc64-unknown + ;; + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64le | powerpc64little) + basic_machine=powerpc64le-unknown + ;; + ppc64le-* | powerpc64little-*) + basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ps2) + basic_machine=i386-ibm + ;; + pw32) + basic_machine=i586-unknown + os=-pw32 + ;; + rdos | rdos64) + basic_machine=x86_64-pc + os=-rdos + ;; + rdos32) + basic_machine=i386-pc + os=-rdos + ;; + rom68k) + basic_machine=m68k-rom68k + os=-coff + ;; + rm[46]00) + basic_machine=mips-siemens + ;; + rtpc | rtpc-*) + basic_machine=romp-ibm + ;; + s390 | s390-*) + basic_machine=s390-ibm + ;; + s390x | s390x-*) + basic_machine=s390x-ibm + ;; + sa29200) + basic_machine=a29k-amd + os=-udi + ;; + sb1) + basic_machine=mipsisa64sb1-unknown + ;; + sb1el) + basic_machine=mipsisa64sb1el-unknown + ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; + sei) + basic_machine=mips-sei + os=-seiux + ;; + sequent) + basic_machine=i386-sequent + ;; + sh) + basic_machine=sh-hitachi + os=-hms + ;; + sh5el) + basic_machine=sh5le-unknown + ;; + sh64) + basic_machine=sh64-unknown + ;; + sparclite-wrs | simso-wrs) + basic_machine=sparclite-wrs + os=-vxworks + ;; + sps7) + basic_machine=m68k-bull + os=-sysv2 + ;; + spur) + basic_machine=spur-unknown + ;; + st2000) + basic_machine=m68k-tandem + ;; + stratus) + basic_machine=i860-stratus + os=-sysv4 + ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + sun2) + basic_machine=m68000-sun + ;; + sun2os3) + basic_machine=m68000-sun + os=-sunos3 + ;; + sun2os4) + basic_machine=m68000-sun + os=-sunos4 + ;; + sun3os3) + basic_machine=m68k-sun + os=-sunos3 + ;; + sun3os4) + basic_machine=m68k-sun + os=-sunos4 + ;; + sun4os3) + basic_machine=sparc-sun + os=-sunos3 + ;; + sun4os4) + basic_machine=sparc-sun + os=-sunos4 + ;; + sun4sol2) + basic_machine=sparc-sun + os=-solaris2 + ;; + sun3 | sun3-*) + basic_machine=m68k-sun + ;; + sun4) + basic_machine=sparc-sun + ;; + sun386 | sun386i | roadrunner) + basic_machine=i386-sun + ;; + sv1) + basic_machine=sv1-cray + os=-unicos + ;; + symmetry) + basic_machine=i386-sequent + os=-dynix + ;; + t3e) + basic_machine=alphaev5-cray + os=-unicos + ;; + t90) + basic_machine=t90-cray + os=-unicos + ;; + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu + ;; + tx39) + basic_machine=mipstx39-unknown + ;; + tx39el) + basic_machine=mipstx39el-unknown + ;; + toad1) + basic_machine=pdp10-xkl + os=-tops20 + ;; + tower | tower-32) + basic_machine=m68k-ncr + ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; + udi29k) + basic_machine=a29k-amd + os=-udi + ;; + ultra3) + basic_machine=a29k-nyu + os=-sym1 + ;; + v810 | necv810) + basic_machine=v810-nec + os=-none + ;; + vaxv) + basic_machine=vax-dec + os=-sysv + ;; + vms) + basic_machine=vax-dec + os=-vms + ;; + vpp*|vx|vx-*) + basic_machine=f301-fujitsu + ;; + vxworks960) + basic_machine=i960-wrs + os=-vxworks + ;; + vxworks68) + basic_machine=m68k-wrs + os=-vxworks + ;; + vxworks29k) + basic_machine=a29k-wrs + os=-vxworks + ;; + w65*) + basic_machine=w65-wdc + os=-none + ;; + w89k-*) + basic_machine=hppa1.1-winbond + os=-proelf + ;; + xbox) + basic_machine=i686-pc + os=-mingw32 + ;; + xps | xps100) + basic_machine=xps100-honeywell + ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; + ymp) + basic_machine=ymp-cray + os=-unicos + ;; + z8k-*-coff) + basic_machine=z8k-unknown + os=-sim + ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; + none) + basic_machine=none-none + os=-none ;; +# Here we handle the default manufacturer of certain CPU types. It is in +# some cases the only manufacturer, in others, it is the most popular. + w89k) + basic_machine=hppa1.1-winbond + ;; + op50n) + basic_machine=hppa1.1-oki + ;; + op60c) + basic_machine=hppa1.1-oki + ;; + romp) + basic_machine=romp-ibm + ;; + mmix) + basic_machine=mmix-knuth + ;; + rs6000) + basic_machine=rs6000-ibm + ;; + vax) + basic_machine=vax-dec + ;; + pdp10) + # there are many clones, so DEC is not a safe bet + basic_machine=pdp10-unknown + ;; + pdp11) + basic_machine=pdp11-dec + ;; + we32k) + basic_machine=we32k-att + ;; + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) + basic_machine=sh-unknown + ;; + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) + basic_machine=sparc-sun + ;; + cydra) + basic_machine=cydra-cydrome + ;; + orion) + basic_machine=orion-highlevel + ;; + orion105) + basic_machine=clipper-highlevel + ;; + mac | mpw | mac-mpw) + basic_machine=m68k-apple + ;; + pmac | pmac-mpw) + basic_machine=powerpc-apple + ;; + *-unknown) + # Make sure to match an already-canonicalized machine name. + ;; *) - # Recognize the cannonical CPU types that are allowed with any - # company name. - case $cpu in - 1750a | 580 \ - | a29k \ - | aarch64 | aarch64_be \ - | abacus \ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \ - | alphapca5[67] | alpha64pca5[67] \ - | am33_2.0 \ - | arc | arceb \ - | arm | arm[lb]e | arme[lb] | armv* \ - | avr | avr32 \ - | asmjs \ - | ba \ - | be32 | be64 \ - | bfin | bs2000 \ - | c[123]* | c30 | [cjt]90 | c4x \ - | c8051 | clipper | craynv | csky | cydra \ - | d10v | d30v | dlx | dsp16xx \ - | e2k | elxsi | epiphany \ - | f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \ - | h8300 | h8500 \ - | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ - | hexagon \ - | i370 | i*86 | i860 | i960 | ia16 | ia64 \ - | ip2k | iq2000 \ - | k1om \ - | le32 | le64 \ - | lm32 \ - | m32c | m32r | m32rle \ - | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k | v70 | w65 \ - | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip \ - | m88110 | m88k | maxq | mb | mcore | mep | metag \ - | microblaze | microblazeel \ - | mips | mipsbe | mipseb | mipsel | mipsle \ - | mips16 \ - | mips64 | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ - | mips64vr | mips64vrel \ - | mips64vr4100 | mips64vr4100el \ - | mips64vr4300 | mips64vr4300el \ - | mips64vr5000 | mips64vr5000el \ - | mips64vr5900 | mips64vr5900el \ - | mipsisa32 | mipsisa32el \ - | mipsisa32r2 | mipsisa32r2el \ - | mipsisa32r6 | mipsisa32r6el \ - | mipsisa64 | mipsisa64el \ - | mipsisa64r2 | mipsisa64r2el \ - | mipsisa64r6 | mipsisa64r6el \ - | mipsisa64sb1 | mipsisa64sb1el \ - | mipsisa64sr71k | mipsisa64sr71kel \ - | mipsr5900 | mipsr5900el \ - | mipstx39 | mipstx39el \ - | mmix \ - | mn10200 | mn10300 \ - | moxie \ - | mt \ - | msp430 \ - | nds32 | nds32le | nds32be \ - | nfp \ - | nios | nios2 | nios2eb | nios2el \ - | none | np1 | ns16k | ns32k \ - | open8 \ - | or1k* \ - | or32 \ - | orion \ - | pdp10 | pdp11 | pj | pjl | pn | power \ - | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \ - | pru \ - | pyramid \ - | riscv | riscv32 | riscv64 \ - | rl78 | romp | rs6000 | rx \ - | score \ - | sh | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \ - | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \ - | sparclite \ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \ - | spu \ - | tahoe \ - | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \ - | tron \ - | ubicom32 \ - | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \ - | vax \ - | visium \ - | wasm32 \ - | we32k \ - | x86 | x86_64 | xc16x | xgate | xps100 \ - | xstormy16 | xtensa* \ - | ymp \ - | z8k | z80) - ;; - - *) - echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2 - exit 1 - ;; - esac + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. -case $vendor in - digital*) - vendor=dec +case $basic_machine in + *-digital*) + basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; - commodore*) - vendor=cbm + *-commodore*) + basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; @@ -1270,246 +1355,200 @@ esac # Decode manufacturer-specific aliases for certain operating systems. -if [ x$os != x ] +if [ x"$os" != x"" ] then case $os in - # First match some system type aliases that might get confused - # with valid system types. - # solaris* is a basic system type, with this one exception. - auroraux) - os=auroraux + # First match some system type aliases + # that might get confused with valid system types. + # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux ;; - bluegene*) - os=cnk - ;; - solaris1 | solaris1.*) + -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; - solaris) - os=solaris2 + -solaris) + os=-solaris2 ;; - unixware*) - os=sysv4.2uw + -svr4*) + os=-sysv4 ;; - gnu/linux*) + -unixware*) + os=-sysv4.2uw + ;; + -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; - # es1800 is here to avoid being matched by es* (a different OS) - es1800*) - os=ose - ;; - # Some version numbers need modification - chorusos*) - os=chorusos - ;; - isc) - os=isc2.2 - ;; - sco6) - os=sco5v6 - ;; - sco5) - os=sco3.2v5 - ;; - sco4) - os=sco3.2v4 - ;; - sco3.2.[4-9]*) - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` - ;; - sco3.2v[4-9]* | sco5v6*) - # Don't forget version if it is 3.2v4 or newer. - ;; - scout) - # Don't match below - ;; - sco*) - os=sco3.2v2 - ;; - psos*) - os=psos - ;; - # Now accept the basic system types. + # First accept the basic system types. # The portable systems comes first. - # Each alternative MUST end in a * to match a version number. - # sysv* is not here because it comes later, after sysvr4. - gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \ - | *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\ - | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \ - | sym* | kopensolaris* | plan9* \ - | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \ - | aos* | aros* | cloudabi* | sortix* \ - | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \ - | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \ - | knetbsd* | mirbsd* | netbsd* \ - | bitrig* | openbsd* | solidbsd* | libertybsd* \ - | ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \ - | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \ - | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \ - | udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \ - | chorusrdb* | cegcc* | glidix* \ - | cygwin* | msys* | pe* | moss* | proelf* | rtems* \ - | midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \ - | linux-newlib* | linux-musl* | linux-uclibc* \ - | uxpv* | beos* | mpeix* | udk* | moxiebox* \ - | interix* | uwin* | mks* | rhapsody* | darwin* \ - | openstep* | oskit* | conix* | pw32* | nonstopux* \ - | storm-chaos* | tops10* | tenex* | tops20* | its* \ - | os2* | vos* | palmos* | uclinux* | nucleus* \ - | morphos* | superux* | rtmk* | windiss* \ - | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \ - | skyos* | haiku* | rdos* | toppers* | drops* | es* \ - | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \ - | midnightbsd*) + # Each alternative MUST END IN A *, to match a version number. + # -sysv* is not here because it comes later, after sysvr4. + -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* | -plan9* \ + | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ + | -aos* | -aros* | -cloudabi* | -sortix* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \ + | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ + | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* | -cegcc* \ + | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-musl* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \ + | -onefs* | -tirtos* | -phoenix* | -fuchsia*) # Remember, each alternative MUST END IN *, to match a version number. ;; - qnx*) - case $cpu in - x86 | i*86) + -qnx*) + case $basic_machine in + x86-* | i*86-*) ;; *) - os=nto-$os + os=-nto$os ;; esac ;; - hiux*) - os=hiuxwe2 + -nto-qnx*) ;; - nto-qnx*) - ;; - nto*) + -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; - sim | xray | os68k* | v88r* \ - | windows* | osx | abug | netware* | os9* \ - | macos* | mpw* | magic* | mmixware* | mon960* | lnews*) + -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ + | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ + | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; - linux-dietlibc) - os=linux-dietlibc + -mac*) + os=`echo $os | sed -e 's|mac|macos|'` ;; - linux*) + -linux-dietlibc) + os=-linux-dietlibc + ;; + -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; - lynx*178) - os=lynxos178 + -sunos5*) + os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; - lynx*5) - os=lynxos5 + -sunos6*) + os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; - lynx*) - os=lynxos + -opened*) + os=-openedition ;; - mac*) - os=`echo "$os" | sed -e 's|mac|macos|'` + -os400*) + os=-os400 ;; - opened*) - os=openedition + -wince*) + os=-wince ;; - os400*) - os=os400 + -osfrose*) + os=-osfrose ;; - sunos5*) - os=`echo "$os" | sed -e 's|sunos5|solaris2|'` + -osf*) + os=-osf ;; - sunos6*) - os=`echo "$os" | sed -e 's|sunos6|solaris3|'` + -utek*) + os=-bsd ;; - wince*) - os=wince + -dynix*) + os=-bsd ;; - utek*) - os=bsd + -acis*) + os=-aos ;; - dynix*) - os=bsd + -atheos*) + os=-atheos ;; - acis*) - os=aos + -syllable*) + os=-syllable ;; - atheos*) - os=atheos + -386bsd) + os=-bsd ;; - syllable*) - os=syllable + -ctix* | -uts*) + os=-sysv ;; - 386bsd) - os=bsd + -nova*) + os=-rtmk-nova ;; - ctix* | uts*) - os=sysv + -ns2 ) + os=-nextstep2 ;; - nova*) - os=rtmk-nova - ;; - ns2) - os=nextstep2 - ;; - nsk*) - os=nsk + -nsk*) + os=-nsk ;; # Preserve the version number of sinix5. - sinix5.*) + -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; - sinix*) - os=sysv4 + -sinix*) + os=-sysv4 ;; - tpf*) - os=tpf + -tpf*) + os=-tpf ;; - triton*) - os=sysv3 + -triton*) + os=-sysv3 ;; - oss*) - os=sysv3 + -oss*) + os=-sysv3 ;; - svr4*) - os=sysv4 + -svr4) + os=-sysv4 ;; - svr3) - os=sysv3 + -svr3) + os=-sysv3 ;; - sysvr4) - os=sysv4 + -sysvr4) + os=-sysv4 ;; - # This must come after sysvr4. - sysv*) + # This must come after -sysvr4. + -sysv*) ;; - ose*) - os=ose + -ose*) + os=-ose ;; - *mint | mint[0-9]* | *MiNT | MiNT[0-9]*) - os=mint + -es1800*) + os=-ose ;; - zvmoe) - os=zvmoe + -xenix) + os=-xenix ;; - dicos*) - os=dicos + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + os=-mint ;; - pikeos*) - # Until real need of OS specific support for - # particular features comes up, bare metal - # configurations are quite functional. - case $cpu in - arm*) - os=eabi - ;; - *) - os=elf - ;; - esac + -aros*) + os=-aros ;; - nacl*) + -zvmoe) + os=-zvmoe ;; - ios) + -dicos*) + os=-dicos ;; - none) + -nacl*) ;; - *-eabi) + -ios) + ;; + -none) ;; *) - echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2 + # Get rid of the `-' at the beginning of $os. + os=`echo $os | sed 's/[^-]*-//'` + echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac @@ -1525,265 +1564,261 @@ else # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. -case $cpu-$vendor in +case $basic_machine in score-*) - os=elf + os=-elf ;; spu-*) - os=elf + os=-elf ;; *-acorn) - os=riscix1.2 + os=-riscix1.2 ;; arm*-rebel) - os=linux + os=-linux ;; arm*-semi) - os=aout + os=-aout ;; c4x-* | tic4x-*) - os=coff + os=-coff ;; c8051-*) - os=elf - ;; - clipper-intergraph) - os=clix + os=-elf ;; hexagon-*) - os=elf + os=-elf ;; tic54x-*) - os=coff + os=-coff ;; tic55x-*) - os=coff + os=-coff ;; tic6x-*) - os=coff + os=-coff ;; # This must come before the *-dec entry. pdp10-*) - os=tops20 + os=-tops20 ;; pdp11-*) - os=none + os=-none ;; *-dec | vax-*) - os=ultrix4.2 + os=-ultrix4.2 ;; m68*-apollo) - os=domain + os=-domain ;; i386-sun) - os=sunos4.0.2 + os=-sunos4.0.2 ;; m68000-sun) - os=sunos3 + os=-sunos3 ;; m68*-cisco) - os=aout + os=-aout ;; mep-*) - os=elf + os=-elf ;; mips*-cisco) - os=elf + os=-elf ;; mips*-*) - os=elf + os=-elf ;; or32-*) - os=coff + os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. - os=sysv3 + os=-sysv3 ;; sparc-* | *-sun) - os=sunos4.1.1 - ;; - pru-*) - os=elf + os=-sunos4.1.1 ;; *-be) - os=beos + os=-beos + ;; + *-haiku) + os=-haiku ;; *-ibm) - os=aix + os=-aix ;; *-knuth) - os=mmixware + os=-mmixware ;; *-wec) - os=proelf + os=-proelf ;; *-winbond) - os=proelf + os=-proelf ;; *-oki) - os=proelf + os=-proelf ;; *-hp) - os=hpux + os=-hpux ;; *-hitachi) - os=hiux + os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) - os=sysv + os=-sysv ;; *-cbm) - os=amigaos + os=-amigaos ;; *-dg) - os=dgux + os=-dgux ;; *-dolphin) - os=sysv3 + os=-sysv3 ;; m68k-ccur) - os=rtu + os=-rtu ;; m88k-omron*) - os=luna + os=-luna ;; - *-next) - os=nextstep + *-next ) + os=-nextstep ;; *-sequent) - os=ptx + os=-ptx ;; *-crds) - os=unos + os=-unos ;; *-ns) - os=genix + os=-genix ;; i370-*) - os=mvs + os=-mvs + ;; + *-next) + os=-nextstep3 ;; *-gould) - os=sysv + os=-sysv ;; *-highlevel) - os=bsd + os=-bsd ;; *-encore) - os=bsd + os=-bsd ;; *-sgi) - os=irix + os=-irix ;; *-siemens) - os=sysv4 + os=-sysv4 ;; *-masscomp) - os=rtu + os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) - os=uxpv + os=-uxpv ;; *-rom68k) - os=coff + os=-coff ;; *-*bug) - os=coff + os=-coff ;; *-apple) - os=macos + os=-macos ;; *-atari*) - os=mint - ;; - *-wrs) - os=vxworks + os=-mint ;; *) - os=none + os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. -case $vendor in - unknown) +vendor=unknown +case $basic_machine in + *-unknown) case $os in - riscix*) + -riscix*) vendor=acorn ;; - sunos*) + -sunos*) vendor=sun ;; - cnk*|-aix*) + -cnk*|-aix*) vendor=ibm ;; - beos*) + -beos*) vendor=be ;; - hpux*) + -hpux*) vendor=hp ;; - mpeix*) + -mpeix*) vendor=hp ;; - hiux*) + -hiux*) vendor=hitachi ;; - unos*) + -unos*) vendor=crds ;; - dgux*) + -dgux*) vendor=dg ;; - luna*) + -luna*) vendor=omron ;; - genix*) + -genix*) vendor=ns ;; - clix*) - vendor=intergraph - ;; - mvs* | opened*) + -mvs* | -opened*) vendor=ibm ;; - os400*) + -os400*) vendor=ibm ;; - ptx*) + -ptx*) vendor=sequent ;; - tpf*) + -tpf*) vendor=ibm ;; - vxsim* | vxworks* | windiss*) + -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; - aux*) + -aux*) vendor=apple ;; - hms*) + -hms*) vendor=hitachi ;; - mpw* | macos*) + -mpw* | -macos*) vendor=apple ;; - *mint | mint[0-9]* | *MiNT | MiNT[0-9]*) + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; - vos*) + -vos*) vendor=stratus ;; esac + basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac -echo "$cpu-$vendor-$os" +echo $basic_machine$os exit # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" diff --git a/hawk/ac/depcomp b/hawk/ac/depcomp index 65cbf709..fc98710e 100755 --- a/hawk/ac/depcomp +++ b/hawk/ac/depcomp @@ -1,9 +1,9 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2018-03-07.03; # UTC +scriptversion=2013-05-30.07; # UTC -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -16,7 +16,7 @@ scriptversion=2018-03-07.03; # UTC # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -783,9 +783,9 @@ exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" +# time-stamp-time-zone: "UTC" # time-stamp-end: "; # UTC" # End: diff --git a/hawk/ac/install-sh b/hawk/ac/install-sh index 8175c640..59990a10 100755 --- a/hawk/ac/install-sh +++ b/hawk/ac/install-sh @@ -1,7 +1,7 @@ #!/bin/sh # install - install a program, script, or datafile -scriptversion=2018-03-11.20; # UTC +scriptversion=2014-09-12.12; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the @@ -271,18 +271,15 @@ do fi dst=$dst_arg - # If destination is a directory, append the input filename. + # If destination is a directory, append the input filename; won't work + # if double slashes aren't ignored. if test -d "$dst"; then if test "$is_target_a_directory" = never; then echo "$0: $dst_arg: Is a directory" >&2 exit 1 fi dstdir=$dst - dstbase=`basename "$src"` - case $dst in - */) dst=$dst$dstbase;; - *) dst=$dst/$dstbase;; - esac + dst=$dstdir/`basename "$src"` dstdir_status=0 else dstdir=`dirname "$dst"` @@ -291,11 +288,6 @@ do fi fi - case $dstdir in - */) dstdirslash=$dstdir;; - *) dstdirslash=$dstdir/;; - esac - obsolete_mkdir_used=false if test $dstdir_status != 0; then @@ -332,16 +324,14 @@ do # is incompatible with FreeBSD 'install' when (umask & 300) != 0. ;; *) - # Note that $RANDOM variable is not portable (e.g. dash); Use it - # here however when possible just to lower collision chance. + # $RANDOM is not portable (e.g. dash); use it when possible to + # lower collision chance tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0 - # Because "mkdir -p" follows existing symlinks and we likely work - # directly in world-writeable /tmp, make sure that the '$tmpdir' - # directory is successfully created first before we actually test - # 'mkdir -p' feature. + # As "mkdir -p" follows symlinks and we work in /tmp possibly; so + # create the $tmpdir first (and fail if unsuccessful) to make sure + # that nobody tries to guess the $tmpdir name. if (umask $mkdir_umask && $mkdirprog $mkdir_mode "$tmpdir" && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 @@ -444,8 +434,8 @@ do else # Make a couple of temp file names in the proper directory. - dsttmp=${dstdirslash}_inst.$$_ - rmtmp=${dstdirslash}_rm.$$_ + dsttmp=$dstdir/_inst.$$_ + rmtmp=$dstdir/_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 @@ -510,9 +500,9 @@ do done # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" +# time-stamp-time-zone: "UTC" # time-stamp-end: "; # UTC" # End: diff --git a/hawk/ac/ltmain.sh b/hawk/ac/ltmain.sh index 7f3523d3..a736cf99 100644 --- a/hawk/ac/ltmain.sh +++ b/hawk/ac/ltmain.sh @@ -31,7 +31,7 @@ PROGRAM=libtool PACKAGE=libtool -VERSION=2.4.6 +VERSION="2.4.6 Debian-2.4.6-2" package_revision=2.4.6 @@ -2068,12 +2068,12 @@ include the following information: compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) - version: $progname (GNU libtool) 2.4.6 + version: $progname $scriptversion Debian-2.4.6-2 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to . -GNU libtool home page: . +GNU libtool home page: . General help using GNU software: ." exit 0 } @@ -2124,7 +2124,7 @@ fi # a configuration failure hint, and exit. func_fatal_configuration () { - func_fatal_error ${1+"$@"} \ + func__fatal_error ${1+"$@"} \ "See the $PACKAGE documentation for more information." \ "Fatal configuration error." } @@ -7274,10 +7274,11 @@ func_mode_link () # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization # -specs=* GCC specs files # -stdlib=* select c++ std lib with clang + # -fsanitize=* Clang/GCC memory and address sanitizer -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ - -specs=*) + -specs=*|-fsanitize=*) func_quote_for_eval "$arg" arg=$func_quote_for_eval_result func_append compile_command " $arg" @@ -7570,7 +7571,10 @@ func_mode_link () case $pass in dlopen) libs=$dlfiles ;; dlpreopen) libs=$dlprefiles ;; - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + link) + libs="$deplibs %DEPLIBS%" + test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" + ;; esac fi if test lib,dlpreopen = "$linkmode,$pass"; then @@ -7889,19 +7893,19 @@ func_mode_link () # It is a libtool convenience library, so add in its objects. func_append convenience " $ladir/$objdir/$old_library" func_append old_convenience " $ladir/$objdir/$old_library" + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done elif test prog != "$linkmode" && test lib != "$linkmode"; then func_fatal_error "'$lib' is not a convenience library" fi - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done continue fi # $pass = conv @@ -8825,6 +8829,9 @@ func_mode_link () revision=$number_minor lt_irix_increment=no ;; + *) + func_fatal_configuration "$modename: unknown library version type '$version_type'" + ;; esac ;; no) diff --git a/hawk/ac/missing b/hawk/ac/missing index 625aeb11..f62bbae3 100755 --- a/hawk/ac/missing +++ b/hawk/ac/missing @@ -1,9 +1,9 @@ #! /bin/sh # Common wrapper for a few potentially missing GNU programs. -scriptversion=2018-03-07.03; # UTC +scriptversion=2013-10-28.13; # UTC -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify @@ -17,7 +17,7 @@ scriptversion=2018-03-07.03; # UTC # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -101,9 +101,9 @@ else exit $st fi -perl_URL=https://www.perl.org/ -flex_URL=https://github.com/westes/flex -gnu_software_URL=https://www.gnu.org/software +perl_URL=http://www.perl.org/ +flex_URL=http://flex.sourceforge.net/ +gnu_software_URL=http://www.gnu.org/software program_details () { @@ -207,9 +207,9 @@ give_advice "$1" | sed -e '1s/^/WARNING: /' \ exit $st # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" +# time-stamp-time-zone: "UTC" # time-stamp-end: "; # UTC" # End: diff --git a/hawk/aclocal.m4 b/hawk/aclocal.m4 index 2b31feff..c054071c 100644 --- a/hawk/aclocal.m4 +++ b/hawk/aclocal.m4 @@ -1,6 +1,6 @@ -# generated automatically by aclocal 1.16.1 -*- Autoconf -*- +# generated automatically by aclocal 1.15 -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -20,7 +20,7 @@ You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically 'autoreconf'.])]) -# Copyright (C) 2002-2018 Free Software Foundation, Inc. +# Copyright (C) 2002-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -32,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.16' +[am__api_version='1.15' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.16.1], [], +m4_if([$1], [1.15], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -51,12 +51,12 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.16.1])dnl +[AM_AUTOMAKE_VERSION([1.15])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) -# Copyright (C) 2011-2018 Free Software Foundation, Inc. +# Copyright (C) 2011-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -118,7 +118,7 @@ AC_SUBST([AR])dnl # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -170,7 +170,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd` # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997-2018 Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -201,7 +201,7 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -392,12 +392,13 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. + # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], @@ -405,41 +406,49 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. - # TODO: see whether this extra hack can be removed once we start - # requiring Autoconf 2.70 or later. - AS_CASE([$CONFIG_FILES], - [*\'*], [eval set x "$CONFIG_FILES"], - [*], [set x $CONFIG_FILES]) + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac shift - # Used to flag and report bootstrapping failures. - am_rc=0 - for am_mf + for mf do # Strip MF so we end up with the name of the file. - am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile which includes - # dependency-tracking related rules and includes. - # Grep'ing the whole file directly is not great: AIX grep has a line + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. - sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ - || continue - am_dirpart=`AS_DIRNAME(["$am_mf"])` - am_filepart=`AS_BASENAME(["$am_mf"])` - AM_RUN_LOG([cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles]) || am_rc=$? + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`AS_DIRNAME("$mf")` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`AS_DIRNAME(["$file"])` + AS_MKDIR_P([$dirpart/$fdir]) + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done done - if test $am_rc -ne 0; then - AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. Try re-running configure with the - '--disable-dependency-tracking' option to at least be able to build - the package (albeit without support for automatic dependency tracking).]) - fi - AS_UNSET([am_dirpart]) - AS_UNSET([am_filepart]) - AS_UNSET([am_mf]) - AS_UNSET([am_rc]) - rm -f conftest-deps.mk } ])# _AM_OUTPUT_DEPENDENCY_COMMANDS @@ -448,17 +457,18 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # -# This code is only required when automatic dependency tracking is enabled. -# This creates each '.Po' and '.Plo' makefile fragment that we'll need in -# order to bootstrap the dependency handling code. +# This code is only required when automatic dependency tracking +# is enabled. FIXME. This creates each '.P' file that we will +# need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], - [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) +]) # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -545,8 +555,8 @@ AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: -# -# +# +# AC_SUBST([mkdir_p], ['$(MKDIR_P)']) # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. @@ -613,7 +623,7 @@ END Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . +that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM @@ -655,7 +665,7 @@ for _am_header in $config_headers :; do done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -676,7 +686,7 @@ if test x"${install_sh+set}" != xset; then fi AC_SUBST([install_sh])]) -# Copyright (C) 2003-2018 Free Software Foundation, Inc. +# Copyright (C) 2003-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -697,7 +707,7 @@ AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -705,42 +715,49 @@ AC_SUBST([am__leading_dot])]) # AM_MAKE_INCLUDE() # ----------------- -# Check whether make has an 'include' directive that can support all -# the idioms we need for our automatic dependency tracking code. +# Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], -[AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) -cat > confinc.mk << 'END' +[am_make=${MAKE-make} +cat > confinc << 'END' am__doit: - @echo this is the am__doit target >confinc.out + @echo this is the am__doit target .PHONY: am__doit END +# If we don't find an include directive, just comment out the code. +AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= -# BSD make does it like this. -echo '.include "confinc.mk" # ignored' > confmf.BSD -# Other make implementations (GNU, Solaris 10, AIX) do it like this. -echo 'include confinc.mk # ignored' > confmf.GNU -_am_result=no -for s in GNU BSD; do - AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) - AS_CASE([$?:`cat confinc.out 2>/dev/null`], - ['0:this is the am__doit target'], - [AS_CASE([$s], - [BSD], [am__include='.include' am__quote='"'], - [am__include='include' am__quote=''])]) - if test "$am__include" != "#"; then - _am_result="yes ($s style)" - break - fi -done -rm -f confinc.* confmf.* -AC_MSG_RESULT([${_am_result}]) -AC_SUBST([am__include])]) -AC_SUBST([am__quote])]) +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) +rm -f confinc confmf +]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997-2018 Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -779,7 +796,7 @@ fi # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -808,7 +825,7 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -855,7 +872,7 @@ AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -874,7 +891,7 @@ AC_DEFUN([AM_RUN_LOG], # Check to make sure that the build environment is sane. -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -955,7 +972,7 @@ AC_CONFIG_COMMANDS_PRE( rm -f conftest.file ]) -# Copyright (C) 2009-2018 Free Software Foundation, Inc. +# Copyright (C) 2009-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1015,7 +1032,7 @@ AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl ]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1043,7 +1060,7 @@ fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006-2018 Free Software Foundation, Inc. +# Copyright (C) 2006-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1062,7 +1079,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004-2018 Free Software Foundation, Inc. +# Copyright (C) 2004-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, diff --git a/hawk/bin/Makefile.in b/hawk/bin/Makefile.in index 142ee005..986d6809 100644 --- a/hawk/bin/Makefile.in +++ b/hawk/bin/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -132,8 +132,7 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = depcomp = $(SHELL) $(top_srcdir)/ac/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/hawk-main.Po +am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -326,6 +325,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -376,8 +376,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -448,13 +448,7 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hawk-main.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hawk-main.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @@ -552,10 +546,7 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -627,7 +618,7 @@ clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/hawk-main.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags @@ -673,7 +664,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/hawk-main.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -694,7 +685,7 @@ uninstall-am: uninstall-binPROGRAMS .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ clean-binPROGRAMS clean-generic clean-libtool cscopelist-am \ ctags ctags-am distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ diff --git a/hawk/configure b/hawk/configure index 15b2f31f..acfdab53 100755 --- a/hawk/configure +++ b/hawk/configure @@ -731,6 +731,7 @@ am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE +am__quote am__include DEPDIR OBJEXT @@ -788,6 +789,7 @@ infodir docdir oldincludedir includedir +runstatedir localstatedir sharedstatedir sysconfdir @@ -806,8 +808,7 @@ PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR -SHELL -am__quote' +SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking @@ -888,6 +889,7 @@ datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' +runstatedir='${localstatedir}/run' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -1140,6 +1142,15 @@ do | -silent | --silent | --silen | --sile | --sil) silent=yes ;; + -runstatedir | --runstatedir | --runstatedi | --runstated \ + | --runstate | --runstat | --runsta | --runst | --runs \ + | --run | --ru | --r) + ac_prev=runstatedir ;; + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ + | --run=* | --ru=* | --r=*) + runstatedir=$ac_optarg ;; + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ @@ -1277,7 +1288,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir + libdir localedir mandir runstatedir do eval ac_val=\$$ac_var # Remove trailing slashes. @@ -1430,6 +1441,7 @@ Fine tuning of the installation directories: --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] @@ -2767,7 +2779,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -am__api_version='1.16' +am__api_version='1.15' # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or @@ -3283,8 +3295,8 @@ MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: -# -# +# +# mkdir_p='$(MKDIR_P)' # We need awk for the "check" target (and possibly the TAP driver). The @@ -3335,7 +3347,7 @@ END Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . +that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM @@ -3350,45 +3362,45 @@ DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 -$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; } -cat > confinc.mk << 'END' + +am_make=${MAKE-make} +cat > confinc << 'END' am__doit: - @echo this is the am__doit target >confinc.out + @echo this is the am__doit target .PHONY: am__doit END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= -# BSD make does it like this. -echo '.include "confinc.mk" # ignored' > confmf.BSD -# Other make implementations (GNU, Solaris 10, AIX) do it like this. -echo 'include confinc.mk # ignored' > confmf.GNU -_am_result=no -for s in GNU BSD; do - { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 - (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } - case $?:`cat confinc.out 2>/dev/null` in #( - '0:this is the am__doit target') : - case $s in #( - BSD) : - am__include='.include' am__quote='"' ;; #( - *) : - am__include='include' am__quote='' ;; -esac ;; #( - *) : - ;; +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; esac - if test "$am__include" != "#"; then - _am_result="yes ($s style)" - break - fi -done -rm -f confinc.* confmf.* -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 -$as_echo "${_am_result}" >&6; } +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : @@ -7179,7 +7191,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else @@ -10881,6 +10893,9 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs=no + ;; esac ld_shlibs=yes @@ -11135,7 +11150,7 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -11805,6 +11820,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then 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' fi + link_all_deplibs=no else 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' 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' @@ -11826,7 +11842,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -12921,9 +12937,6 @@ fi # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command @@ -12932,7 +12945,7 @@ fi # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then 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' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -12944,6 +12957,18 @@ fi dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -15838,7 +15863,7 @@ lt_prog_compiler_static_CXX= ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -16213,6 +16238,9 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie ;; esac ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs_CXX=no + ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; @@ -16886,9 +16914,6 @@ fi # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command @@ -16897,7 +16922,7 @@ fi # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then 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' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -16909,6 +16934,18 @@ fi dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -17335,7 +17372,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) +#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; @@ -17381,7 +17418,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) +#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; @@ -17405,7 +17442,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) +#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; @@ -17450,7 +17487,7 @@ else We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) +#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; @@ -17474,7 +17511,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext We can't simply define LARGE_OFF_T to be 9223372036854775807, since some C++ compilers masquerading as C compilers incorrectly reject 9223372036854775807. */ -#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) +#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 && LARGE_OFF_T % 2147483647 == 1) ? 1 : -1]; @@ -23835,7 +23872,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # -AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" # The HP-UX ksh and POSIX shell print the target directory to stdout @@ -24834,35 +24871,29 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. - # TODO: see whether this extra hack can be removed once we start - # requiring Autoconf 2.70 or later. - case $CONFIG_FILES in #( - *\'*) : - eval set x "$CONFIG_FILES" ;; #( - *) : - set x $CONFIG_FILES ;; #( - *) : - ;; -esac + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac shift - # Used to flag and report bootstrapping failures. - am_rc=0 - for am_mf + for mf do # Strip MF so we end up with the name of the file. - am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile which includes - # dependency-tracking related rules and includes. - # Grep'ing the whole file directly is not great: AIX grep has a line + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. - sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ - || continue - am_dirpart=`$as_dirname -- "$am_mf" || -$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$am_mf" : 'X\(//\)[^/]' \| \ - X"$am_mf" : 'X\(//\)$' \| \ - X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$am_mf" | + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -24880,48 +24911,53 @@ $as_echo X"$am_mf" | q } s/.*/./; q'` - am_filepart=`$as_basename -- "$am_mf" || -$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ - X"$am_mf" : 'X\(//\)$' \| \ - X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$am_mf" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } - /^X\/\(\/\/\)$/{ + /^X\(\/\/\)[^/].*/{ s//\1/ q } - /^X\/\(\/\).*/{ + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` - { echo "$as_me:$LINENO: cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles" >&5 - (cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } || am_rc=$? + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done done - if test $am_rc -ne 0; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. Try re-running configure with the - '--disable-dependency-tracking' option to at least be able to build - the package (albeit without support for automatic dependency tracking). -See \`config.log' for more details" "$LINENO" 5; } - fi - { am_dirpart=; unset am_dirpart;} - { am_filepart=; unset am_filepart;} - { am_mf=; unset am_mf;} - { am_rc=; unset am_rc;} - rm -f conftest-deps.mk } ;; "libtool":C) @@ -24939,7 +24975,6 @@ See \`config.log' for more details" "$LINENO" 5; } cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. diff --git a/hawk/lib/Makefile.am b/hawk/lib/Makefile.am index 0d2f126d..d1b9c6e5 100644 --- a/hawk/lib/Makefile.am +++ b/hawk/lib/Makefile.am @@ -79,6 +79,7 @@ libhawk_la_SOURCES = \ ecs.c \ err-prv.h \ err.c \ + err-sys.c \ fmt-imp.h \ fmt.c \ fnc-prv.h \ @@ -143,7 +144,6 @@ libhawk_la_SOURCES += \ pio.c \ sio.c \ syscall.h \ - syserr.h \ tio.c \ std-prv.h \ std.c diff --git a/hawk/lib/Makefile.in b/hawk/lib/Makefile.in index 54e48b50..7d7947ea 100644 --- a/hawk/lib/Makefile.in +++ b/hawk/lib/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -164,36 +164,36 @@ am__DEPENDENCIES_4 = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) \ am__libhawk_la_SOURCES_DIST = hawk.h hawk-chr.h hawk-cmn.h hawk-dir.h \ hawk-ecs.h hawk-fmt.h hawk-gem.h hawk-htb.h hawk-rbt.h \ hawk-pack1.h hawk-utl.h hawk-std.h hawk-tre.h hawk-unpack.h \ - arr.c chr.c dir.c ecs-imp.h ecs.c err-prv.h err.c fmt-imp.h \ - fmt.c fnc-prv.h fnc.c htb.c gem.c gem-skad.c gem-nwif.c \ - gem-nwif2.c hawk-prv.h hawk.c mb8.c misc-prv.h misc.c \ - parse-prv.h parse.c rbt.c rec.c rio-prv.h rio.c run-prv.h \ - run.c tre-prv.h tre-ast.c tre-ast.h tre-compile.c \ + arr.c chr.c dir.c ecs-imp.h ecs.c err-prv.h err.c err-sys.c \ + fmt-imp.h fmt.c fnc-prv.h fnc.c htb.c gem.c gem-skad.c \ + gem-nwif.c gem-nwif2.c hawk-prv.h hawk.c mb8.c misc-prv.h \ + misc.c parse-prv.h parse.c rbt.c rec.c rio-prv.h rio.c \ + run-prv.h run.c tre-prv.h tre-ast.c tre-ast.h tre-compile.c \ tre-compile.h tre-match-bt.c tre-match-pa.c tre-match-ut.h \ tre-mem.c tre-mem.h tre-parse.c tre-parse.h tre-stack.c \ tre-stack.h tre.c tree-prv.h tree.c utf16.c utf8.c utl-ass.c \ utl-skad.c utl-skad.h utl-sort.c utl-str.c utl-sys.c utl.c \ val-prv.h val.c hawk-cli.h hawk-fio.h hawk-mtx.h hawk-pio.h \ hawk-sio.h hawk-tio.h cli.c fio.c mtx.c pio.c sio.c syscall.h \ - syserr.h tio.c std-prv.h std.c imap-imp.h mod-math.c \ - mod-math.h mod-str.c mod-str.h mod-sys.c mod-sys.h + tio.c std-prv.h std.c imap-imp.h mod-math.c mod-math.h \ + mod-str.c mod-str.h mod-sys.c mod-sys.h am__objects_1 = @ENABLE_STATIC_MODULE_TRUE@am__objects_2 = libhawk_la-mod-math.lo \ @ENABLE_STATIC_MODULE_TRUE@ libhawk_la-mod-str.lo \ @ENABLE_STATIC_MODULE_TRUE@ libhawk_la-mod-sys.lo am_libhawk_la_OBJECTS = $(am__objects_1) libhawk_la-arr.lo \ libhawk_la-chr.lo libhawk_la-dir.lo libhawk_la-ecs.lo \ - libhawk_la-err.lo libhawk_la-fmt.lo libhawk_la-fnc.lo \ - libhawk_la-htb.lo libhawk_la-gem.lo libhawk_la-gem-skad.lo \ - libhawk_la-gem-nwif.lo libhawk_la-gem-nwif2.lo \ - libhawk_la-hawk.lo libhawk_la-mb8.lo libhawk_la-misc.lo \ - libhawk_la-parse.lo libhawk_la-rbt.lo libhawk_la-rec.lo \ - libhawk_la-rio.lo libhawk_la-run.lo libhawk_la-tre-ast.lo \ - libhawk_la-tre-compile.lo libhawk_la-tre-match-bt.lo \ - libhawk_la-tre-match-pa.lo libhawk_la-tre-mem.lo \ - libhawk_la-tre-parse.lo libhawk_la-tre-stack.lo \ - libhawk_la-tre.lo libhawk_la-tree.lo libhawk_la-utf16.lo \ - libhawk_la-utf8.lo libhawk_la-utl-ass.lo \ + libhawk_la-err.lo libhawk_la-err-sys.lo libhawk_la-fmt.lo \ + libhawk_la-fnc.lo libhawk_la-htb.lo libhawk_la-gem.lo \ + libhawk_la-gem-skad.lo libhawk_la-gem-nwif.lo \ + libhawk_la-gem-nwif2.lo libhawk_la-hawk.lo libhawk_la-mb8.lo \ + libhawk_la-misc.lo libhawk_la-parse.lo libhawk_la-rbt.lo \ + libhawk_la-rec.lo libhawk_la-rio.lo libhawk_la-run.lo \ + libhawk_la-tre-ast.lo libhawk_la-tre-compile.lo \ + libhawk_la-tre-match-bt.lo libhawk_la-tre-match-pa.lo \ + libhawk_la-tre-mem.lo libhawk_la-tre-parse.lo \ + libhawk_la-tre-stack.lo libhawk_la-tre.lo libhawk_la-tree.lo \ + libhawk_la-utf16.lo libhawk_la-utf8.lo libhawk_la-utl-ass.lo \ libhawk_la-utl-skad.lo libhawk_la-utl-sort.lo \ libhawk_la-utl-str.lo libhawk_la-utl-sys.lo libhawk_la-utl.lo \ libhawk_la-val.lo libhawk_la-cli.lo libhawk_la-fio.lo \ @@ -229,45 +229,7 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = depcomp = $(SHELL) $(top_srcdir)/ac/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/libhawk_la-arr.Plo \ - ./$(DEPDIR)/libhawk_la-chr.Plo ./$(DEPDIR)/libhawk_la-cli.Plo \ - ./$(DEPDIR)/libhawk_la-dir.Plo ./$(DEPDIR)/libhawk_la-ecs.Plo \ - ./$(DEPDIR)/libhawk_la-err.Plo ./$(DEPDIR)/libhawk_la-fio.Plo \ - ./$(DEPDIR)/libhawk_la-fmt.Plo ./$(DEPDIR)/libhawk_la-fnc.Plo \ - ./$(DEPDIR)/libhawk_la-gem-nwif.Plo \ - ./$(DEPDIR)/libhawk_la-gem-nwif2.Plo \ - ./$(DEPDIR)/libhawk_la-gem-skad.Plo \ - ./$(DEPDIR)/libhawk_la-gem.Plo ./$(DEPDIR)/libhawk_la-hawk.Plo \ - ./$(DEPDIR)/libhawk_la-htb.Plo ./$(DEPDIR)/libhawk_la-mb8.Plo \ - ./$(DEPDIR)/libhawk_la-misc.Plo \ - ./$(DEPDIR)/libhawk_la-mod-math.Plo \ - ./$(DEPDIR)/libhawk_la-mod-str.Plo \ - ./$(DEPDIR)/libhawk_la-mod-sys.Plo \ - ./$(DEPDIR)/libhawk_la-mtx.Plo \ - ./$(DEPDIR)/libhawk_la-parse.Plo \ - ./$(DEPDIR)/libhawk_la-pio.Plo ./$(DEPDIR)/libhawk_la-rbt.Plo \ - ./$(DEPDIR)/libhawk_la-rec.Plo ./$(DEPDIR)/libhawk_la-rio.Plo \ - ./$(DEPDIR)/libhawk_la-run.Plo ./$(DEPDIR)/libhawk_la-sio.Plo \ - ./$(DEPDIR)/libhawk_la-std.Plo ./$(DEPDIR)/libhawk_la-tio.Plo \ - ./$(DEPDIR)/libhawk_la-tre-ast.Plo \ - ./$(DEPDIR)/libhawk_la-tre-compile.Plo \ - ./$(DEPDIR)/libhawk_la-tre-match-bt.Plo \ - ./$(DEPDIR)/libhawk_la-tre-match-pa.Plo \ - ./$(DEPDIR)/libhawk_la-tre-mem.Plo \ - ./$(DEPDIR)/libhawk_la-tre-parse.Plo \ - ./$(DEPDIR)/libhawk_la-tre-stack.Plo \ - ./$(DEPDIR)/libhawk_la-tre.Plo ./$(DEPDIR)/libhawk_la-tree.Plo \ - ./$(DEPDIR)/libhawk_la-utf16.Plo \ - ./$(DEPDIR)/libhawk_la-utf8.Plo \ - ./$(DEPDIR)/libhawk_la-utl-ass.Plo \ - ./$(DEPDIR)/libhawk_la-utl-skad.Plo \ - ./$(DEPDIR)/libhawk_la-utl-sort.Plo \ - ./$(DEPDIR)/libhawk_la-utl-str.Plo \ - ./$(DEPDIR)/libhawk_la-utl-sys.Plo \ - ./$(DEPDIR)/libhawk_la-utl.Plo ./$(DEPDIR)/libhawk_la-val.Plo \ - ./$(DEPDIR)/libhawkxx_la-Hawk.Plo \ - ./$(DEPDIR)/libhawkxx_la-StdHawk.Plo +am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -492,6 +454,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -543,9 +506,9 @@ pkginclude_HEADERS = \ pkglib_LTLIBRARIES = libhawk.la $(am__append_5) libhawk_la_SOURCES = $(pkginclude_HEADERS) arr.c chr.c dir.c ecs-imp.h \ - ecs.c err-prv.h err.c fmt-imp.h fmt.c fnc-prv.h fnc.c htb.c \ - gem.c gem-skad.c gem-nwif.c gem-nwif2.c hawk-prv.h hawk.c \ - mb8.c misc-prv.h misc.c parse-prv.h parse.c rbt.c rec.c \ + ecs.c err-prv.h err.c err-sys.c fmt-imp.h fmt.c fnc-prv.h \ + fnc.c htb.c gem.c gem-skad.c gem-nwif.c gem-nwif2.c hawk-prv.h \ + hawk.c mb8.c misc-prv.h misc.c parse-prv.h parse.c rbt.c rec.c \ rio-prv.h rio.c run-prv.h run.c tre-prv.h tre-ast.c tre-ast.h \ tre-compile.c tre-compile.h tre-match-bt.c tre-match-pa.c \ tre-match-ut.h tre-mem.c tre-mem.h tre-parse.c tre-parse.h \ @@ -553,7 +516,7 @@ libhawk_la_SOURCES = $(pkginclude_HEADERS) arr.c chr.c dir.c ecs-imp.h \ utl-ass.c utl-skad.c utl-skad.h utl-sort.c utl-str.c utl-sys.c \ utl.c val-prv.h val.c hawk-cli.h hawk-fio.h hawk-mtx.h \ hawk-pio.h hawk-sio.h hawk-tio.h cli.c fio.c mtx.c pio.c sio.c \ - syscall.h syserr.h tio.c std-prv.h std.c $(am__append_6) + syscall.h tio.c std-prv.h std.c $(am__append_6) libhawk_la_CPPFLAGS = $(CPPFLAGS_LIB_COMMON) libhawk_la_LDFLAGS = $(LDFLAGS_LIB_COMMON) libhawk_la_LIBADD = $(LIBADD_LIB_COMMON) $(am__append_7) \ @@ -595,8 +558,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -670,62 +633,57 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-arr.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-chr.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-cli.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-dir.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-ecs.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-err.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fio.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fmt.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fnc.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-nwif.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-nwif2.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-skad.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-hawk.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-htb.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mb8.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-misc.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-math.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-str.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-sys.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mtx.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-parse.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-pio.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rbt.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rec.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rio.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-run.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-sio.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-std.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tio.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-ast.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-compile.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-match-bt.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-match-pa.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-mem.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-parse.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-stack.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tree.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utf16.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utf8.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-ass.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-skad.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-sort.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-str.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-sys.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-val.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawkxx_la-Hawk.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawkxx_la-StdHawk.Plo@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-arr.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-chr.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-cli.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-dir.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-ecs.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-err-sys.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-err.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fio.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fmt.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-fnc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-nwif.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-nwif2.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem-skad.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-gem.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-hawk.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-htb.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mb8.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-misc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-math.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-str.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mod-sys.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-mtx.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-parse.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-pio.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rbt.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rec.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-rio.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-run.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-sio.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-std.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tio.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-ast.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-compile.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-match-bt.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-match-pa.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-mem.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-parse.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre-stack.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tre.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-tree.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utf16.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utf8.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-ass.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-skad.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-sort.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-str.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl-sys.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-utl.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_la-val.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawkxx_la-Hawk.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawkxx_la-StdHawk.Plo@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @@ -786,6 +744,13 @@ libhawk_la-err.lo: err.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libhawk_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libhawk_la-err.lo `test -f 'err.c' || echo '$(srcdir)/'`err.c +libhawk_la-err-sys.lo: err-sys.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libhawk_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libhawk_la-err-sys.lo -MD -MP -MF $(DEPDIR)/libhawk_la-err-sys.Tpo -c -o libhawk_la-err-sys.lo `test -f 'err-sys.c' || echo '$(srcdir)/'`err-sys.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhawk_la-err-sys.Tpo $(DEPDIR)/libhawk_la-err-sys.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='err-sys.c' object='libhawk_la-err-sys.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libhawk_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libhawk_la-err-sys.lo `test -f 'err-sys.c' || echo '$(srcdir)/'`err-sys.c + libhawk_la-fmt.lo: fmt.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libhawk_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libhawk_la-fmt.lo -MD -MP -MF $(DEPDIR)/libhawk_la-fmt.Tpo -c -o libhawk_la-fmt.lo `test -f 'fmt.c' || echo '$(srcdir)/'`fmt.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libhawk_la-fmt.Tpo $(DEPDIR)/libhawk_la-fmt.Plo @@ -1204,10 +1169,7 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -1280,56 +1242,7 @@ clean-am: clean-generic clean-libtool clean-pkglibLTLIBRARIES \ mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/libhawk_la-arr.Plo - -rm -f ./$(DEPDIR)/libhawk_la-chr.Plo - -rm -f ./$(DEPDIR)/libhawk_la-cli.Plo - -rm -f ./$(DEPDIR)/libhawk_la-dir.Plo - -rm -f ./$(DEPDIR)/libhawk_la-ecs.Plo - -rm -f ./$(DEPDIR)/libhawk_la-err.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fmt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fnc.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-nwif.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-nwif2.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-skad.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem.Plo - -rm -f ./$(DEPDIR)/libhawk_la-hawk.Plo - -rm -f ./$(DEPDIR)/libhawk_la-htb.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mb8.Plo - -rm -f ./$(DEPDIR)/libhawk_la-misc.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-math.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-str.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-sys.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mtx.Plo - -rm -f ./$(DEPDIR)/libhawk_la-parse.Plo - -rm -f ./$(DEPDIR)/libhawk_la-pio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rbt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rec.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-run.Plo - -rm -f ./$(DEPDIR)/libhawk_la-sio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-std.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-ast.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-compile.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-match-bt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-match-pa.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-mem.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-parse.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-stack.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tree.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utf16.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utf8.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-ass.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-skad.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-sort.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-str.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-sys.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl.Plo - -rm -f ./$(DEPDIR)/libhawk_la-val.Plo - -rm -f ./$(DEPDIR)/libhawkxx_la-Hawk.Plo - -rm -f ./$(DEPDIR)/libhawkxx_la-StdHawk.Plo + -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-tags @@ -1375,56 +1288,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/libhawk_la-arr.Plo - -rm -f ./$(DEPDIR)/libhawk_la-chr.Plo - -rm -f ./$(DEPDIR)/libhawk_la-cli.Plo - -rm -f ./$(DEPDIR)/libhawk_la-dir.Plo - -rm -f ./$(DEPDIR)/libhawk_la-ecs.Plo - -rm -f ./$(DEPDIR)/libhawk_la-err.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fmt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-fnc.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-nwif.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-nwif2.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem-skad.Plo - -rm -f ./$(DEPDIR)/libhawk_la-gem.Plo - -rm -f ./$(DEPDIR)/libhawk_la-hawk.Plo - -rm -f ./$(DEPDIR)/libhawk_la-htb.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mb8.Plo - -rm -f ./$(DEPDIR)/libhawk_la-misc.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-math.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-str.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mod-sys.Plo - -rm -f ./$(DEPDIR)/libhawk_la-mtx.Plo - -rm -f ./$(DEPDIR)/libhawk_la-parse.Plo - -rm -f ./$(DEPDIR)/libhawk_la-pio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rbt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rec.Plo - -rm -f ./$(DEPDIR)/libhawk_la-rio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-run.Plo - -rm -f ./$(DEPDIR)/libhawk_la-sio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-std.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tio.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-ast.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-compile.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-match-bt.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-match-pa.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-mem.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-parse.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre-stack.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tre.Plo - -rm -f ./$(DEPDIR)/libhawk_la-tree.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utf16.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utf8.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-ass.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-skad.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-sort.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-str.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl-sys.Plo - -rm -f ./$(DEPDIR)/libhawk_la-utl.Plo - -rm -f ./$(DEPDIR)/libhawk_la-val.Plo - -rm -f ./$(DEPDIR)/libhawkxx_la-Hawk.Plo - -rm -f ./$(DEPDIR)/libhawkxx_la-StdHawk.Plo + -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -1445,15 +1309,15 @@ uninstall-am: uninstall-pkgincludeHEADERS uninstall-pkglibLTLIBRARIES .MAKE: all install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-generic clean-libtool clean-pkglibLTLIBRARIES \ - cscopelist-am ctags ctags-am distclean distclean-compile \ - distclean-generic distclean-hdr distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-pkgincludeHEADERS \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-pkglibLTLIBRARIES cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-hdr distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-pkgincludeHEADERS \ install-pkglibLTLIBRARIES install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ diff --git a/hawk/lib/dir.c b/hawk/lib/dir.c index c9406256..d37af69e 100644 --- a/hawk/lib/dir.c +++ b/hawk/lib/dir.c @@ -87,9 +87,6 @@ static void close_dir_safely (hawk_dir_t* dir); static int reset_to_path (hawk_dir_t* dir, const hawk_ooch_t* path); static int read_ahead_and_sort (hawk_dir_t* dir, const hawk_ooch_t* path); -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - hawk_dir_t* hawk_dir_open (hawk_gem_t* gem, hawk_oow_t xtnsize, const hawk_ooch_t* path, int flags) { hawk_dir_t* dir; @@ -420,7 +417,7 @@ static int reset_to_path (hawk_dir_t* dir, const hawk_ooch_t* path) dir->h = FindFirstFile(tptr, &dir->wfd); if (dir->h == INVALID_HANDLE_VALUE) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -467,7 +464,7 @@ static int reset_to_path (hawk_dir_t* dir, const hawk_ooch_t* path) if (rc != NO_ERROR) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -503,7 +500,7 @@ static int reset_to_path (hawk_dir_t* dir, const hawk_ooch_t* path) rc = _dos_findfirst(mptr, _A_NORMAL | _A_SUBDIR, &dir->f); if (rc != 0) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL,syserr_to_errnum(errno)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL,hawk_syserr_to_errnum(errno)); return -1; } @@ -542,7 +539,7 @@ static int reset_to_path (hawk_dir_t* dir, const hawk_ooch_t* path) if (dp == HAWK_NULL) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -595,7 +592,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) } else { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum(x)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(x)); dir->status |= STATUS_DONE; dir->status |= STATUS_DONE_ERR; return -1; @@ -630,7 +627,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) if (x == ERROR_NO_MORE_FILES) dir->status |= STATUS_DONE; else { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (x)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(x)); dir->status |= STATUS_DONE; dir->status |= STATUS_DONE_ERR; } @@ -659,7 +656,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) } else if (rc != NO_ERROR) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (rc)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } } @@ -682,7 +679,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) if (rc == ERROR_NO_MORE_FILES) dir->count = 0; else if (rc != NO_ERROR) { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (rc)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -709,7 +706,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) } else { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (errno)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); dir->status |= STATUS_DONE; dir->status |= STATUS_DONE_ERR; return -1; @@ -736,7 +733,7 @@ static int read_dir_to_buf (hawk_dir_t* dir, void** name) if (errno == ENOENT) dir->status |= STATUS_DONE; else { - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (errno)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); dir->status |= STATUS_DONE; dir->status |= STATUS_DONE_ERR; } @@ -756,7 +753,7 @@ read: if (de == NULL) { if (errno == 0) return 0; - hawk_gem_seterrnum (dir->gem, HAWK_NULL, syserr_to_errnum (errno)); + hawk_gem_seterrnum (dir->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } diff --git a/hawk/lib/err-prv.h b/hawk/lib/err-prv.h index 1558e21c..5cb8e039 100644 --- a/hawk/lib/err-prv.h +++ b/hawk/lib/err-prv.h @@ -33,6 +33,9 @@ extern "C" { const hawk_ooch_t* hawk_dflerrstr (hawk_t* awk, hawk_errnum_t errnum); +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e); + + #if defined(__cplusplus) } #endif diff --git a/hawk/lib/err-sys.c b/hawk/lib/err-sys.c new file mode 100644 index 00000000..77468b04 --- /dev/null +++ b/hawk/lib/err-sys.c @@ -0,0 +1,198 @@ +/* + * $Id$ + * + Copyright (c) 2006-2019 Chung, Hyung-Hwan. All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include + +#if defined(_WIN32) +# include +#elif defined(__OS2__) +# define INCL_DOSERRORS +# include +#elif defined(vms) || defined(__vms) +# define __NEW_STARLET 1 +# include +# include +#elif defined(__DOS__) +# include +#else +# include +#endif + + +#if defined(_WIN32) + +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e) /* actually DWORD */ +{ + switch (e) + { + case ERROR_NOT_ENOUGH_MEMORY: + case ERROR_OUTOFMEMORY: + return HAWK_ENOMEM; + case ERROR_INVALID_PARAMETER: + case ERROR_INVALID_HANDLE: + case ERROR_INVALID_NAME: + return HAWK_EINVAL; + case ERROR_ACCESS_DENIED: + case ERROR_SHARING_VIOLATION: + return HAWK_EACCES; + case ERROR_FILE_NOT_FOUND: + case ERROR_PATH_NOT_FOUND: + return HAWK_ENOENT; + case ERROR_ALREADY_EXISTS: + case ERROR_FILE_EXISTS: + return HAWK_EEXIST; + case ERROR_BROKEN_PIPE: + return HAWK_EPIPE; + default: + return HAWK_ESYSERR; + } +} + +#elif defined(__OS2__) + +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e) /* actually APIRET */ +{ + switch (e) + { + case ERROR_NOT_ENOUGH_MEMORY: + return HAWK_ENOMEM; + case ERROR_INVALID_PARAMETER: + case ERROR_INVALID_HANDLE: + case ERROR_INVALID_NAME: + return HAWK_EINVAL; + case ERROR_ACCESS_DENIED: + case ERROR_SHARING_VIOLATION: + return HAWK_EACCES; + case ERROR_FILE_NOT_FOUND: + case ERROR_PATH_NOT_FOUND: + return HAWK_ENOENT; + case ERROR_ALREADY_EXISTS: + return HAWK_EEXIST; + case ERROR_BROKEN_PIPE: + return HAWK_EPIPE; + default: + return HAWK_ESYSERR; + } +} + +#elif defined(__DOS__) + +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e) +{ + switch (e) + { + case ENOMEM: return HAWK_ENOMEM; + case EINVAL: return HAWK_EINVAL; + case EACCES: return HAWK_EACCES; + case ENOENT: return HAWK_ENOENT; + case EEXIST: return HAWK_EEXIST; + default: return HAWK_ESYSERR; + } +} + +#elif defined(vms) || defined(__vms) + + /* TODO: */ +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e) /* actually unsigned long */ +{ + switch (e) + { + case RMS$_NORMAL: return HAWK_ENOERR; + default: return HAWK_ESYSERR; + } +} + +#else + +hawk_errnum_t hawk_syserr_to_errnum (hawk_intptr_t e) +{ + switch (e) + { + #if defined(ENOMEM) + case ENOMEM: return HAWK_ENOMEM; + #endif + #if defined(EINVAL) + case EINVAL: return HAWK_EINVAL; + #endif + #if defined(EBUSY) + case EBUSY: return HAWK_EBUSY; + #endif + #if defined(EACCES) + case EACCES: return HAWK_EACCES; + #endif + #if defined(EPERM) + case EPERM: return HAWK_EPERM; + #endif + #if defined(EISDIR) + case EISDIR: return HAWK_EISDIR; + #endif + #if defined(ENOTDIR) + case ENOTDIR: return HAWK_ENOTDIR; + #endif + #if defined(ENXIO) + case ENXIO: return HAWK_ENOENT; /* ENODEV mapped to ENOENT */ + #endif + #if defined(ENODEV) + case ENODEV: return HAWK_ENOENT; /* ENODEV mapped to ENOENT */ + #endif + #if defined(ENOENT) + case ENOENT: return HAWK_ENOENT; + #endif + #if defined(EEXIST) + case EEXIST: return HAWK_EEXIST; + #endif + #if defined(EINTR) + case EINTR: return HAWK_EINTR; + #endif + #if defined(EPIPE) + case EPIPE: return HAWK_EPIPE; + #endif + #if defined(ECHILD) + case ECHILD: return HAWK_ECHILD; + #endif + #if defined(ETIMEDOUT) + case ETIMEDOUT: return HAWK_ETMOUT; + #endif + #if defined(EINPROGRESS) + case EINPROGRESS: return HAWK_EINPROG; + #endif + + #if defined(EWOULDBLOCK) && defined(EAGAIN) && (EWOULDBLOCK == EAGAIN) + case EAGAIN: return HAWK_EAGAIN; + #else + #if defined(EWOULDBLOCK) + case EWOULDBLOCK: return HAWK_EAGAIN; + #endif + #if defined(EAGAIN) + case EAGAIN: return HAWK_EAGAIN; + #endif + #endif + default: return HAWK_ESYSERR; + } +} + + +#endif diff --git a/hawk/lib/err.c b/hawk/lib/err.c index 34e8251a..1f4c35a0 100644 --- a/hawk/lib/err.c +++ b/hawk/lib/err.c @@ -655,3 +655,4 @@ void hawk_gem_seterrufmt (hawk_gem_t* gem, const hawk_loc_t* errloc, hawk_errnum gem->errnum = errnum; gem->errloc = (errloc? *errloc: _nullloc); } + diff --git a/hawk/lib/fio.c b/hawk/lib/fio.c index 18f4aa55..7bef18ea 100644 --- a/hawk/lib/fio.c +++ b/hawk/lib/fio.c @@ -60,9 +60,6 @@ enum STATUS_WIN32_STDIN = (1 << 2) }; -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - #if defined(_WIN32) typedef DWORD WINAPI (*getmappedfilename_t) ( @@ -312,13 +309,13 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in } if (handle == INVALID_HANDLE_VALUE) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } } else { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); return -1; } } @@ -328,7 +325,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in #if 0 if (GetFileType(handle) == FILE_TYPE_UNKNOWN) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); CloseHandle (handle); return -1; } @@ -463,7 +460,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return -1; } } @@ -549,7 +546,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in if (handle <= -1) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } } @@ -652,7 +649,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in #else if (path_mb != path_mb_buf) hawk_gem_freemem (fio->gem, path_mb); #endif - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(r0)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(r0)); return -1; } @@ -665,7 +662,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in #else if (path_mb != path_mb_buf) hawk_gem_freemem (fio->gem, path_mb); #endif - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(r0)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(r0)); return -1; } @@ -771,7 +768,7 @@ int hawk_fio_init (hawk_fio_t* fio, hawk_gem_t* gem, const hawk_ooch_t* path, in #endif if (handle == -1) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } else @@ -859,7 +856,7 @@ hawk_fio_off_t hawk_fio_seek (hawk_fio_t* fio, hawk_fio_off_t offset, hawk_fio_o fio->handle, x.LowPart, &x.HighPart, seek_map[origin]); if (x.LowPart == INVALID_SET_FILE_POINTER && GetLastError() != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return (hawk_fio_off_t)-1; } return (hawk_fio_off_t)x.QuadPart; @@ -887,7 +884,7 @@ hawk_fio_off_t hawk_fio_seek (hawk_fio_t* fio, hawk_fio_off_t offset, hawk_fio_o ret = dos_set_file_ptr_l (fio->handle, pos, seek_map[origin], &newpos); if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return (hawk_fio_off_t)-1; } @@ -902,7 +899,7 @@ hawk_fio_off_t hawk_fio_seek (hawk_fio_t* fio, hawk_fio_off_t offset, hawk_fio_o ret = DosSetFilePtr (fio->handle, offset, seek_map[origin], &newpos); if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return (hawk_fio_off_t)-1; } @@ -942,7 +939,7 @@ hawk_fio_off_t hawk_fio_seek (hawk_fio_t* fio, hawk_fio_off_t offset, hawk_fio_o &tmp, seek_map[origin]) == -1) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return (hawk_fio_off_t)-1; } @@ -960,7 +957,7 @@ int hawk_fio_truncate (hawk_fio_t* fio, hawk_fio_off_t size) if (hawk_fio_seek (fio, size, HAWK_FIO_BEGIN) == (hawk_fio_off_t)-1) return -1; if (SetEndOfFile(fio->handle) == FALSE) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return 0; @@ -989,7 +986,7 @@ int hawk_fio_truncate (hawk_fio_t* fio, hawk_fio_off_t size) if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return -1; } return 0; @@ -998,7 +995,7 @@ int hawk_fio_truncate (hawk_fio_t* fio, hawk_fio_off_t size) int n; n = chsize (fio->handle, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #elif defined(vms) || defined(__vms) @@ -1009,7 +1006,7 @@ int hawk_fio_truncate (hawk_fio_t* fio, hawk_fio_off_t size) if ((r0 = sys$rewind (rab, 0, 0)) != RMS$_NORMAL || (r0 = sys$truncate (rab, 0, 0)) != RMS$_NORMAL) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(r0)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(r0)); return -1; } @@ -1019,7 +1016,7 @@ int hawk_fio_truncate (hawk_fio_t* fio, hawk_fio_off_t size) int n; n = HAWK_FTRUNCATE (fio->handle, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #else @@ -1044,7 +1041,7 @@ hawk_ooi_t hawk_fio_read (hawk_fio_t* fio, void* buf, hawk_oow_t size) * assuming that ERROR_BROKEN_PIPE doesn't occur with normal * input streams, i treat the condition as a normal EOF indicator. */ if ((fio->status & STATUS_WIN32_STDIN) && e == ERROR_BROKEN_PIPE) return 0; - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); return -1; } return (hawk_ooi_t)count; @@ -1058,7 +1055,7 @@ hawk_ooi_t hawk_fio_read (hawk_fio_t* fio, void* buf, hawk_oow_t size) ret = DosRead (fio->handle, buf, (ULONG)size, &count); if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return -1; } return (hawk_ooi_t)count; @@ -1069,7 +1066,7 @@ hawk_ooi_t hawk_fio_read (hawk_fio_t* fio, void* buf, hawk_oow_t size) if (size > (HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int))) size = HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int); n = read (fio->handle, buf, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #elif defined(vms) || defined(__vms) @@ -1085,7 +1082,7 @@ hawk_ooi_t hawk_fio_read (hawk_fio_t* fio, void* buf, hawk_oow_t size) r0 = sys$get (rab, 0, 0); if (r0 != RMS$_NORMAL) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(r0)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(r0)); return -1; } @@ -1095,7 +1092,7 @@ hawk_ooi_t hawk_fio_read (hawk_fio_t* fio, void* buf, hawk_oow_t size) hawk_ooi_t n; if (size > HAWK_TYPE_MAX(hawk_ooi_t)) size = HAWK_TYPE_MAX(hawk_ooi_t); n = HAWK_READ (fio->handle, buf, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #endif } @@ -1124,7 +1121,7 @@ hawk_ooi_t hawk_fio_write (hawk_fio_t* fio, const void* data, hawk_oow_t size) if (WriteFile (fio->handle, data, (DWORD)size, &count, HAWK_NULL) == FALSE) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return (hawk_ooi_t)count; @@ -1161,7 +1158,7 @@ hawk_ooi_t hawk_fio_write (hawk_fio_t* fio, const void* data, hawk_oow_t size) (PVOID)data, (ULONG)size, &count); if (ret != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(ret)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(ret)); return -1; } return (hawk_ooi_t)count; @@ -1172,7 +1169,7 @@ hawk_ooi_t hawk_fio_write (hawk_fio_t* fio, const void* data, hawk_oow_t size) if (size > (HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int))) size = HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int); n = write (fio->handle, data, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #elif defined(vms) || defined(__vms) @@ -1188,7 +1185,7 @@ hawk_ooi_t hawk_fio_write (hawk_fio_t* fio, const void* data, hawk_oow_t size) r0 = sys$put (rab, 0, 0); if (r0 != RMS$_NORMAL) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(r0)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(r0)); return -1; } @@ -1199,7 +1196,7 @@ hawk_ooi_t hawk_fio_write (hawk_fio_t* fio, const void* data, hawk_oow_t size) hawk_ooi_t n; if (size > HAWK_TYPE_MAX(hawk_ooi_t)) size = HAWK_TYPE_MAX(hawk_ooi_t); n = HAWK_WRITE (fio->handle, data, size); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #endif } @@ -1223,7 +1220,7 @@ static int get_devname_from_handle ( psapi = LoadLibrary (HAWK_T("PSAPI.DLL")); if (!psapi) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -1231,7 +1228,7 @@ static int get_devname_from_handle ( GetProcAddress (psapi, HAWK_BT("GetMappedFileName")); if (!getmappedfilename) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); FreeLibrary (psapi); return -1; } @@ -1247,7 +1244,7 @@ static int get_devname_from_handle ( ); if (map == NULL) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); FreeLibrary (psapi); return -1; } @@ -1256,7 +1253,7 @@ static int get_devname_from_handle ( mem = MapViewOfFile (map, FILE_MAP_READ, 0, 0, 1); if (mem == NULL) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); CloseHandle (map); FreeLibrary (psapi); return -1; @@ -1265,7 +1262,7 @@ static int get_devname_from_handle ( olen = getmappedfilename (GetCurrentProcess(), mem, buf, len); if (olen == 0) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); UnmapViewOfFile (mem); CloseHandle (map); FreeLibrary (psapi); @@ -1297,7 +1294,7 @@ static int get_volname_from_handle (hawk_fio_t* fio, hawk_ooch_t* buf, hawk_oow_ if (n == 0 /* error */ || n > HAWK_COUNTOF(drives) /* buffer small */) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -1348,7 +1345,7 @@ int hawk_fio_chmod (hawk_fio_t* fio, int mode) if (!(mode & HAWK_FIO_WUSR)) flags = FILE_ATTRIBUTE_READONLY; if (SetFileAttributes (name, flags) == FALSE) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return 0; @@ -1371,7 +1368,7 @@ int hawk_fio_chmod (hawk_fio_t* fio, int mode) #endif if (n != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } @@ -1385,7 +1382,7 @@ int hawk_fio_chmod (hawk_fio_t* fio, int mode) #endif if (n != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } @@ -1413,7 +1410,7 @@ int hawk_fio_chmod (hawk_fio_t* fio, int mode) #elif defined(HAVE_FCHMOD) int n; n = HAWK_FCHMOD (fio->handle, mode); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #else @@ -1429,7 +1426,7 @@ int hawk_fio_sync (hawk_fio_t* fio) if (FlushFileBuffers (fio->handle) == FALSE) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return 0; @@ -1440,7 +1437,7 @@ int hawk_fio_sync (hawk_fio_t* fio) n = DosResetBuffer (fio->handle); if (n != NO_ERROR) { - hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } return 0; @@ -1449,7 +1446,7 @@ int hawk_fio_sync (hawk_fio_t* fio) int n; n = fsync (fio->handle); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #elif defined(vms) || defined(__vms) @@ -1462,7 +1459,7 @@ int hawk_fio_sync (hawk_fio_t* fio) int n; n = HAWK_FSYNC(fio->handle); - if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (fio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #else hawk_gem_seterrnum (fio->gem, HAWK_NULL, HAWK_ENOIMPL); diff --git a/hawk/lib/gem-nwif.c b/hawk/lib/gem-nwif.c index 2b642294..e60d153a 100644 --- a/hawk/lib/gem-nwif.c +++ b/hawk/lib/gem-nwif.c @@ -49,9 +49,6 @@ # endif #endif -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - #if defined(SIOCGIFCONF) && (defined(SIOCGIFANUM) || defined(SIOCGIFNUM)) static int get_sco_ifconf (hawk_gem_t* gem, struct ifconf* ifc) { @@ -63,7 +60,7 @@ static int get_sco_ifconf (hawk_gem_t* gem, struct ifconf* ifc) h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -73,13 +70,13 @@ static int get_sco_ifconf (hawk_gem_t* gem, struct ifconf* ifc) #if defined(SIOCGIFANUM) if (ioctl(h, SIOCGIFANUM, &num) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } #else if (ioctl(h, SIOCGIFNUM, &num) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } #endif @@ -97,7 +94,7 @@ static int get_sco_ifconf (hawk_gem_t* gem, struct ifconf* ifc) if (ioctl(h, SIOCGIFCONF, ifc) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } HAWK_CLOSE (h); h = -1; @@ -140,7 +137,7 @@ int hawk_gem_bcstrtoifindex (hawk_gem_t* gem, const hawk_bch_t* ptr, unsigned in h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -173,7 +170,7 @@ int hawk_gem_bcstrtoifindex (hawk_gem_t* gem, const hawk_bch_t* ptr, unsigned in tmpidx = if_nametoindex(tmp); if (tmpidx == 0) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } *index = tmpidx; @@ -227,7 +224,7 @@ int hawk_gem_bcharstoifindex (hawk_gem_t* gem, const hawk_bch_t* ptr, hawk_oow_t h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -257,7 +254,7 @@ int hawk_gem_bcharstoifindex (hawk_gem_t* gem, const hawk_bch_t* ptr, hawk_oow_t tmpidx = if_nametoindex(tmp); if (tmpidx == 0) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } *index = tmpidx; @@ -311,7 +308,7 @@ int hawk_gem_ucstrtoifindex (hawk_gem_t* gem, const hawk_uch_t* ptr, unsigned in h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -343,7 +340,7 @@ int hawk_gem_ucstrtoifindex (hawk_gem_t* gem, const hawk_uch_t* ptr, unsigned in tmpidx = if_nametoindex(tmp); if (tmpidx == 0) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } *index = tmpidx; @@ -403,7 +400,7 @@ int hawk_gem_ucharstoifindex (hawk_gem_t* gem, const hawk_uch_t* ptr, hawk_oow_t h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -437,7 +434,7 @@ int hawk_gem_ucharstoifindex (hawk_gem_t* gem, const hawk_uch_t* ptr, hawk_oow_t tmpidx = if_nametoindex(tmp); if (tmpidx == 0) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } *index = tmpidx; @@ -498,7 +495,7 @@ int hawk_gem_ifindextobcstr (hawk_gem_t* gem, unsigned int index, hawk_bch_t* bu h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -514,7 +511,7 @@ int hawk_gem_ifindextobcstr (hawk_gem_t* gem, unsigned int index, hawk_bch_t* bu if (x <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -524,7 +521,7 @@ int hawk_gem_ifindextobcstr (hawk_gem_t* gem, unsigned int index, hawk_bch_t* bu hawk_bch_t tmp[IF_NAMESIZE + 1]; if (if_indextoname (index, tmp) == HAWK_NULL) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } return hawk_copy_bcstr(buf, len, tmp); @@ -579,7 +576,7 @@ int hawk_gem_ifindextoucstr (hawk_gem_t* gem, unsigned int index, hawk_uch_t* bu h = socket(AF_INET, SOCK_DGRAM, 0); if (h <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -595,7 +592,7 @@ int hawk_gem_ifindextoucstr (hawk_gem_t* gem, unsigned int index, hawk_uch_t* bu if (x <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -612,7 +609,7 @@ int hawk_gem_ifindextoucstr (hawk_gem_t* gem, unsigned int index, hawk_uch_t* bu if (if_indextoname(index, tmp) == HAWK_NULL) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } wl = len; diff --git a/hawk/lib/gem-nwif2.c b/hawk/lib/gem-nwif2.c index 0307a7e5..1a0fea5a 100644 --- a/hawk/lib/gem-nwif2.c +++ b/hawk/lib/gem-nwif2.c @@ -87,9 +87,6 @@ # endif #endif -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - #if defined(AF_INET6) static int prefix_to_in6 (int prefix, struct in6_addr* in6) { @@ -165,7 +162,7 @@ static int get_nwifs (hawk_gem_t* gem, int s, int f, hawk_xptl_t* nwifs) ifn.lifn_flags = 0; if (ioctl(s, SIOCGLIFNUM, &ifn) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } @@ -182,7 +179,7 @@ static int get_nwifs (hawk_gem_t* gem, int s, int f, hawk_xptl_t* nwifs) b.ptr = hawk_gem_allocmem(gem, b.len); if (b.ptr == HAWK_NULL) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } @@ -193,7 +190,7 @@ static int get_nwifs (hawk_gem_t* gem, int s, int f, hawk_xptl_t* nwifs) if (ioctl(s, SIOCGLIFCONF, &ifc) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } @@ -317,7 +314,7 @@ int hawk_gem_getifcfg (hawk_gem_t* gem, hawk_ifcfg_t* cfg) return 0; sys_oops: - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); oops: if (head) free_nwifcfg (cfg->mmgr, head); if (nwifs.ptr) hawk_gem_freemem (gem, nwifs.ptr); @@ -500,7 +497,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i #if defined(SIOCGIFINDEX) if (ioctl(s, SIOCGIFINDEX, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } #if defined(HAVE_STRUCT_IFREQ_IFR_IFINDEX) @@ -514,7 +511,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i if (ioctl(s, SIOCGIFFLAGS, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } cfg->flags = 0; @@ -525,7 +522,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i if (ioctl(s, SIOCGIFMTU, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } #if defined(HAVE_STRUCT_IFREQ_IFR_MTU) @@ -624,7 +621,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i #if defined(SIOCGIFINDEX) if (ioctl(s, SIOCGIFINDEX, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -640,7 +637,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i if (ioctl (s, SIOCGIFFLAGS, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } cfg->flags = 0; @@ -651,7 +648,7 @@ static int get_ifcfg (hawk_gem_t* gem, int s, hawk_ifcfg_t* cfg, struct ifreq* i if (ioctl(s, SIOCGIFMTU, ifr) <= -1) { - hawk_gem_seterrnum (gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } #if defined(HAVE_STRUCT_IFREQ_IFR_MTU) diff --git a/hawk/lib/hawk.c b/hawk/lib/hawk.c index cde02015..494f067d 100644 --- a/hawk/lib/hawk.c +++ b/hawk/lib/hawk.c @@ -50,7 +50,7 @@ static int init_token (hawk_t* hawk, hawk_tok_t* tok) { tok->name = hawk_ooecs_open(hawk_getgem(hawk), 0, 128); if (!tok->name) return -1; - + tok->type = 0; tok->loc.file = HAWK_NULL; tok->loc.line = 0; diff --git a/hawk/lib/mtx.c b/hawk/lib/mtx.c index 9767cd0b..48e2788b 100644 --- a/hawk/lib/mtx.c +++ b/hawk/lib/mtx.c @@ -50,9 +50,6 @@ # include #endif -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - hawk_mtx_t* hawk_mtx_open (hawk_gem_t* gem, hawk_oow_t xtnsize) { hawk_mtx_t* mtx; @@ -86,7 +83,7 @@ int hawk_mtx_init (hawk_mtx_t* mtx, hawk_gem_t* gem) mtx->hnd = CreateMutex(HAWK_NULL, FALSE, HAWK_NULL); if (mtx->hnd == HAWK_NULL) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -99,7 +96,7 @@ int hawk_mtx_init (hawk_mtx_t* mtx, hawk_gem_t* gem) rc = DosCreateMutexSem(HAWK_NULL, &m, DC_SEM_SHARED, FALSE); if (rc != NO_ERROR) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -128,7 +125,7 @@ int hawk_mtx_init (hawk_mtx_t* mtx, hawk_gem_t* gem) n = pthread_mutex_init((pthread_mutex_t*)&mtx->hnd, HAWK_NULL); if (n != 0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } } @@ -185,7 +182,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) } else if (ret != WAIT_OBJECT_0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } } @@ -193,7 +190,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) { if (WaitForSingleObject(mtx->hnd, INFINITE) == WAIT_FAILED) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } } @@ -207,7 +204,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) rc = DosRequestMutexSem(mtx->hnd, msec); if (rc != NO_ERROR) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } } @@ -217,7 +214,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) rc = DosRequestMutexSem(mtx->hnd, SEM_INDEFINITE_WAIT); if (rc != NO_ERROR) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } } @@ -244,7 +241,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) n = pthread_mutex_timedlock((pthread_mutex_t*)&mtx->hnd, &ts); if (n != 0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } } @@ -255,7 +252,7 @@ int hawk_mtx_lock (hawk_mtx_t* mtx, const hawk_ntime_t* waiting_time) n = pthread_mutex_lock((pthread_mutex_t*)&mtx->hnd); if (n != 0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } #if defined(HAVE_PTHREAD_MUTEX_TIMEDLOCK) @@ -271,7 +268,7 @@ int hawk_mtx_unlock (hawk_mtx_t* mtx) #if defined(_WIN32) if (ReleaseMutex(mtx->hnd) == FALSE) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -280,7 +277,7 @@ int hawk_mtx_unlock (hawk_mtx_t* mtx) rc = DosReleaseMutexSem(mtx->hnd); if (rc != NO_ERROR) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -293,7 +290,7 @@ int hawk_mtx_unlock (hawk_mtx_t* mtx) n = pthread_mutex_unlock((pthread_mutex_t*)&mtx->hnd); if (n != 0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } #endif @@ -305,7 +302,7 @@ int hawk_mtx_trylock (hawk_mtx_t* mtx) #if defined(_WIN32) if (WaitForSingleObject(mtx->hnd, 0) != WAIT_OBJECT_0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } #elif defined(__OS2__) @@ -313,7 +310,7 @@ int hawk_mtx_trylock (hawk_mtx_t* mtx) rc = DosRequestMutexSem(mtx->hnd, 0); if (rc != NO_ERROR) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -339,7 +336,7 @@ int hawk_mtx_trylock (hawk_mtx_t* mtx) #endif if (n != 0) { - hawk_gem_seterrnum (mtx->gem, HAWK_NULL, syserr_to_errnum(n)); + hawk_gem_seterrnum (mtx->gem, HAWK_NULL, hawk_syserr_to_errnum(n)); return -1; } /* -------------------------------------------------- */ diff --git a/hawk/lib/pio.c b/hawk/lib/pio.c index d95e83d2..0504a389 100644 --- a/hawk/lib/pio.c +++ b/hawk/lib/pio.c @@ -51,9 +51,6 @@ static hawk_ooi_t pio_input (hawk_tio_t* tio, hawk_tio_cmd_t cmd, void* buf, hawk_oow_t size); static hawk_ooi_t pio_output (hawk_tio_t* tio, hawk_tio_cmd_t cmd, void* buf, hawk_oow_t size); -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - #if !defined(_WIN32) && !defined(__OS2__) && !defined(__DOS__) static int get_highest_fd (hawk_pio_t* pio) { @@ -424,14 +421,14 @@ static int assert_executable (hawk_pio_t* pio, const hawk_bch_t* path) if (HAWK_ACCESS(path, X_OK) <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } /*if (HAWK_LSTAT(path, &st) <= -1)*/ if (HAWK_STAT(path, &st) <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -473,7 +470,7 @@ static hawk_pio_pid_t standard_fork_and_exec (hawk_pio_t* pio, int pipes[], para pid = HAWK_FORK(); if (pid <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return -1; } @@ -613,7 +610,7 @@ static int set_pipe_nonblock (hawk_pio_t* pio, hawk_pio_hnd_t fd, int enabled) int flag = HAWK_FCNTL (fd, F_GETFL, 0); if (flag >= 0) flag = HAWK_FCNTL (fd, F_SETFL, (enabled? (flag | O_NONBLOCK): (flag & ~O_NONBLOCK))); - if (flag <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (flag <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return flag; #else @@ -729,7 +726,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int /* child reads, parent writes */ if (CreatePipe(&handle[0], &handle[1], &secattr, 0) == FALSE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); goto oops; } @@ -741,7 +738,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int { /* SetHandleInformation() is not implemented on win9x. * so let's care only if it is implemented */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); goto oops; } } @@ -754,7 +751,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int /* child writes, parent reads */ if (CreatePipe(&handle[2], &handle[3], &secattr, 0) == FALSE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); goto oops; } @@ -766,7 +763,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int { /* SetHandleInformation() is not implemented on win9x. * so let's care only if it is implemented */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); goto oops; } } @@ -780,7 +777,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int /* child writes, parent reads */ if (CreatePipe(&handle[4], &handle[5], &secattr, 0) == FALSE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); goto oops; } @@ -792,7 +789,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int { /* SetHandleInformation() is not implemented on win9x. * so let's care only if it is implemented */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); goto oops; } } @@ -818,7 +815,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int ); if (windevnul == INVALID_HANDLE_VALUE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); goto oops; } } @@ -841,7 +838,7 @@ int hawk_pio_init (hawk_pio_t* pio, hawk_gem_t* gem, const hawk_ooch_t* cmd, int startup.hStdOutput == INVALID_HANDLE_VALUE || startup.hStdError == INVALID_HANDLE_VALUE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); goto oops; } @@ -960,7 +957,7 @@ create_process: goto create_process; } - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(e)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(e)); goto oops; } @@ -995,7 +992,7 @@ create_process: rc = DosDupHandle(x,y); \ if (rc != NO_ERROR) \ { \ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); \ + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); \ goto oops; \ } \ ) @@ -1006,7 +1003,7 @@ create_process: rc = DosCreatePipe (&handle[0], &handle[1], pipe_size); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1015,7 +1012,7 @@ create_process: rc = DosSetFHState (handle[1], OPEN_FLAGS_NOINHERIT); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1033,7 +1030,7 @@ create_process: rc = DosCreatePipe (&handle[2], &handle[3], pipe_size); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1042,7 +1039,7 @@ create_process: rc = DosSetFHState(handle[2], OPEN_FLAGS_NOINHERIT); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1056,7 +1053,7 @@ create_process: rc = DosCreatePipe(&handle[4], &handle[5], pipe_size); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1065,7 +1062,7 @@ create_process: rc = DosSetFHState (handle[4], OPEN_FLAGS_NOINHERIT); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } @@ -1104,7 +1101,7 @@ create_process: ); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } } @@ -1114,20 +1111,20 @@ create_process: rc = DosDupHandle (std_in, &old_in); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } rc = DosDupHandle (std_out, &old_out); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); DosClose (old_in); old_in = HAWK_PIO_HND_NIL; goto oops; } rc = DosDupHandle (std_err, &old_err); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); DosClose (old_out); old_out = HAWK_PIO_HND_NIL; DosClose (old_in); old_in = HAWK_PIO_HND_NIL; goto oops; @@ -1299,7 +1296,7 @@ create_process: if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); goto oops; } pio->child = child_rc.codeTerminate; @@ -1316,7 +1313,7 @@ create_process: { if (HAWK_PIPE(&handle[0]) <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } minidx = 0; maxidx = 1; @@ -1326,7 +1323,7 @@ create_process: { if (HAWK_PIPE(&handle[2]) <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } if (minidx == -1) minidx = 2; @@ -1337,7 +1334,7 @@ create_process: { if (HAWK_PIPE(&handle[4]) <= -1) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); goto oops; } if (minidx == -1) minidx = 4; @@ -1364,7 +1361,7 @@ create_process: if ((pserr = posix_spawn_file_actions_init(&fa)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } fa_inited = 1; @@ -1374,17 +1371,17 @@ create_process: /* child should read */ if ((pserr = posix_spawn_file_actions_addclose(&fa, handle[1])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_adddup2(&fa, handle[0], 0)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_addclose(&fa, handle[0])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } } @@ -1394,23 +1391,23 @@ create_process: /* child should write */ if ((pserr = posix_spawn_file_actions_addclose(&fa, handle[2])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_adddup2(&fa, handle[3], 1)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_ERRTOOUT) && (pserr = posix_spawn_file_actions_adddup2 (&fa, handle[3], 2)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_addclose(&fa, handle[3])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } } @@ -1420,23 +1417,23 @@ create_process: /* child should write */ if ((pserr = posix_spawn_file_actions_addclose (&fa, handle[4])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_adddup2 (&fa, handle[5], 2)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_OUTTOERR) && (pserr = posix_spawn_file_actions_adddup2 (&fa, handle[5], 1)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((pserr = posix_spawn_file_actions_addclose (&fa, handle[5])) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } } @@ -1450,19 +1447,19 @@ create_process: if ((flags & HAWK_PIO_INTONUL) && (pserr = posix_spawn_file_actions_addopen (&fa, 0, HAWK_BT("/dev/null"), oflags, 0)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_OUTTONUL) && (pserr = posix_spawn_file_actions_addopen (&fa, 1, HAWK_BT("/dev/null"), oflags, 0)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_ERRTONUL) && (pserr = posix_spawn_file_actions_addopen (&fa, 2, HAWK_BT("/dev/null"), oflags, 0)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } } @@ -1475,19 +1472,19 @@ create_process: if ((flags & HAWK_PIO_DROPIN) && is_fd_valid(0) && (pserr = posix_spawn_file_actions_addclose (&fa, 0)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_DROPOUT) && is_fd_valid(1) && (pserr = posix_spawn_file_actions_addclose (&fa, 1)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } if ((flags & HAWK_PIO_DROPERR) && is_fd_valid(2) && (pserr = posix_spawn_file_actions_addclose (&fa, 2)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } @@ -1507,7 +1504,7 @@ create_process: if (is_fd_valid_and_nocloexec(fd) && (pserr = posix_spawn_file_actions_addclose (&fa, fd)) != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } } @@ -1549,7 +1546,7 @@ create_process: } if (pserr != 0) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(pserr)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(pserr)); goto oops; } @@ -1935,7 +1932,7 @@ static hawk_ooi_t pio_read (hawk_pio_t* pio, void* buf, hawk_oow_t size, hawk_pi /* ReadFile receives ERROR_BROKEN_PIPE when the write end * is closed in the child process */ if (GetLastError() == ERROR_BROKEN_PIPE) return 0; - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return (hawk_ooi_t)count; @@ -1949,7 +1946,7 @@ static hawk_ooi_t pio_read (hawk_pio_t* pio, void* buf, hawk_oow_t size, hawk_pi if (rc != NO_ERROR) { if (rc == ERROR_BROKEN_PIPE) return 0; /* TODO: check this */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } return (hawk_ooi_t)count; @@ -1961,7 +1958,7 @@ static hawk_ooi_t pio_read (hawk_pio_t* pio, void* buf, hawk_oow_t size, hawk_pi size = HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int); n = read (hnd, buf, size); - if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #else @@ -1981,7 +1978,7 @@ reread: } else { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); } } @@ -2023,7 +2020,7 @@ static hawk_ooi_t pio_write (hawk_pio_t* pio, const void* data, hawk_oow_t size, if (WriteFile (hnd, data, (DWORD)size, &count, HAWK_NULL) == FALSE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return (hawk_ooi_t)count; @@ -2036,7 +2033,7 @@ static hawk_ooi_t pio_write (hawk_pio_t* pio, const void* data, hawk_oow_t size, rc = DosWrite (hnd, (PVOID)data, (ULONG)size, &count); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } return (hawk_ooi_t)count; @@ -2047,7 +2044,7 @@ static hawk_ooi_t pio_write (hawk_pio_t* pio, const void* data, hawk_oow_t size, size = HAWK_TYPE_MAX(hawk_ooi_t) & HAWK_TYPE_MAX(unsigned int); n = write (hnd, data, size); - if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #else @@ -2067,7 +2064,7 @@ rewrite: } else { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); } } return n; @@ -2146,7 +2143,7 @@ int hawk_pio_wait (hawk_pio_t* pio) if (w != WAIT_OBJECT_0) { /* WAIT_FAILED, WAIT_ABANDONED */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } @@ -2156,7 +2153,7 @@ int hawk_pio_wait (hawk_pio_t* pio) { /* close the handle anyway to prevent further * errors when this function is called again */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); CloseHandle (pio->child); pio->child = HAWK_PIO_PID_NIL; return -1; @@ -2204,7 +2201,7 @@ int hawk_pio_wait (hawk_pio_t* pio) if (rc != NO_ERROR) { /* WAIT_FAILED, WAIT_ABANDONED */ - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } @@ -2251,7 +2248,7 @@ int hawk_pio_wait (hawk_pio_t* pio) if (!(pio->flags & HAWK_PIO_WAITNORETRY)) continue; } - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); break; } @@ -2318,7 +2315,7 @@ int hawk_pio_kill (hawk_pio_t* pio) n = TerminateProcess(pio->child, 255 + 1 + 9); if (n == FALSE) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } return 0; @@ -2328,7 +2325,7 @@ int hawk_pio_kill (hawk_pio_t* pio) rc = DosKillProcess(pio->child, DKP_PROCESSTREE); if (rc != NO_ERROR) { - hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(rc)); + hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(rc)); return -1; } return 0; @@ -2340,7 +2337,7 @@ int hawk_pio_kill (hawk_pio_t* pio) #else n = HAWK_KILL(pio->child, SIGKILL); - if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, syserr_to_errnum(errno)); + if (n <= -1) hawk_gem_seterrnum (pio->gem, HAWK_NULL, hawk_syserr_to_errnum(errno)); return n; #endif } diff --git a/hawk/lib/sio.c b/hawk/lib/sio.c index 0d3937a2..96e160e4 100644 --- a/hawk/lib/sio.c +++ b/hawk/lib/sio.c @@ -37,9 +37,6 @@ # include "syscall.h" #endif -#include "syserr.h" -IMPLEMENT_SYSERR_TO_ERRNUM (hawk, HAWK) - #define LOCK_OUTPUT(sio) do { if ((sio)->mtx) hawk_mtx_lock ((sio)->mtx, HAWK_NULL); } while(0) #define UNLOCK_OUTPUT(sio) do { if ((sio)->mtx) hawk_mtx_unlock ((sio)->mtx); } while(0) @@ -461,7 +458,7 @@ hawk_ooi_t hawk_sio_putucstr (hawk_sio_t* sio, const hawk_uch_t* str) { if (WriteConsoleW(sio->file.handle, cur, left, &count, HAWK_NULL) == FALSE) { - hawk_gem_seterrnum (sio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (sio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } if (count == 0) break; @@ -525,7 +522,7 @@ hawk_ooi_t hawk_sio_putuchars (hawk_sio_t* sio, const hawk_uch_t* str, hawk_oow_ { if (WriteConsoleW(sio->file.handle, cur, left, &count, HAWK_NULL) == FALSE) { - hawk_gem_seterrnum (sio->gem, HAWK_NULL, syserr_to_errnum(GetLastError())); + hawk_gem_seterrnum (sio->gem, HAWK_NULL, hawk_syserr_to_errnum(GetLastError())); return -1; } if (count == 0) break; diff --git a/hawk/lib/syserr.h b/hawk/lib/syserr.h deleted file mode 100644 index fe59b9fc..00000000 --- a/hawk/lib/syserr.h +++ /dev/null @@ -1,253 +0,0 @@ -/* - * $Id$ - * - Copyright (c) 2006-2019 Chung, Hyung-Hwan. All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR - IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. - IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, - INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT - NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF - THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -/* - * this file is intended for internal use only. - * you can include this file and use IMPLEMENT_SYSERR_TO_ERRNUM. - * - * #include "syserr.h" - * IMPLEMENT_SYSERR_TO_ERRNUM (pio, PIO) - * - * header files defining system error codes must be included - * before this file. - */ - -#if defined(__cplusplus) -# define __SYSERRTYPE__(obj) obj -# define __SYSERRNUM__(obj,num) (obj E_ ## num) -#else -/*# define __SYSERRTYPE__(obj) hawk_ ## obj ## _errnum_t -# define __SYSERRNUM__(obj,num) (HAWK_ ## obj ## _ ## num)*/ -# define __SYSERRTYPE__(obj) obj ## _errnum_t -# define __SYSERRNUM__(obj,num) (obj ## _ ## num) -#endif - -#if defined(_WIN32) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (DWORD e) \ - { \ - switch (e) \ - { \ - case ERROR_NOT_ENOUGH_MEMORY: \ - case ERROR_OUTOFMEMORY: \ - return __SYSERRNUM__ (obj2, ENOMEM); \ - case ERROR_INVALID_PARAMETER: \ - case ERROR_INVALID_HANDLE: \ - case ERROR_INVALID_NAME: \ - return __SYSERRNUM__ (obj2, EINVAL); \ - case ERROR_ACCESS_DENIED: \ - case ERROR_SHARING_VIOLATION: \ - return __SYSERRNUM__ (obj2, EACCES); \ - case ERROR_FILE_NOT_FOUND: \ - case ERROR_PATH_NOT_FOUND: \ - return __SYSERRNUM__ (obj2, ENOENT); \ - case ERROR_ALREADY_EXISTS: \ - case ERROR_FILE_EXISTS: \ - return __SYSERRNUM__ (obj2, EEXIST); \ - case ERROR_BROKEN_PIPE: \ - return __SYSERRNUM__ (obj2, EPIPE); \ - default: \ - return __SYSERRNUM__ (obj2, ESYSERR); \ - } \ - } - -#elif defined(__OS2__) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (APIRET e) \ - { \ - switch (e) \ - { \ - case ERROR_NOT_ENOUGH_MEMORY: \ - return __SYSERRNUM__ (obj2, ENOMEM); \ - case ERROR_INVALID_PARAMETER: \ - case ERROR_INVALID_HANDLE: \ - case ERROR_INVALID_NAME: \ - return __SYSERRNUM__ (obj2, EINVAL); \ - case ERROR_ACCESS_DENIED: \ - case ERROR_SHARING_VIOLATION: \ - return __SYSERRNUM__ (obj2, EACCES); \ - case ERROR_FILE_NOT_FOUND: \ - case ERROR_PATH_NOT_FOUND: \ - return __SYSERRNUM__ (obj2, ENOENT); \ - case ERROR_ALREADY_EXISTS: \ - return __SYSERRNUM__ (obj2, EEXIST); \ - case ERROR_BROKEN_PIPE: \ - return __SYSERRNUM__ (obj2, EPIPE); \ - default: \ - return __SYSERRNUM__ (obj2, ESYSERR); \ - } \ - } - -/* -#elif defined(__DOS__) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (int e) \ - { \ - switch (e) \ - { \ - case ENOMEM: return __SYSERRNUM__ (obj2, ENOMEM); \ - case EINVAL: return __SYSERRNUM__ (obj2, EINVAL); \ - case EACCES: return __SYSERRNUM__ (obj2, EACCES); \ - case ENOENT: return __SYSERRNUM__ (obj2, ENOENT); \ - case EEXIST: return __SYSERRNUM__ (obj2, EEXIST); \ - default: return __SYSERRNUM__ (obj2, ESYSERR); \ - } \ - } -*/ - -#elif defined(vms) || defined(__vms) - - /* TODO: */ - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (unsigned long e) \ - { \ - switch (e) \ - { \ - case RMS$_NORMAL: return __SYSERRNUM__ (obj2, ENOERR); \ - default: return __SYSERRNUM__ (obj2, ESYSERR); \ - } \ - } - -#else - - #if defined(EWOULDBLOCK) && defined(EAGAIN) && (EWOULDBLOCK != EAGAIN) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (int e) \ - { \ - switch (e) \ - { \ - case ENOMEM: return __SYSERRNUM__(obj2, ENOMEM); \ - case EINVAL: return __SYSERRNUM__(obj2, EINVAL); \ - case EBUSY: return _SYSERRNUM__(obj2, EBUSY); \ - case EACCES: return __SYSERRNUM__(obj2, EACCES); \ - case EPERM: return __SYSERRNUM__(obj2, EPERM); \ - case EISDIR: return __SYSERRNUM__(obj2, EISDIR); \ - case ENOTDIR: return __SYSERRNUM__(obj2, ENOTDIR); \ - case ENXIO: \ - case ENODEV: \ - case ENOENT: return __SYSERRNUM__(obj2, ENOENT); \ - case EEXIST: return __SYSERRNUM__(obj2, EEXIST); \ - case EINTR: return __SYSERRNUM__(obj2, EINTR); \ - case EPIPE: return __SYSERRNUM__(obj2, EPIPE); \ - case ECHILD: return __SYSERRNUM__(obj2, ECHILD); \ - case ETIMEDOUT: return __SYSERRNUM__(obj2, ETMOUT); \ - case EINPROGRESS: return __SYSERRNUM__(obj2, EINPROG); \ - case EWOULDBLOCK: \ - case EAGAIN: return __SYSERRNUM__(obj2, EAGAIN); \ - default: return __SYSERRNUM__(obj2, ESYSERR); \ - } \ - } - - #elif defined(EAGAIN) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (int e) \ - { \ - switch (e) \ - { \ - case ENOMEM: return __SYSERRNUM__(obj2, ENOMEM); \ - case EINVAL: return __SYSERRNUM__(obj2, EINVAL); \ - case EBUSY: return __SYSERRNUM__(obj2, EBUSY); \ - case EACCES: return __SYSERRNUM__(obj2, EACCES); \ - case EPERM: return __SYSERRNUM__(obj2, EPERM); \ - case EISDIR: return __SYSERRNUM__(obj2, EISDIR); \ - case ENOTDIR: return __SYSERRNUM__(obj2, ENOTDIR); \ - case ENXIO: \ - case ENODEV: \ - case ENOENT: return __SYSERRNUM__(obj2, ENOENT); \ - case EEXIST: return __SYSERRNUM__(obj2, EEXIST); \ - case EINTR: return __SYSERRNUM__(obj2, EINTR); \ - case EPIPE: return __SYSERRNUM__(obj2, EPIPE); \ - case ECHILD: return __SYSERRNUM__(obj2, ECHILD); \ - case ETIMEDOUT: return __SYSERRNUM__(obj2, ETMOUT); \ - case EINPROGRESS: return __SYSERRNUM__(obj2, EINPROG); \ - case EAGAIN: return __SYSERRNUM__(obj2, EAGAIN); \ - default: return __SYSERRNUM__(obj2, ESYSERR); \ - } \ - } - - #elif defined(EWOULDBLOCK) - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (int e) \ - { \ - switch (e) \ - { \ - case ENOMEM: return __SYSERRNUM__(obj2, ENOMEM); \ - case EINVAL: return __SYSERRNUM__(obj2, EINVAL); \ - case EBUSY: return __SYSERRNUM__(obj2, EBUSY); \ - case EACCES: return __SYSERRNUM__(obj2, EACCES); \ - case EPERM: return __SYSERRNUM__(obj2, EPERM); \ - case EISDIR: return __SYSERRNUM__(obj2, EISDIR); \ - case ENOTDIR: return __SYSERRNUM__(obj2, ENOTDIR); \ - case ENXIO: \ - case ENODEV: \ - case ENOENT: return __SYSERRNUM__(obj2, ENOENT); \ - case EEXIST: return __SYSERRNUM__(obj2, EEXIST); \ - case EINTR: return __SYSERRNUM__(obj2, EINTR); \ - case EPIPE: return __SYSERRNUM__(obj2, EPIPE); \ - case ECHILD: return __SYSERRNUM__(obj2, ECHILD); \ - case ETIMEDOUT: return __SYSERRNUM__(obj2, ETMOUT); \ - case EINPROGRESS: return __SYSERRNUM__(obj2, EINPROG); \ - case EWOULDBLOCK: return __SYSERRNUM__(obj2, EAGAIN); \ - default: return __SYSERRNUM__(obj2, ESYSERR); \ - } \ - } - - #else - - #define IMPLEMENT_SYSERR_TO_ERRNUM(obj1,obj2) \ - static __SYSERRTYPE__(obj1) syserr_to_errnum (int e) \ - { \ - switch (e) \ - { \ - case ENOMEM: return __SYSERRNUM__(obj2, ENOMEM); \ - case EINVAL: return __SYSERRNUM__(obj2, EINVAL); \ - case EBUSY: return __SYSERRNUM__(obj2, EBUSY); \ - case EACCES: return __SYSERRNUM__(obj2, EACCES); \ - case EPERM: return __SYSERRNUM__(obj2, EPERM); \ - case EISDIR: return __SYSERRNUM__(obj2, EISDIR); \ - case ENOTDIR: return __SYSERRNUM__(obj2, ENOTDIR); \ - case ENXIO: \ - case ENODEV: \ - case ENOENT: return __SYSERRNUM__(obj2, ENOENT); \ - case EEXIST: return __SYSERRNUM__(obj2, EEXIST); \ - case EINTR: return __SYSERRNUM__(obj2, EINTR); \ - case EPIPE: return __SYSERRNUM__(obj2, EPIPE); \ - case ECHILD: return __SYSERRNUM__(obj2, ECHILD); \ - case ETIMEDOUT: return __SYSERRNUM__(obj2, ETMOUT); \ - case EINPROGRESS: return __SYSERRNUM__(obj2, EINPROG); \ - default: return __SYSERRNUM__(obj2, ESYSERR); \ - } \ - } - - #endif - -#endif diff --git a/hawk/lib/tre.c b/hawk/lib/tre.c index 4e8ac940..956f7362 100644 --- a/hawk/lib/tre.c +++ b/hawk/lib/tre.c @@ -224,9 +224,9 @@ int hawk_tre_execx ( return -1; } #if defined(HAWK_OOCH_IS_UCH) - ret = tre_match (tre, str, len, STR_WIDE, nmatch, pmatch, eflags); + ret = tre_match(tre, str, len, STR_WIDE, nmatch, pmatch, eflags); #else - ret = tre_match (tre, str, len, STR_BYTE, nmatch, pmatch, eflags); + ret = tre_match(tre, str, len, STR_BYTE, nmatch, pmatch, eflags); #endif if (ret > 0) { diff --git a/hawk/m4/libtool.m4 b/hawk/m4/libtool.m4 index a644432f..ee80844b 100644 --- a/hawk/m4/libtool.m4 +++ b/hawk/m4/libtool.m4 @@ -728,7 +728,6 @@ _LT_CONFIG_SAVE_COMMANDS([ cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. @@ -2867,9 +2866,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command @@ -2878,7 +2874,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then 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' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -2890,6 +2886,18 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -3549,7 +3557,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else @@ -4427,7 +4435,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -4939,6 +4947,9 @@ m4_if([$1], [CXX], [ ;; esac ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; @@ -5001,6 +5012,9 @@ dnl Note also adjust exclude_expsyms for C++ above. openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes @@ -5255,7 +5269,7 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -5776,6 +5790,7 @@ _LT_EOF if test yes = "$lt_cv_irix_exported_symbol"; then _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' fi + _LT_TAGVAR(link_all_deplibs, $1)=no else _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' _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' @@ -5797,7 +5812,7 @@ _LT_EOF esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else diff --git a/hawk/mod/Makefile.in b/hawk/mod/Makefile.in index 291e72f8..de667927 100644 --- a/hawk/mod/Makefile.in +++ b/hawk/mod/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -184,9 +184,7 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = depcomp = $(SHELL) $(top_srcdir)/ac/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/libhawk_mysql_la-mod-mysql.Plo \ - ./$(DEPDIR)/libhawk_uci_la-mod-uci.Plo +am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -380,6 +378,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -453,8 +452,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -524,14 +523,8 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_mysql_la-mod-mysql.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_uci_la-mod-uci.Plo@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_mysql_la-mod-mysql.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libhawk_uci_la-mod-uci.Plo@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @@ -629,10 +622,7 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -705,8 +695,7 @@ clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ clean-pkgmodexecLTLIBRARIES mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/libhawk_mysql_la-mod-mysql.Plo - -rm -f ./$(DEPDIR)/libhawk_uci_la-mod-uci.Plo + -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags @@ -752,8 +741,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/libhawk_mysql_la-mod-mysql.Plo - -rm -f ./$(DEPDIR)/libhawk_uci_la-mod-uci.Plo + -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -774,8 +762,8 @@ uninstall-am: uninstall-pkgmodexecLTLIBRARIES .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-generic clean-libtool clean-noinstLTLIBRARIES \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLTLIBRARIES \ clean-pkgmodexecLTLIBRARIES cscopelist-am ctags ctags-am \ distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ diff --git a/hawk/t/Makefile.in b/hawk/t/Makefile.in index 0d3fb1bd..fe453e10 100644 --- a/hawk/t/Makefile.in +++ b/hawk/t/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -135,9 +135,7 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = depcomp = $(SHELL) $(top_srcdir)/ac/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/t-001.Po ./$(DEPDIR)/t-002.Po \ - ./$(DEPDIR)/t-005.Po +am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -330,6 +328,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -385,8 +384,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -465,15 +464,9 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-001.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-002.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-005.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-001.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-002.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t-005.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @@ -557,10 +550,7 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -632,9 +622,7 @@ clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/t-001.Po - -rm -f ./$(DEPDIR)/t-002.Po - -rm -f ./$(DEPDIR)/t-005.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags @@ -680,9 +668,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/t-001.Po - -rm -f ./$(DEPDIR)/t-002.Po - -rm -f ./$(DEPDIR)/t-005.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -703,7 +689,7 @@ uninstall-am: uninstall-binPROGRAMS .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ clean-binPROGRAMS clean-generic clean-libtool cscopelist-am \ ctags ctags-am distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ diff --git a/hawk/tools/Makefile.in b/hawk/tools/Makefile.in index 8c922d28..187b7375 100644 --- a/hawk/tools/Makefile.in +++ b/hawk/tools/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -137,9 +137,7 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = depcomp = $(SHELL) $(top_srcdir)/ac/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/uni_case-uni-case.Po \ - ./$(DEPDIR)/uni_prop-uni-prop.Po +am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -332,6 +330,7 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -383,8 +382,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -459,14 +458,8 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uni_case-uni-case.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uni_prop-uni-prop.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uni_case-uni-case.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uni_prop-uni-prop.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ @@ -578,10 +571,7 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) +distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -653,8 +643,7 @@ clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/uni_case-uni-case.Po - -rm -f ./$(DEPDIR)/uni_prop-uni-prop.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags @@ -700,8 +689,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/uni_case-uni-case.Po - -rm -f ./$(DEPDIR)/uni_prop-uni-prop.Po + -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -722,7 +710,7 @@ uninstall-am: uninstall-binPROGRAMS .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ clean-binPROGRAMS clean-generic clean-libtool cscopelist-am \ ctags ctags-am distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \