1991-08-15 07:23:44 +09:00
|
|
|
# This file is a shell script that supplies the information necessary
|
|
|
|
# to tailor a template configure script into the configure script
|
|
|
|
# appropriate for this directory. For more information, check any
|
|
|
|
# existing configure script.
|
|
|
|
|
|
|
|
srctrigger=ar.c
|
1992-07-05 05:47:03 +08:00
|
|
|
srcname="Binutils"
|
1991-08-15 07:23:44 +09:00
|
|
|
|
1993-06-08 03:45:12 +08:00
|
|
|
# per-host:
|
1991-08-15 07:23:44 +09:00
|
|
|
|
1994-06-08 13:05:21 +08:00
|
|
|
. ${srcdir}/../bfd/configure.host
|
|
|
|
|
1992-07-05 05:47:03 +08:00
|
|
|
host_makefile_frag=
|
|
|
|
if [ -f ${srcdir}/../bfd/config/${my_host}.mh ] ; then
|
|
|
|
host_makefile_frag=../bfd/config/${my_host}.mh
|
|
|
|
fi
|
1991-08-15 07:23:44 +09:00
|
|
|
|
1992-07-05 05:47:03 +08:00
|
|
|
# per-target:
|
1994-06-08 13:05:21 +08:00
|
|
|
|
|
|
|
# Canonicalize the secondary target names.
|
1995-09-01 10:24:59 +08:00
|
|
|
if [ -n "$enable_targets" ]; then
|
|
|
|
for targ in `echo $enable_targets | sed 's/,/ /g'`
|
1994-06-08 13:05:21 +08:00
|
|
|
do
|
|
|
|
result=`$configsub $targ 2>/dev/null`
|
|
|
|
if [ -n "$result" ]; then
|
|
|
|
canon_targets="$canon_targets $result"
|
|
|
|
else
|
|
|
|
# Allow targets that config.sub doesn't recognize, like "all".
|
|
|
|
canon_targets="$canon_targets $targ"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
else
|
|
|
|
# If our target is rs6000 _and nothing else_ then we build only nm!
|
|
|
|
case $target in
|
|
|
|
rs6000-*-lynx*) target_makefile_frag=config/rslynx ;;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
|
|
|
|
all_targets=false
|
|
|
|
build_nlmconv=false
|
1995-09-01 10:24:59 +08:00
|
|
|
nlmconv_defs=
|
1994-06-08 13:05:21 +08:00
|
|
|
build_srconv=false
|
1995-09-01 10:24:59 +08:00
|
|
|
build_dlltool=false
|
|
|
|
dlltool_defs=
|
1994-06-08 13:05:21 +08:00
|
|
|
|
|
|
|
for targ in $target $canon_targets
|
|
|
|
do
|
1995-09-01 10:24:59 +08:00
|
|
|
bfd_target=`${config_shell} $srcdir/../bfd/config.bfd $targ`
|
1994-06-08 13:05:21 +08:00
|
|
|
|
|
|
|
if [ "x$bfd_target" = "xall" ]; then
|
|
|
|
all_targets=true
|
|
|
|
build_nlmconv=true
|
|
|
|
build_srconv=true
|
1995-09-01 10:24:59 +08:00
|
|
|
nlmconv_defs="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC"
|
1994-06-08 13:05:21 +08:00
|
|
|
else
|
|
|
|
case $targ in
|
1995-09-01 10:24:59 +08:00
|
|
|
i[345]86*-*-netware*)
|
|
|
|
build_nlmconv=true
|
|
|
|
nlmconv_defs="$nlmconv_defs -DNLMCONV_I386"
|
|
|
|
;;
|
|
|
|
alpha*-*-netware*)
|
|
|
|
build_nlmconv=true
|
|
|
|
nlmconv_defs="$nlmconv_defs -DNLMCONV_ALPHA"
|
|
|
|
;;
|
|
|
|
powerpc*-*-netware*)
|
|
|
|
build_nlmconv=true
|
|
|
|
nlmconv_defs="$nlmconv_defs -DNLMCONV_POWERPC"
|
|
|
|
;;
|
|
|
|
sparc*-*-netware*)
|
|
|
|
build_nlmconv=true
|
|
|
|
nlmconv_defs="$nlmconv_defs -DNLMCONV_SPARC"
|
|
|
|
;;
|
1994-06-08 13:05:21 +08:00
|
|
|
esac
|
|
|
|
case $targ in
|
|
|
|
*-*-hms*) build_srconv=true ;;
|
|
|
|
esac
|
1995-09-01 10:24:59 +08:00
|
|
|
case $targ in
|
|
|
|
arm-*pe*)
|
|
|
|
build_dlltool=true;
|
|
|
|
dlltool_defs="$dlltool_defs -DDLLTOOL_ARM"
|
|
|
|
;;
|
|
|
|
i[3-6]86-*pe* | i[3-6]86-*-win32)
|
|
|
|
build_dlltool=true;
|
|
|
|
dlltool_defs="$dlltool_defs -DDLLTOOL_I386"
|
|
|
|
;;
|
|
|
|
esac
|
1994-06-08 13:05:21 +08:00
|
|
|
fi
|
|
|
|
done
|
|
|
|
|
|
|
|
# We don't do any links based on the target system, just makefile config.
|
|
|
|
|
|
|
|
# post-target:
|
|
|
|
|
|
|
|
rm -f Makefile.tmp Makefile.2
|
|
|
|
mv Makefile Makefile.tmp
|
|
|
|
|
|
|
|
if [ "x${build_nlmconv}" = "xtrue" ]; then
|
|
|
|
echo 'BUILD_NLMCONV = $(NLMCONV_PROG)' >> Makefile.2
|
1995-09-01 10:24:59 +08:00
|
|
|
echo "NLMCONV_DEFS = ${nlmconv_defs}" >> Makefile.2
|
1994-06-08 13:05:21 +08:00
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "x${build_srconv}" = "xtrue" ]; then
|
|
|
|
echo 'BUILD_SRCONV = $(SRCONV_PROG)' >> Makefile.2
|
|
|
|
fi
|
|
|
|
|
1995-09-01 10:24:59 +08:00
|
|
|
if [ "x${build_dlltool}" = "xtrue" ]; then
|
|
|
|
echo 'BUILD_DLLTOOL = $(DLLTOOL_PROG)' >> Makefile.2
|
|
|
|
echo "DLLTOOL_DEFS = ${dlltool_defs}" >> Makefile.2
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "x`${config_shell} $srcdir/../bfd/config.bfd $target _`" = "xyes" ]; then
|
1994-06-17 05:59:41 +08:00
|
|
|
underscore=1
|
|
|
|
else
|
|
|
|
underscore=0
|
|
|
|
fi
|
|
|
|
echo "UNDERSCORE = ${underscore}" >> Makefile.2
|
|
|
|
|
1994-06-08 13:05:21 +08:00
|
|
|
cat Makefile.tmp >> Makefile.2
|
|
|
|
rm -f Makefile.tmp
|
|
|
|
mv Makefile.2 Makefile
|