1 srcname="Remote GDB server"
3 gdb_serial_driver=../ser-unix.c
7 . ${srcdir}/../configure.host
9 echo "gdbserver/configure.in: host is $host, target is $target"
11 if [ ! -f ${srcdir}/../config/${gdb_host_cpu}/${gdb_host}.mh ]; then
12 echo '***' "GDB remote does not support host ${host}" 1>&2
16 # We really shouldn't depend on there being a space after XM_FILE= ...
17 hostfile=`awk '$1 == "XM_FILE=" { print $2 }' <${srcdir}/../config/${gdb_host_cpu}/${gdb_host}.mh`
21 . ${srcdir}/../configure.tgt
23 echo "gdbserver/configure.in: host_cpu is $host_cpu, target_cpu is $target_cpu"
25 if [ ! -f ${srcdir}/../config/${gdb_target_cpu}/${gdb_target}.mt ]; then
26 echo '***' "GDB remote does not support target ${target}" 1>&2
30 if [ -z "${removing}" ] ; then
31 cat ${srcdir}/../config/${gdb_host_cpu}/${gdb_host}.mh ${srcdir}/../config/${gdb_target_cpu}/${gdb_target}.mt | awk '$1 == "#msg" {
35 # We really shouldn't depend on there being a space after TM_FILE= ...
36 targetfile=`awk '$1 == "TM_FILE=" { print $2 }' <${srcdir}/../config/${gdb_target_cpu}/${gdb_target}.mt`
38 if [ "${target}" = "${host}" ] ; then
39 nativefile=`awk '$1 == "NAT_FILE=" { print $2 }' <${srcdir}/../config/${gdb_host_cpu}/${gdb_host}.mh`
42 host_makefile_frag=../config/${gdb_host_cpu}/${gdb_host}.mh
43 target_makefile_frag=../config/${gdb_target_cpu}/${gdb_target}.mt
45 # If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile
46 # (NAT_FILE) is not set in the ?config/* file, we don't make the
47 # corresponding links. But we have to remove the xm.h files and tm.h
48 # files anyway, e.g. when switching from "configure host" to
55 if [ "${hostfile}" != "" ]; then
56 if [ -f ${srcdir}/../config/${hostfile} ]; then
57 files="${files} ../config/${hostfile}"
59 files="${files} ../config/${gdb_host_cpu}/${hostfile}"
63 # files="${files} ${gdb_serial_driver}"
64 # links="${links} ser-hardwire.c"
67 if [ "${targetfile}" != "" ]; then
68 if [ -f ${srcdir}/../config/${targetfile} ]; then
69 files="${files} ../config/${targetfile}"
71 files="${files} ../config/${gdb_target_cpu}/${targetfile}"
76 if [ "${nativefile}" != "" ]; then
77 if [ -f ${srcdir}/../config/${nativefile} ]; then
78 files="${files} ../config/${nativefile}"
80 files="${files} ../config/${gdb_host_cpu}/${nativefile}"
83 # temporary scaffolding until all hosts have the host/target/native
86 files="${files} ../config/nm-empty.h"
90 if [ ${target_cpu} = "sparclite" ]; then
91 configdirs="${configdirs} sparclite"
96 if [ "${nativefile}" = "" ] ; then
97 sed -e '/^NATDEPFILES= /s//# NATDEPFILES= /' \
98 < Makefile > Makefile.tem
99 mv -f Makefile.tem Makefile