8 # map host info into gdb names.
13 case "${host_vendor}" in
17 gas) gdb_host=altosgas ;;
24 amigados) gdb_host=amigados ;;
25 sysv4*) gdb_host=amix ;;
31 hpux) gdb_host=hp300hpux ;;
32 bsd) gdb_host=hp300bsd ;;
37 sony) gdb_host=news ;;
40 sunos3) gdb_host=sun3os3 ;;
41 sunos4) gdb_host=sun3os4 ;;
49 case "${host_vendor}" in
52 sunos3) gdb_host=sun2os3 ;;
53 sunos4) gdb_host=sun2os4 ;;
61 sunos3) gdb_host=sun4os3 ;;
62 sunos4) gdb_host=sun4os4 ;;
68 case "${host_vendor}" in
69 sony) gdb_host=news1000 ;;
74 case "${host_vendor}" in
75 sony) gdb_host=bigmips ;;
76 dec) gdb_host=decstation ;;
77 little) gdb_host=littlemips ;;
78 sgi) gdb_host=irix3 ;;
87 case "${host_vendor}" in
88 sun) gdb_host=sun386 ;;
89 sco) gdb_host=i386sco ;;
90 sequent) gdb_host=symmetry ;;
93 sysv32) gdb_host=i386v32 ;;
94 sysv4*) gdb_host=i386v4 ;;
95 sysv*) gdb_host=i386v ;;
96 scosysv*) gdb_host=i386sco ;;
97 mach) gdb_host=i386mach ;;
103 c1 | c2) gdb_host=convex ;;
106 case "${host_vendor}" in
107 umax) gdb_host=umax ;;
124 case "${host_vendor}" in
132 arm | vax | merlin | none | np1 | pn | pyramid | tahoe)
144 if [ ! -f ${srcdir}/config/mh-${gdb_host} ]; then
145 echo '***' "Gdb does not support host ${host}" 1>&2
149 # We really shouldn't depend on there being a space after XM_FILE= ...
150 hostfile=`awk '$1 == "XM_FILE=" { print $2 }' <${srcdir}/config/mh-${gdb_host}`
154 case "${target_cpu}" in
157 case "${target_vendor}" in
158 att) gdb_target=3b1 ;;
159 altos) gdb_target=altos ;;
162 amigados) gdb_host=amigados ;;
163 sysv4*) gdb_target=amix ;;
167 case "${target_os}" in
168 bsd) gdb_target=hp300bsd ;;
169 hpux) gdb_target=hp300hpux ;;
173 case "${target_os}" in
174 sunos3) gdb_target=sun3os3 ;;
175 sunos4) gdb_target=sun3os4 ;;
176 *) gdb_target=sun3 ;;
179 wrs) gdb_target=vxworks68 ;;
180 isi) gdb_target=isi ;;
181 sony) gdb_target=news ;;
186 case "${target_vendor}" in
188 case "${target_os}" in
189 sunos3) gdb_target=sun2os3 ;;
190 sunos4) gdb_target=sun2os4 ;;
191 *) gdb_target=sun2 ;;
197 case "${target_vendor}" in
198 sony) gdb_target=news1000 ;;
202 none | arm | tahoe | vax | np1 | pn | np1 | pn | pyramid | merlin)
203 gdb_target=${target_cpu} ;;
206 case "${target_vendor}" in
207 motorola) gdb_target=delta88 ;;
208 *) gdb_target=dgux ;;
212 case "${target_os}" in
213 none|aout|coff) gdb_target=a29k ;;
214 sym1) gdb_target=ultra3 ;;
215 kern) gdb_target=a29k-kern ;;
216 ebmon) gdb_target=a29k;;
221 case "${target_vendor}" in
222 sony) gdb_target=bigmips ;;
223 dec) gdb_target=decstation ;;
224 little) gdb_target=littlemips ;;
225 sgi) gdb_target=irix3 ;;
229 c1 | c2) gdb_target=convex ;;
232 case "${target_vendor}" in
234 case "${target_os}" in
235 sunos3) gdb_target=sun4os3 ;;
236 sunos4) gdb_target=sun4os4 ;;
237 *) gdb_target=sun4 ;;
247 i860) gdb_target=stratus
251 case "${target_vendor}" in
252 sco) gdb_target=i386sco ;;
253 sun) gdb_target=sun386 ;;
254 sequent) gdb_target=symmetry ;;
256 case "${target_os}" in
257 sysv32) gdb_target=i386v32 ;;
258 scosysv3*) gdb_target=i386v32 ;;
259 sysv4*) gdb_target=i386v4 ;;
260 sysv*) gdb_target=i386v ;;
261 mach) gdb_target=i386mach ;;
262 coff) gdb_target=i386v ;;
263 aout) gdb_target=i386aout ;;
269 case "${target_vendor}" in
270 bout | wrs) gdb_target=vxworks960 ;;
271 coff | intel) gdb_target=nindy960 ;;
276 case "${target_vendor}" in
277 utek) gdb_target=umax ;;
285 ### unhandled targets
292 if [ ! -f ${srcdir}/config/mt-${gdb_target} ]; then
293 echo '***' "Gdb does not support target ${target}" 1>&2
297 if [ -z "${removing}" ] ; then
298 cat ${srcdir}/config/mh-${gdb_host} ${srcdir}/config/mt-${gdb_target} | awk '$1 == "#msg" {
302 # We really shouldn't depend on there being a space after TM_FILE= ...
303 targetfile=`awk '$1 == "TM_FILE=" { print $2 }' <${srcdir}/config/mt-${gdb_target}`
305 host_makefile_frag=config/mh-${gdb_host}
306 target_makefile_frag=config/mt-${gdb_target}
308 # If hostfile (XM_FILE) and/or targetfile (TM_FILE) is not set in the
309 # ?config/* file, we don't make the corresponding links. But we have
310 # to remove the xm.h files and tm.h files anyway, e.g. when switching
311 # from "configure host" to "configure none".
315 if [ "${hostfile}" != "" ]; then
316 files="${files} ${hostfile}"
317 links="${links} xm.h"
320 if [ "${targetfile}" != "" ]; then
321 files="${files} ${targetfile}"
322 links="${links} tm.h"
331 grep -s "source ${srcdir}/.gdbinit" .gdbinit 2>/dev/null || \
332 echo "source ${srcdir}/.gdbinit" >> .gdbinit
335 cat ${srcdir}/alldeps.mak ${srcdir}/depend >>Makefile