s/GDB_MULTI_ARCH[ ]*=[ ]*\([^ ]*\)[ ]*/\1/p
' ${target_makefile_frag}`
-# these really aren't orthogonal true/false values of the same condition,
-# but shells are slow enough that I like to reuse the test conditions
-# whenever possible
if test "${target}" = "${host}"; then
+# We pick this up from the host configuration file (.mh) because we
+# do not have a native configuration Makefile fragment.
nativefile=`sed -n '
s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
' ${host_makefile_frag}`
-# else
-# GDBserver is only useful in a "native" environment
-# configdirs=`echo $configdirs | sed 's/gdbserver//'`
fi
*) { echo "configure: error: "GDB: Unknown GDB_MULTI_ARCH value ${GDB_MULTI_ARCH}"" 1>&2; exit 1; };;
esac
-
SUBDIRS="doc testsuite nlm"
if test "${enable_multi_ice}" = "yes"; then
SUBDIRS="${SUBDIRS} multi-ice"
fi
+# ``gdbserver'' can only be built in a native configuration.
+if test x"${target}" = x"${host}"; then
+ echo $ac_n "checking whether gdbserver is supported on this host""... $ac_c" 1>&6
+echo "configure:8521: checking whether gdbserver is supported on this host" >&5
+ if test x"${build_gdbserver}" = xyes ; then
+ configdirs="${configdirs} gdbserver"
+ SUBDIRS="${SUBDIRS} gdbserver"
+ echo "$ac_t""yes" 1>&6
+ else
+ echo "$ac_t""no" 1>&6
+ fi
+fi
+
# If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:8575: checking whether ln -s works" >&5
+echo "configure:8583: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:8599: checking for Cygwin environment" >&5
+echo "configure:8607: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8604 "configure"
+#line 8612 "configure"
#include "confdefs.h"
int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:8615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8623: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:8632: checking for mingw32 environment" >&5
+echo "configure:8640: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8637 "configure"
+#line 8645 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:8644: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8652: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:8663: checking for executable suffix" >&5
+echo "configure:8671: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:8673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:8681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
*.c | *.o | *.obj | *.ilk | *.pdb) ;;
arc-*-*) gdb_target=arc ;;
arm*-wince-pe) gdb_target=wince ;;
-arm*-*-linux*) gdb_target=linux
- configdirs="$configdirs gdbserver"
+arm*-*-linux*) gdb_target=linux
+ build_gdbserver=yes
;;
arm*-*-netbsd*) gdb_target=nbsd ;;
arm*-*-* | thumb*-*-* | strongarm*-*-*)
fr30-*-elf*) gdb_target=fr30 ;;
-hppa*-*-bsd*) gdb_target=hppabsd
- configdirs="${configdirs} gdbserver" ;;
+hppa*-*-bsd*) gdb_target=hppabsd ;;
hppa*-*-pro*) gdb_target=hppapro ;;
hppa*64*-*-hpux11*) gdb_target=hppa64 ;;
hppa*-*-hpux*) gdb_target=hppahpux ;;
hppa*-*-hiux*) gdb_target=hppahpux ;;
-hppa*-*-osf*) gdb_target=hppaosf
- configdirs="${configdirs} gdbserver" ;;
+hppa*-*-osf*) gdb_target=hppaosf ;;
i[3456]86-sequent-bsd*) gdb_target=symmetry ;;
i[3456]86-sequent-sysv4*) gdb_target=ptx4 ;;
i[3456]86-*-aix*) gdb_target=i386aix ;;
i[3456]86-*-bsd*) gdb_target=i386bsd ;;
i[3456]86-*-freebsd*) gdb_target=fbsd ;;
-i[3456]86-*-netbsdelf*) gdb_target=nbsdelf
- configdirs="${configdirs} gdbserver" ;;
-i[3456]86-*-netbsd*) gdb_target=nbsd
- configdirs="${configdirs} gdbserver" ;;
+i[3456]86-*-netbsdelf*) gdb_target=nbsdelf ;;
+i[3456]86-*-netbsd*) gdb_target=nbsd ;;
i[3456]86-*-os9k) gdb_target=i386os9k ;;
i[3456]86-*-go32*) gdb_target=i386aout ;;
i[3456]86-*-msdosdjgpp*) gdb_target=go32 ;;
-i[3456]86-*-lynxos*) gdb_target=i386lynx
- configdirs="${configdirs} gdbserver" ;;
+i[3456]86-*-lynxos*) gdb_target=i386lynx ;;
i[3456]86-*-openbsd*) gdb_target=obsd ;;
i[3456]86-*-solaris*) gdb_target=i386sol2 ;;
i[3456]86-*-sysv4.2*) gdb_target=i386v42mp ;;
i[3456]86-*-sco*) gdb_target=i386v ;;
i[3456]86-*-sysv*) gdb_target=i386v ;;
i[3456]86-*-linux*) gdb_target=linux
- configdirs="${configdirs} gdbserver" ;;
-i[3456]86-pc-linux-gnu) gdb_target=linux
- configdirs="${configdirs} gdbserver" ;;
+ build_gdbserver=yes
+ ;;
i[3456]86-*-isc*) gdb_target=i386v ;;
i[3456]86-*-mach3*) gdb_target=i386m3 ;;
i[3456]86-*-gnu*) gdb_target=i386gnu ;;
i960-*-vxworks*) gdb_target=vxworks960 ;;
ia64-*-aix*) gdb_target=aix ;;
-ia64-*-linux*) gdb_target=linux ;;
+ia64-*-linux*) gdb_target=linux
+ build_gdbserver=yes
+ ;;
m32r-*-elf*) gdb_target=m32r ;;
m68*-*-coff*) gdb_target=monitor ;;
m68*-*-elf*) gdb_target=monitor ;;
m68*-*-linux*) gdb_target=linux
- configdirs="${configdirs} gdbserver" ;;
-m68*-*-lynxos*) gdb_target=m68klynx
- configdirs="${configdirs} gdbserver" ;;
-m68*-*-netbsd*) gdb_target=nbsd
- configdirs="${configdirs} gdbserver" ;;
+ build_gdbserver=yes
+ ;;
+m68*-*-lynxos*) gdb_target=m68klynx ;;
+m68*-*-netbsd*) gdb_target=nbsd ;;
m68*-*-os68k*) gdb_target=os68k ;;
m68*-*-sunos3*) gdb_target=sun3os3 ;;
-m68*-*-sunos4*) gdb_target=sun3os4
- configdirs="${configdirs} gdbserver" ;;
+m68*-*-sunos4*) gdb_target=sun3os4 ;;
m68*-*-sysv4*) gdb_target=m68kv4 ;;
m68*-*-vxworks*) gdb_target=vxworks68 ;;
mips64*vr4100*el-*-elf*) gdb_target=vr4300el ;;
mips64*vr4100*-*-elf*) gdb_target=vr4100 ;;
mips64*vr5000*el-*-elf*) gdb_target=vr5000el ;;
-mips64*vr5000*-*-elf*) gdb_target=vr5000
- configdirs="${configdirs} gdbserver" ;;
+mips64*vr5000*-*-elf*) gdb_target=vr5000 ;;
mips*tx39*el*-elf*) gdb_target=tx39l ;;
mips*tx39*-elf*) gdb_target=tx39 ;;
mips64*el-*-elf*) gdb_target=embedl64 ;;
mips*-sgi-irix6*) gdb_target=irix6 ;;
mips*-sgi-*) gdb_target=irix3 ;;
mips*-sony-*) gdb_target=bigmips ;;
-mips*-*-linux*) gdb_target=linux ;;
+mips*-*-linux*) gdb_target=linux
+ build_gdbserver=yes
+ ;;
mips*-*-mach3*) gdb_target=mipsm3 ;;
mips*-*-sysv4*) gdb_target=mipsv4 ;;
mips*-*-sysv*) gdb_target=bigmips ;;
none-*-*) gdb_target=none ;;
-ns32k-*-netbsd*) gdb_target=nbsd
- configdirs="${configdirs} gdbserver" ;;
+ns32k-*-netbsd*) gdb_target=nbsd ;;
-powerpc-*-netbsd*) gdb_target=nbsd
- configdirs="${configdirs} gdbserver" ;;
+powerpc-*-netbsd*) gdb_target=nbsd ;;
powerpc-*-aix*) gdb_target=aix ;;
powerpc-*-eabi* | powerpc-*-sysv* | powerpc-*-elf*)
if test -f ../sim/ppc/Makefile; then
else
gdb_target=ppcle-eabi
fi ;;
-powerpc-*-linux*) gdb_target=linux ;;
+powerpc-*-linux*) gdb_target=linux
+ build_gdbserver=yes
+ ;;
powerpc-*-vxworks*) gdb_target=vxworks ;;
-rs6000-*-lynxos*) gdb_target=rs6000lynx
- configdirs="${configdirs} gdbserver" ;;
+rs6000-*-lynxos*) gdb_target=rs6000lynx ;;
rs6000-*-aix4*) gdb_target=aix4 ;;
rs6000-*-*) gdb_target=rs6000 ;;
sh-*-hms) gdb_target=embed ;;
sh-*-coff*) gdb_target=embed ;;
sh-*-elf*) gdb_target=embed ;;
-sh-*-linux*) gdb_target=linux ;;
+sh-*-linux*) gdb_target=linux
+ build_gdbserver=yes
+ ;;
sparc-*-aout*) gdb_target=sparc-em ;;
sparc-*-coff*) gdb_target=sparc-em ;;
sparc-*-elf*) gdb_target=sparc-em ;;
sparc-*-linux*) gdb_target=linux ;;
-sparc-*-lynxos*) gdb_target=sparclynx
- configdirs="${configdirs} gdbserver" ;;
+sparc-*-lynxos*) gdb_target=sparclynx ;;
sparc-*-netbsd*) gdb_target=nbsd ;;
sparc-*-solaris2*) gdb_target=sun4sol2 ;;
-sparc-*-sunos4*) gdb_target=sun4os4
- configdirs="${configdirs} gdbserver" ;;
+sparc-*-sunos4*) gdb_target=sun4os4 ;;
sparc-*-sunos5*) gdb_target=sun4sol2 ;;
sparc-*-vxworks*) gdb_target=vxsparc ;;
sparc-*-*) gdb_target=sun4os4 ;;
esac
;;
-x86_64-*-linux*) gdb_target=x86-64linux
- configdirs="${configdirs} gdbserver" ;;
+x86_64-*-linux*) gdb_target=x86-64linux ;;
z8k-*-coff*) gdb_target=z8k ;;