for this_target in $target $canon_targets ; do
- eval `echo $this_target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/cpu=\1 vendor=\2 os=\3/'`
+changequote(,)dnl
+ eval `echo $this_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/cpu=\1 vendor=\2 os=\3/'`
+changequote([,])dnl
# check for architecture variants
case ${cpu} in
m683??) cpu_type=m68k ;;
changequote([,])dnl
m8*) cpu_type=m88k ;;
- mips*el) cpu_type=mips endian=little;;
+ mips*el) cpu_type=mips endian=little ;;
mips*) cpu_type=mips endian=big ;;
powerpcle*) cpu_type=ppc endian=little ;;
powerpc*) cpu_type=ppc endian=big ;;
a29k-nyu-sym1) fmt=coff targ=ebmon29k ;;
a29k-*-vxworks*) fmt=coff ;;
+ alpha-*-*vms*) fmt=evax ;;
alpha-*-netware*) fmt=ecoff ;;
alpha-*-osf*) fmt=ecoff ;;
alpha-*-linuxecoff*) fmt=ecoff ;;
mips-*-irix*) fmt=ecoff targ=mips-big ;;
mips-*-riscos*) fmt=ecoff targ=mips-big ;;
mips-*-sysv*) fmt=ecoff targ=mips-big ;;
- mips-*-elf*) fmt=elf
+ mips-*-elf* | mips-*-rtems* | mips-*-linux*)
+ fmt=elf
case "$endian" in
big) targ=mips-big ;;
*) targ=mips-lit ;;
esac
;;
+ mn10200-*-*) fmt=elf bfd_gas=yes ;;
+ mn10300-*-*) fmt=elf bfd_gas=yes ;;
ppc-*-pe | ppc-*-cygwin32 | ppc-*-winnt*)
fmt=coff em=pe
case "$endian" in
fmt=coff em=macos ;;
ppc-*-netware*) fmt=elf em=ppcnw ;;
- sh-*-coff) fmt=coff ;;
+ sh-*-elf*) fmt=elf ;;
+ sh-*-coff*) fmt=coff ;;
ns32k-pc532-mach* | ns32k-pc532-ux*) fmt=aout em=pc532mach ;;
ns32k-pc532-netbsd* | ns32k-pc532-lites*) fmt=aout em=nbsd532 ;;
sparc-*-rtems*) fmt=aout ;;
sparc-*-sunos4*) fmt=aout em=sun3 ;;
sparc-*-aout | sparc*-*-vxworks*)
- fmt=aout ;;
+ fmt=aout em=sparcaout ;;
sparc-*-coff) fmt=coff ;;
sparc-*-lynxos*) fmt=coff em=lynx ;;
sparc-fujitsu-none) fmt=aout ;;
fmt=elf ;;
sparc-*-netbsd*) fmt=aout em=nbsd bfd_gas=yes ;;
+# start-sanitize-tic80
+ tic80-*-coff) fmt=coff targ=tic80coff;;
+# end-sanitize-tic80
+ v850-*-*) fmt=elf bfd_gas=yes ;;
+
vax-*-bsd* | vax-*-ultrix*)
fmt=aout ;;
vax-*-vms) fmt=vms ;;
])
HLDFLAGS=
+HLDENV=
RPATH_ENVVAR=LD_LIBRARY_PATH
# If we have shared libraries, try to set rpath reasonably.
if test "${shared}" = "true"; then
*-*-linux*)
HLDFLAGS='-Wl,-rpath,$(libdir)'
;;
- *-*-sysv4* | *-*-solaris*)
+ *-*-solaris*)
HLDFLAGS='-R $(libdir)'
;;
+ *-*-sysv4*)
+ HLDENV='if test -z "$${LD_RUN_PATH}"; then LD_RUN_PATH=$(libdir); else LD_RUN_PATH=$${LD_RUN_PATH}:$(libdir); fi; export LD_RUN_PATH;'
+ ;;
esac
fi
;;
esac
AC_SUBST(HLDFLAGS)
+AC_SUBST(HLDENV)
AC_SUBST(RPATH_ENVVAR)
dnl This must come last.