Merge in irix support.
[deliverable/binutils-gdb.git] / gdb / configure.in
CommitLineData
912e0732
RP
1srcname="GDB"
2srctrigger=main.c
912e0732 3
0df06ca0
RP
4# per-host:
5
6c815bbe
RP
6# map host info into gdb names.
7
8case "${host_cpu}" in
9
10m68k)
11 case "${host_vendor}" in
12 att) gdb_host=3b1 ;;
13 altos)
14 case "${host_os}" in
15 gas) gdb_host=altosgas ;;
16 *) gdb_host=altos ;;
17 esac
18 ;;
19 hp)
20 case ${host_os} in
21 hpux) gdb_host=hp300hpux ;;
22 bsd) gdb_host=hp300bsd ;;
23 esac
24 ;;
25
26 isi) gdb_host=isi ;;
27 sony) gdb_host=news ;;
28 sun)
29 case "${host_os}" in
30 sunos3) gdb_host=sun3os3 ;;
31 sunos4) gdb_host=sun3os4 ;;
32 *) gdb_host=sun3 ;;
33 esac
34 ;;
35 esac
36 ;;
37
38m68000)
39 case "${host_vendor}" in
40 sun)
41 case "${host_os}" in
42 sunos3) gdb_host=sun2os3 ;;
43 sunos4) gdb_host=sun2os4 ;;
44 *) gdb_host=sun2 ;;
45 esac
46 esac
47 ;;
48
49sparc)
50 case "${host_os}" in
51 sunos3) gdb_host=sun4os3 ;;
52 sunos4) gdb_host=sun4os4 ;;
53 *) gdb_host=sun4 ;;
54 esac
55 ;;
56
57m68030)
58 case "${host_vendor}" in
59 sony) gdb_host=news1000 ;;
60 esac
61 ;;
62
63mips)
64 case "${host_vendor}" in
65 sony) gdb_host=bigmips ;;
66 dec) gdb_host=dec3100 ;;
67 little) gdb_host=littlemips ;;
68 esac
69 ;;
70
71i386)
72 case "${host_vendor}" in
73 sun) gdb_host=sun386 ;;
74 sco) gdb_host=i386sco ;;
75 sequent) gdb_host=symmetry ;;
76 *)
77 case "${host_os}" in
78 sysv) gdb_host=i386v ;;
79 sysv32) gdb_host=i386v32 ;;
80 esac
81 ;;
82 esac
83 ;;
84
85c1 | c2) gdb_host=convex ;;
86
87ns32k)
88 case "${host_vendor}" in
89 umax) gdb_host=umax ;;
90 esac
91 ;;
92
93arm | vax | m88k | merlin | none | np1 | pn | pyramid | tahoe) gdb_host=${host_cpu} ;;
94
95### unhandled hosts
96#altosgas
97#i386v-g
98#i386v32-g
99
100esac
101
102if [ ! -f xconfig/${gdb_host} ]; then
103 echo '***' "Gdb does not support host ${host}" 1>&2
912e0732
RP
104 exit 1
105fi
106
bdf3621b 107# We really shouldn't depend on there being a space after XM_FILE= ...
6c815bbe 108hostfile=`awk '$1 == "XM_FILE=" { print $2 }' <xconfig/${gdb_host}`
912e0732 109
0df06ca0 110# per-target:
912e0732 111
6c815bbe
RP
112case "${target_cpu}" in
113
114m68k)
115 case "${target_vendor}" in
116 att) gdb_target=3b1 ;;
117 altos) gdb_target=altos ;;
118 hp)
119 case "${target_os}" in
120 bsd) gdb_target=hp300bsd ;;
121 hpux) gdb_target=hp300hpux ;;
122 esac
123 ;;
124 sun)
125 case "${target_os}" in
126 sunos3) gdb_target=sun3os3 ;;
127 sunos4) gdb_target=sun3os4 ;;
128 *) gdb_target=sun3 ;;
129 esac
130 ;;
131 wrs) gdb_target=vxworks68 ;;
132 isi) gdb_target=isi ;;
133 sony) gdb_target=news ;;
134 esac
135 ;;
136
137m68000)
138 case "${target_vendor}" in
139 sun)
140 case "${target_os}" in
141 sunos3) gdb_target=sun2os3 ;;
142 sunos4) gdb_target=sun2os4 ;;
143 *) gdb_target=sun2 ;;
144 esac
145 esac
146 ;;
147
148m68030)
149 case "${target_vendor}" in
150 sony) gdb_target=news1000 ;;
151 esac
152 ;;
153
69e87de2 154none | tahoe | vax | np1 | pn | np1 | pn | pyramid | merlin | m88k)
6c815bbe 155 gdb_target=${target_cpu} ;;
69e87de2 156a29k) gdb_target=am29k ;;
6c815bbe
RP
157arm) gdb_target=${target_cpu} ;;
158
159mips)
160 case "${target_vendor}" in
161 sony) gdb_target=bigmips ;;
162 dec) gdb_target=dec3100 ;;
163 little) gdb_target=littlemips ;;
164 esac
165 ;;
166
167c1 | c2) gdb_target=convex ;;
168
6c815bbe
RP
169sparc)
170 case "${target_vendor}" in
171 sun)
172 case "${target_os}" in
173 sunos3) gdb_target=sun4os3 ;;
174 sunos4) gdb_target=sun4os4 ;;
175 *) gdb_target=sun4 ;;
176 esac
177 ;;
178 esac
179 ;;
180
181
182i386)
183 case "${target_vendor}" in
69e87de2
RP
184 sco) gdb_target=i386sco ;;
185 sun) gdb_target=sun386 ;;
6c815bbe 186 sequent) gdb_target=symmetry ;;
69e87de2
RP
187 coff) gdb_target=i386v ;;
188 aout) gdb_target=i386v ;;
6c815bbe
RP
189 *)
190 case "${target_os}" in
191 sysv) gdb_target=i386v ;;
192 sysv32) gdb_target=i386v32 ;;
193 esac
194 esac
195 ;;
196
197i960)
198 case "${target_vendor}" in
69e87de2
RP
199 bout | wrs) gdb_target=vxworks960 ;;
200 coff | intel) gdb_target=nindy960 ;;
6c815bbe
RP
201 esac
202 ;;
203
204ns32k)
205 case "${target_vendor}" in
206 utek) gdb_target=umax ;;
207 esac
208 ;;
209
210### unhandled targets
211# altosgas
212# i386v-g
213# i386v32-g
214
215esac
216
217if [ ! -f tconfig/${gdb_target} ]; then
218 echo '***' "Gdb does not support target ${target}" 1>&2
912e0732
RP
219 exit 1
220fi
221
222if [ -z "${removing}" ] ; then
6c815bbe 223 cat xconfig/${gdb_host} tconfig/${gdb_target} | awk '$1 == "#msg" {
912e0732
RP
224 print substr($0,6)}'
225fi
226
bdf3621b 227# We really shouldn't depend on there being a space after TM_FILE= ...
6c815bbe 228targetfile=`awk '$1 == "TM_FILE=" { print $2 }' <tconfig/${gdb_target}`
912e0732 229
6c815bbe
RP
230host_makefile_frag=xconfig/${gdb_host}
231target_makefile_frag=tconfig/${gdb_target}
912e0732 232
bdf3621b 233# If hostfile (XM_FILE) and/or targetfile (TM_FILE) is not set in the
dc0c3f64
JG
234# ?config/* file, we don't make the corresponding links. But we have
235# to remove the xm.h files and tm.h files anyway, e.g. when switching
236# from "configure host" to "configure none".
bdf3621b
JG
237files=
238links=
dc0c3f64 239rm -f xm.h
bdf3621b
JG
240if [ "${hostfile}" != "" ]; then
241 files="${files} ${hostfile}"
242 links="${links} xm.h"
243fi
dc0c3f64 244rm -f tm.h
bdf3621b
JG
245if [ "${targetfile}" != "" ]; then
246 files="${files} ${targetfile}"
247 links="${links} tm.h"
248fi
249
250# post-target:
912e0732 251
bdf3621b
JG
252case ${srcdir} in
253 .)
254 ;;
255 *)
256 grep -s "source ${srcdir}/.gdbinit" .gdbinit 2>/dev/null || \
257 echo "source ${srcdir}/.gdbinit" >> .gdbinit
258esac
259
dc0c3f64 260cat ${srcdir}/alldeps.mak ${srcdir}/depend >>Makefile
This page took 0.040896 seconds and 4 git commands to generate.