* config.bfd (sh-*-linux*): Use bfd_elf*_sh64*lin_vec as sh64

vectors in target_selvecs.
	(shle-*-netbsdelf*): Use bfd_elf*_sh64*nbsd_vec as sh64 vectors
	in target_selvecs.
	(sh-*-netbsdelf*): Likewise.
	* configure.in (assocvecs): New variable.  Handle assocvecs like
	selvecs.
	* configure: Regenerate.
	* format.c (bfd_check_format_matches): Store bfd_target pointers
	in matching_vector instead of target names.  Select first target
	from bfd_associated_vector that matches a list of ambiguous targets.
	* targets.c (_bfd_associated_vector): New array.
	(bfd_associated_vector): New variable.
	(_bfd_target_vector): Add bfd_elf*_sh64*lin_vec.
	* libbfd-in.h (bfd_associated_vector): Declare.
	* libbfd.h: Regenerate.
This commit is contained in:
Alan Modra
2002-11-05 01:18:56 +00:00
parent 89117aabb3
commit 08f740041a
8 changed files with 133 additions and 30 deletions

View File

@ -1,3 +1,23 @@
2002-11-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
Alan Modra <amodra@bigpond.net.au>
* config.bfd (sh-*-linux*): Use bfd_elf*_sh64*lin_vec as sh64
vectors in target_selvecs.
(shle-*-netbsdelf*): Use bfd_elf*_sh64*nbsd_vec as sh64 vectors
in target_selvecs.
(sh-*-netbsdelf*): Likewise.
* configure.in (assocvecs): New variable. Handle assocvecs like
selvecs.
* configure: Regenerate.
* format.c (bfd_check_format_matches): Store bfd_target pointers
in matching_vector instead of target names. Select first target
from bfd_associated_vector that matches a list of ambiguous targets.
* targets.c (_bfd_associated_vector): New array.
(bfd_associated_vector): New variable.
(_bfd_target_vector): Add bfd_elf*_sh64*lin_vec.
* libbfd-in.h (bfd_associated_vector): Declare.
* libbfd.h: Regenerate.
2002-11-05 Elias Athanasopoulos <eathan@otenet.gr> 2002-11-05 Elias Athanasopoulos <eathan@otenet.gr>
* vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is * vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is

View File

@ -949,7 +949,7 @@ case "${targ}" in
targ_defvec=bfd_elf32_shblin_vec targ_defvec=bfd_elf32_shblin_vec
targ_selvecs=bfd_elf32_shlin_vec targ_selvecs=bfd_elf32_shlin_vec
#ifdef BFD64 #ifdef BFD64
targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec" targ_selvecs="${targ_selvecs} bfd_elf32_sh64lin_vec bfd_elf32_sh64blin_vec bfd_elf64_sh64lin_vec bfd_elf64_sh64blin_vec"
#endif #endif
;; ;;
sh*eb-*-linux*) sh*eb-*-linux*)
@ -985,7 +985,7 @@ case "${targ}" in
targ_defvec=bfd_elf32_shlnbsd_vec targ_defvec=bfd_elf32_shlnbsd_vec
targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec" targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec"
#ifdef BFD64 #ifdef BFD64
targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec" targ_selvecs="${targ_selvecs} bfd_elf32_sh64lnbsd_vec bfd_elf32_sh64nbsd_vec bfd_elf64_sh64lnbsd_vec bfd_elf64_sh64nbsd_vec"
#endif #endif
;; ;;
sh*le-*-netbsdelf*) sh*le-*-netbsdelf*)
@ -996,7 +996,7 @@ case "${targ}" in
targ_defvec=bfd_elf32_shnbsd_vec targ_defvec=bfd_elf32_shnbsd_vec
targ_selvecs="bfd_elf32_shlnbsd_vec shcoff_vec shlcoff_vec" targ_selvecs="bfd_elf32_shlnbsd_vec shcoff_vec shlcoff_vec"
#ifdef BFD64 #ifdef BFD64
targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec" targ_selvecs="${targ_selvecs} bfd_elf32_sh64lnbsd_vec bfd_elf32_sh64nbsd_vec bfd_elf64_sh64lnbsd_vec bfd_elf64_sh64nbsd_vec"
#endif #endif
;; ;;
sh*-*-netbsdelf*) sh*-*-netbsdelf*)

45
bfd/configure vendored
View File

@ -5975,12 +5975,14 @@ fi
all_targets=false all_targets=false
defvec= defvec=
selvecs= selvecs=
assocvecs=
selarchs= selarchs=
TDEFINES= TDEFINES=
for targ in $target $canon_targets for targ in $target $canon_targets
do do
if test "x$targ" = "xall"; then if test "x$targ" = "xall"; then
all_targets=true all_targets=true
assocvecs="$assocvecs $targ_defvec $targ_selvecs"
else else
. $srcdir/config.bfd . $srcdir/config.bfd
if test "x$targ" = "x$target"; then if test "x$targ" = "x$target"; then
@ -6011,6 +6013,17 @@ done
selvecs="$f" selvecs="$f"
# uniq the associated vectors in all the configured targets.
f=""
for i in $assocvecs ; do
case " $f " in
*" $i "*) ;;
*) f="$f $i" ;;
esac
done
assocvecs="$f"
# uniq the architectures in all the configured targets. # uniq the architectures in all the configured targets.
f="" f=""
for i in $selarchs ; do for i in $selarchs ; do
@ -6320,9 +6333,12 @@ if test x${all_targets} = xtrue ; then
selvecs= selvecs=
havevecs= havevecs=
selarchs= selarchs=
test -n "$assocvecs" &&
assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
else # all_targets is true else # all_targets is true
# Only set these if they will be nonempty, for the clever echo. # Only set these if they will be nonempty, for the clever echo.
havevecs= havevecs=
assocvecs=
test -n "$selvecs" && test -n "$selvecs" &&
havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'` havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
test -n "$selvecs" && test -n "$selvecs" &&
@ -6343,10 +6359,10 @@ case ${host64}-${target64}-${want64} in
if test -n "$GCC" ; then if test -n "$GCC" ; then
bad_64bit_gcc=no; bad_64bit_gcc=no;
echo $ac_n "checking for gcc version with buggy 64-bit support""... $ac_c" 1>&6 echo $ac_n "checking for gcc version with buggy 64-bit support""... $ac_c" 1>&6
echo "configure:6347: checking for gcc version with buggy 64-bit support" >&5 echo "configure:6363: checking for gcc version with buggy 64-bit support" >&5
# Add more tests for gcc versions with non-working 64-bit support here. # Add more tests for gcc versions with non-working 64-bit support here.
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 6350 "configure" #line 6366 "configure"
#include "confdefs.h" #include "confdefs.h"
:__GNUC__:__GNUC_MINOR__:__i386__: :__GNUC__:__GNUC_MINOR__:__i386__:
EOF EOF
@ -6383,6 +6399,7 @@ esac
tdefaults="" tdefaults=""
test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}" test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'" test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'"
test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'" test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}" test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
@ -6391,17 +6408,17 @@ for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6395: checking for $ac_hdr" >&5 echo "configure:6412: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 6400 "configure" #line 6417 "configure"
#include "confdefs.h" #include "confdefs.h"
#include <$ac_hdr> #include <$ac_hdr>
EOF EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6405: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } { (eval echo configure:6422: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then if test -z "$ac_err"; then
rm -rf conftest* rm -rf conftest*
@ -6430,12 +6447,12 @@ done
for ac_func in getpagesize for ac_func in getpagesize
do do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:6434: checking for $ac_func" >&5 echo "configure:6451: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 6439 "configure" #line 6456 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */ which can conflict with char $ac_func(); below. */
@ -6458,7 +6475,7 @@ $ac_func();
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:6462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:6479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_$ac_func=yes" eval "ac_cv_func_$ac_func=yes"
else else
@ -6483,7 +6500,7 @@ fi
done done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
echo "configure:6487: checking for working mmap" >&5 echo "configure:6504: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
@ -6491,7 +6508,7 @@ else
ac_cv_func_mmap_fixed_mapped=no ac_cv_func_mmap_fixed_mapped=no
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 6495 "configure" #line 6512 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test. /* Thanks to Mike Haertel and Jim Avera for this test.
@ -6644,7 +6661,7 @@ main()
} }
EOF EOF
if { (eval echo configure:6648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null if { (eval echo configure:6665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then then
ac_cv_func_mmap_fixed_mapped=yes ac_cv_func_mmap_fixed_mapped=yes
else else
@ -6669,12 +6686,12 @@ fi
for ac_func in madvise mprotect for ac_func in madvise mprotect
do do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:6673: checking for $ac_func" >&5 echo "configure:6690: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 6678 "configure" #line 6695 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */ which can conflict with char $ac_func(); below. */
@ -6697,7 +6714,7 @@ $ac_func();
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:6701: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:6718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_$ac_func=yes" eval "ac_cv_func_$ac_func=yes"
else else

View File

@ -471,12 +471,14 @@ fi
all_targets=false all_targets=false
defvec= defvec=
selvecs= selvecs=
assocvecs=
selarchs= selarchs=
TDEFINES= TDEFINES=
for targ in $target $canon_targets for targ in $target $canon_targets
do do
if test "x$targ" = "xall"; then if test "x$targ" = "xall"; then
all_targets=true all_targets=true
assocvecs="$assocvecs $targ_defvec $targ_selvecs"
else else
. $srcdir/config.bfd . $srcdir/config.bfd
if test "x$targ" = "x$target"; then if test "x$targ" = "x$target"; then
@ -507,6 +509,17 @@ done
selvecs="$f" selvecs="$f"
# uniq the associated vectors in all the configured targets.
f=""
for i in $assocvecs ; do
case " $f " in
*" $i "*) ;;
*) f="$f $i" ;;
esac
done
assocvecs="$f"
# uniq the architectures in all the configured targets. # uniq the architectures in all the configured targets.
f="" f=""
for i in $selarchs ; do for i in $selarchs ; do
@ -816,9 +829,12 @@ if test x${all_targets} = xtrue ; then
selvecs= selvecs=
havevecs= havevecs=
selarchs= selarchs=
test -n "$assocvecs" &&
assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
else # all_targets is true else # all_targets is true
# Only set these if they will be nonempty, for the clever echo. # Only set these if they will be nonempty, for the clever echo.
havevecs= havevecs=
assocvecs=
test -n "$selvecs" && test -n "$selvecs" &&
havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'` havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
test -n "$selvecs" && test -n "$selvecs" &&
@ -866,6 +882,7 @@ AC_SUBST(bfd_default_target_size)
tdefaults="" tdefaults=""
test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}" test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'" test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'"
test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'" test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}" test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
AC_SUBST(tdefaults) AC_SUBST(tdefaults)

View File

@ -119,8 +119,9 @@ bfd_check_format_matches (abfd, format, matching)
char ***matching; char ***matching;
{ {
extern const bfd_target binary_vec; extern const bfd_target binary_vec;
const bfd_target * const *target, *save_targ, *right_targ, *ar_right_targ; const bfd_target * const *target;
char **matching_vector = NULL; const bfd_target **matching_vector = NULL;
const bfd_target *save_targ, *right_targ, *ar_right_targ;
int match_count; int match_count;
int ar_match_index; int ar_match_index;
@ -145,8 +146,8 @@ bfd_check_format_matches (abfd, format, matching)
bfd_size_type amt; bfd_size_type amt;
*matching = NULL; *matching = NULL;
amt = sizeof (char *) * 2 * _bfd_target_vector_entries; amt = sizeof (*matching_vector) * 2 * _bfd_target_vector_entries;
matching_vector = (char **) bfd_malloc (amt); matching_vector = (const bfd_target **) bfd_malloc (amt);
if (!matching_vector) if (!matching_vector)
return false; return false;
} }
@ -170,7 +171,7 @@ bfd_check_format_matches (abfd, format, matching)
abfd->xvec = right_targ; /* Set the target as returned. */ abfd->xvec = right_targ; /* Set the target as returned. */
if (matching) if (matching)
free (matching_vector); free ((PTR) matching_vector);
return true; /* File position has moved, BTW. */ return true; /* File position has moved, BTW. */
} }
@ -193,7 +194,7 @@ bfd_check_format_matches (abfd, format, matching)
abfd->format = bfd_unknown; abfd->format = bfd_unknown;
if (matching) if (matching)
free (matching_vector); free ((PTR) matching_vector);
bfd_set_error (bfd_error_file_not_recognized); bfd_set_error (bfd_error_file_not_recognized);
@ -236,7 +237,7 @@ bfd_check_format_matches (abfd, format, matching)
} }
if (matching) if (matching)
matching_vector[match_count] = temp->name; matching_vector[match_count] = temp;
match_count++; match_count++;
@ -259,7 +260,7 @@ bfd_check_format_matches (abfd, format, matching)
if (ar_right_targ != bfd_default_vector[0]) if (ar_right_targ != bfd_default_vector[0])
ar_right_targ = *target; ar_right_targ = *target;
if (matching) if (matching)
matching_vector[ar_match_index] = (*target)->name; matching_vector[ar_match_index] = *target;
ar_match_index++; ar_match_index++;
} }
else if (err != bfd_error_wrong_format) else if (err != bfd_error_wrong_format)
@ -268,7 +269,7 @@ bfd_check_format_matches (abfd, format, matching)
abfd->format = bfd_unknown; abfd->format = bfd_unknown;
if (matching) if (matching)
free (matching_vector); free ((PTR) matching_vector);
return false; return false;
} }
@ -289,7 +290,27 @@ bfd_check_format_matches (abfd, format, matching)
{ {
memcpy (matching_vector, memcpy (matching_vector,
matching_vector + _bfd_target_vector_entries, matching_vector + _bfd_target_vector_entries,
sizeof (char *) * match_count); sizeof (*matching_vector) * match_count);
}
}
}
if (match_count > 1 && bfd_associated_vector != NULL)
{
const bfd_target * const *assoc = bfd_associated_vector;
while ((right_targ = *assoc++) != NULL)
{
int i = match_count;
while (--i >= 0)
if (matching_vector[i] == right_targ)
break;
if (i >= 0)
{
match_count = 1;
break;
} }
} }
} }
@ -299,7 +320,7 @@ bfd_check_format_matches (abfd, format, matching)
abfd->xvec = right_targ; /* Change BFD's target permanently. */ abfd->xvec = right_targ; /* Change BFD's target permanently. */
if (matching) if (matching)
free (matching_vector); free ((PTR) matching_vector);
return true; /* File position has moved, BTW. */ return true; /* File position has moved, BTW. */
} }
@ -312,7 +333,7 @@ bfd_check_format_matches (abfd, format, matching)
bfd_set_error (bfd_error_file_not_recognized); bfd_set_error (bfd_error_file_not_recognized);
if (matching) if (matching)
free (matching_vector); free ((PTR) matching_vector);
} }
else else
{ {
@ -320,8 +341,15 @@ bfd_check_format_matches (abfd, format, matching)
if (matching) if (matching)
{ {
*matching = matching_vector; *matching = (char **) matching_vector;
matching_vector[match_count] = NULL; matching_vector[match_count] = NULL;
/* Return target names. This is a little nasty. Maybe we
should do another bfd_malloc? */
while (--match_count >= 0)
{
const char *name = matching_vector[match_count]->name;
*(const char **) &matching_vector[match_count] = name;
}
} }
} }

View File

@ -567,6 +567,9 @@ extern bfd *bfd_last_cache;
extern const bfd_target * const *bfd_target_vector; extern const bfd_target * const *bfd_target_vector;
extern const bfd_target *bfd_default_vector[]; extern const bfd_target *bfd_default_vector[];
/* List of associated target vectors. */
extern const bfd_target * const *bfd_associated_vector;
/* Functions shared by the ECOFF and MIPS ELF backends, which have no /* Functions shared by the ECOFF and MIPS ELF backends, which have no
other common header files. */ other common header files. */

View File

@ -572,6 +572,9 @@ extern bfd *bfd_last_cache;
extern const bfd_target * const *bfd_target_vector; extern const bfd_target * const *bfd_target_vector;
extern const bfd_target *bfd_default_vector[]; extern const bfd_target *bfd_default_vector[];
/* List of associated target vectors. */
extern const bfd_target * const *bfd_associated_vector;
/* Functions shared by the ECOFF and MIPS ELF backends, which have no /* Functions shared by the ECOFF and MIPS ELF backends, which have no
other common header files. */ other common header files. */

View File

@ -859,6 +859,8 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_sh64l_vec, &bfd_elf32_sh64l_vec,
&bfd_elf32_sh64lnbsd_vec, &bfd_elf32_sh64lnbsd_vec,
&bfd_elf32_sh64nbsd_vec, &bfd_elf32_sh64nbsd_vec,
&bfd_elf32_sh64lin_vec,
&bfd_elf32_sh64blin_vec,
#endif #endif
&bfd_elf32_sparc_vec, &bfd_elf32_sparc_vec,
&bfd_elf32_tradbigmips_vec, &bfd_elf32_tradbigmips_vec,
@ -889,6 +891,8 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf64_sh64l_vec, &bfd_elf64_sh64l_vec,
&bfd_elf64_sh64lnbsd_vec, &bfd_elf64_sh64lnbsd_vec,
&bfd_elf64_sh64nbsd_vec, &bfd_elf64_sh64nbsd_vec,
&bfd_elf64_sh64lin_vec,
&bfd_elf64_sh64blin_vec,
#if 0 #if 0
&bfd_elf64_sparc_vec, &bfd_elf64_sparc_vec,
#endif #endif
@ -1106,6 +1110,17 @@ const bfd_target *bfd_default_vector[] = {
NULL NULL
}; };
/* bfd_associated_vector[] contains the associated target vectors used
to reduce the ambiguity in bfd_check_format_matches. */
static const bfd_target *_bfd_associated_vector[] = {
#ifdef ASSOCIATED_VECS
ASSOCIATED_VECS,
#endif
NULL
};
const bfd_target * const *bfd_associated_vector = _bfd_associated_vector;
/* When there is an ambiguous match, bfd_check_format_matches puts the /* When there is an ambiguous match, bfd_check_format_matches puts the
names of the matching targets in an array. This variable is the maximum names of the matching targets in an array. This variable is the maximum
number of entries that the array could possibly need. */ number of entries that the array could possibly need. */