* interp.c (sim_*): Make result void where there isn't one.
[deliverable/binutils-gdb.git] / build-all.mk
CommitLineData
543cf4ac
DZ
1# Build all of the targets for any given host.....
2#
3# This file is going to be ugly. It will be VERY specific to the
4# Cygnus environment and build-process.
5#
85195426
DE
6# Useful targets (rt = recursion target):
7# (please correct or expand on this)
8# FIXME: Might some of these be superfluous?
543cf4ac 9#
85195426
DE
10# all-emacs
11# all-cygnus - set up install directories, build 3stage native and all
12# supported cross targets, then check 3stage'd native
13# (rt = $(canonhost)-stamp-3stage-done, do-cygnus for cross)
14# native - set up install directories, build 3stage native
15# (rt = $(canonhost)-stamp-3stage-1)
16# build-cygnus - build 3stage native and all supported cross targets
17# (rt = $(canonhost)-stamp-3stage-done, build-cygnus for cross)
18# build-latest - build native and all supported cross targets
19# (rt = build-latest)
20# all-native - set up install directories, build native
21# (rt = do-native)
22# all-cross - set up install directories, build all targets
23# (rt = do-cygnus)
24# config - configure native and all supported cross targets
25# (rt = do1-config, do-native-config for cross)
26# build - build native and all supported cross targets
27# (rt = do1-build, build-native for cross)
28# 3build - build 3stage native and all supported cross targets
29# (rt = all, build-cygnus for cross)
30# build-all-latest - build 3stage native and all supported cross targets
31# (rt = $(canonhost)-stamp-3stage-done, build-latest for cross)
44c1515d
DE
32# clean - remove objdir directories, stamp files
33# (rt = clean)
85195426
DE
34#
35# To configure/build for fewer targets, specify TARGETS="native cross1 ...".
36
543cf4ac 37TREE = devo
022f8f67 38include $(TREE)/release-info
543cf4ac 39
8456a631 40TEST_INSTALL_DISK = /tug
543cf4ac 41
022f8f67 42INSTALLDIR = $(TEST_INSTALL_DISK)/$(TREE)-test/$(RELEASE_TAG)
543cf4ac 43
12eda620
ILT
44ifndef host
45host := $(shell $(TREE)/config.guess)
46endif
47
022f8f67
DZ
48NATIVE = native
49
e87f9243
ILT
50GCC = gcc -O
51CFLAGS = -g
52CXXFLAGS = -g -O
9823504d 53MAKEINFOFLAGS =
543cf4ac
DZ
54
55log = 1>$(canonhost)-build-log 2>&1
0689f73a 56clog = 1>$(canonhost)-check-log 2>&1
f74859e4 57cyglog = 1> $(canonhost)-x-$$i-cygnus-build-log 2>&1
39ad69d8 58latestlog = 1> $(canonhost)-x-$$i-latest-build-log 2>&1
f74859e4 59natlog = 1> $(canonhost)-x-$$i-native-build-log 2>&1
543cf4ac
DZ
60
61canonhost := $(shell $(TREE)/config.sub $(host))
12eda620
ILT
62
63# Convert config.guess results to a simpler form.
89da237f
ILT
64ifeq ($(canonhost),sparc-sun-solaris2.1)
65canonhost := sparc-sun-solaris2
66endif
85195426
DE
67ifeq ($(canonhost),sparc-sun-solaris2.3)
68canonhost := sparc-sun-solaris2
69endif
12eda620
ILT
70ifeq ($(canonhost),mips-dec-ultrix4.2)
71canonhost := mips-dec-ultrix
72endif
73ifeq ($(canonhost),mips-sgi-irix4.0.1)
74canonhost := mips-sgi-irix4
75endif
85195426
DE
76ifeq ($(canonhost),mips-sgi-irix4.0.5H)
77canonhost := mips-sgi-irix4
78endif
db526bd7
ILT
79ifeq ($(canonhost),rs6000-ibm-aix3.2)
80canonhost := rs6000-ibm-aix
81endif
12eda620 82ifeq ($(canonhost),i486-unknown-sco3.2v4.0)
21412832
ILT
83canonhost := i386-sco3.2v4
84endif
ec782faa
DZ
85ifeq ($(canonhost),i386-unknown-sco3.2v4.0)
86canonhost := i386-sco3.2v4
87endif
08629ab8
DZ
88ifeq ($(canonhost),i386-unknown-sco3.2v4)
89canonhost := i386-sco3.2v4
90endif
60986901
ILT
91ifeq ($(canonhost),i386-unknown-go32)
92canonhost := i386-go32
93endif
89745e93
DZ
94ifeq ($(canonhost),i386-unknown-sysv4.2)
95canonhost := i386-sysv4.2
96endif
f358c814 97ifeq ($(canonhost),i386-lynx-lynxos)
8456a631 98canonhost := i386-lynx
f358c814
DZ
99endif
100ifeq ($(canonhost),m68k-lynx-lynxos)
8456a631 101canonhost := m68k-lynx
f358c814 102endif
543cf4ac 103
32480238
DZ
104ifeq ($(canonhost),sparc-sun-sunos4.1.3)
105TARGETS = $(NATIVE) \
d5b2cb76 106 i386-go32 \
32480238 107 a29k-amd-udi \
d5b2cb76
DZ
108 h8300-hms \
109 i386-aout \
110 i386-lynx \
8456a631 111 i960-vxworks \
32480238
DZ
112 mips-idt-ecoff \
113 m68k-aout m68k-vxworks m68k-coff \
d5b2cb76
DZ
114 m68k-lynx \
115 sh-hms \
116 sparc-aout sparc-vxworks \
117 sparclite-aout sparclite-vxworks \
8456a631 118 sparclite-coff z8k-coff
32480238 119GCC = gcc -O -pipe
543cf4ac
DZ
120all: all-cygnus
121endif
122
123ifeq ($(canonhost),m68k-sun-sunos4.1.1)
32480238 124TARGETS = $(NATIVE) \
a4c50dd0 125 m68k-coff
e37dbf93 126GCC = gcc -O -msoft-float
7cc2923a 127CC = cc -J
543cf4ac
DZ
128all: all-cygnus
129endif
130
131ifeq ($(canonhost),sparc-sun-solaris2)
32480238 132TARGETS = $(NATIVE) \
d5b2cb76 133 a29k-amd-udi \
a4c50dd0 134 i960-vxworks \
8456a631
KC
135 m68k-aout m68k-coff m68k-vxworks \
136 m88k-coff \
a4c50dd0
KC
137 mipsel-idt-ecoff \
138 sparclite-aout
6d98b3d2 139CC = cc -Xs
32480238 140GCC = gcc -O -pipe
543cf4ac
DZ
141all: all-cygnus
142endif
143
144ifeq ($(canonhost),mips-dec-ultrix)
e110c2a8 145TARGETS = $(NATIVE) m68k-aout
872ff7ef 146CC = cc -Wf,-XNg1000
543cf4ac
DZ
147all: all-cygnus
148endif
149
150ifeq ($(canonhost),mips-sgi-irix4)
89745e93
DZ
151TARGETS = $(NATIVE) \
152 mips-idt-ecoff sh-hms
fea15001 153CC = cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000
543cf4ac
DZ
154all: all-cygnus
155endif
156
157ifeq ($(canonhost),rs6000-ibm-aix)
32480238 158TARGETS = $(NATIVE) \
a4c50dd0
KC
159 i960-vxworks \
160 m68k-aout
543cf4ac
DZ
161all: all-cygnus
162endif
163
164ifeq ($(canonhost),m68k-hp-hpux)
07be0634 165TARGETS = $(NATIVE) m68k-aout
e37dbf93 166TMPDIR := $(shell mkdir $(canonhost)-tmpdir; cd $(canonhost)-tmpdir ; pwd)
32480238
DZ
167CC = cc -Wp,-P
168#CFLAGS = +O1000
c262769a 169CFLAGS =
eb0293dc 170all: all-cygnus
543cf4ac
DZ
171endif
172
173ifeq ($(canonhost),hppa1.1-hp-hpux)
32480238 174TARGETS = \
d5b2cb76 175 $(NATIVE) \
32480238 176 i960-vxworks \
d5b2cb76 177 m68k-aout m68k-vxworks
32480238
DZ
178CC = cc
179#CFLAGS = +Obb2000
180CFLAGS = -g
26de3d0c 181all: all-native
543cf4ac
DZ
182endif
183
21412832
ILT
184ifeq ($(canonhost),i386-sco3.2v4)
185TARGETS = $(NATIVE) i386-aout
21412832
ILT
186all: all-cygnus
187endif
188
60986901 189ifeq ($(canonhost),i386-go32)
d5b2cb76 190TARGETS = \
32480238 191 a29k-amd-udi \
d5b2cb76
DZ
192 h8300-hms \
193 i386-aout \
32480238 194 m68k-aout m68k-coff \
d5b2cb76
DZ
195 mips-idt-ecoff \
196 sh-hms \
32480238 197 sparclite-aout
60986901
ILT
198CC = i386-go32-gcc
199GCC = i386-go32-gcc -O
9823504d
ILT
200CFLAGS =
201CXXFLAGS = -O
202MAKEINFOFLAGS = --no-split
60986901
ILT
203all: all-cross
204endif
205
7f82101d 206ifeq ($(canonhost),i386-sysv4.2)
a4c50dd0 207TARGETS = $(NATIVE) i386-netware
32480238
DZ
208CC = cc
209all: all-cygnus
210endif
211
8456a631 212ifeq ($(canonhost),i386-lynx)
f358c814
DZ
213TARGETS = $(NATIVE)
214CC = /bin/gcc
215all: all-cygnus
fb682d69 216SHELL=/bin/bash
f358c814
DZ
217endif
218
8456a631 219ifeq ($(canonhost),m68k-lynx)
f358c814
DZ
220TARGETS = $(NATIVE)
221CC = /bin/gcc
222all: all-cygnus
fb682d69 223SHELL=/bin/bash
f358c814
DZ
224endif
225
543cf4ac
DZ
226FLAGS_TO_PASS := \
227 "GCC=$(GCC)" \
7cc2923a 228 "CC=$(CC)" \
543cf4ac 229 "CFLAGS=$(CFLAGS)" \
e87f9243 230 "CXXFLAGS=$(CXXFLAGS)" \
12eda620 231 "host=$(canonhost)" \
9823504d 232 "MAKEINFOFLAGS=$(MAKEINFOFLAGS)" \
fb682d69
ME
233 "RELEASE_TAG=$(RELEASE_TAG)" \
234 "SHELL=$(SHELL)"
543cf4ac 235
7ae68194
ME
236# set GNU_MAKE and CONFIG_SHELL correctly in sub-builds
237ifeq ($(patsubst %-lynxos,lynxos,$(canonhost)),lynxos)
238FLAGS_TO_PASS := $(FLAGS_TO_PASS) "GNU_MAKE=$(MAKE)" "CONFIG_SHELL=/bin/bash"
239endif
240
57dfb584
DZ
241all-emacs:
242 @echo build started at `date`
243 [ -d $(INSTALLDIR) ] || mkdir $(INSTALLDIR)
f358c814 244 -rm -f $(ROOTING)/$(RELEASE_TAG)
022f8f67 245 ln -s $(INSTALLDIR) $(ROOTING)/$(RELEASE_TAG)
08629ab8
DZ
246 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) do1 > $(canonhost)-emacs-native-log 2>&1
247 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) do-latest > $(canonhost)-emacs-latest-log 2>&1
57dfb584
DZ
248 @echo done at `date`
249
543cf4ac
DZ
250all-cygnus:
251 @echo build started at `date`
252 [ -d $(INSTALLDIR) ] || mkdir $(INSTALLDIR)
c262769a 253 -rm -f $(ROOTING)/$(RELEASE_TAG) && ln -s $(INSTALLDIR) $(ROOTING)/$(RELEASE_TAG)
543cf4ac
DZ
254 @for i in $(TARGETS) ; do \
255 if [ "$$i" = "native" ] ; then \
75217b36 256 if [ ! -f $(canonhost)-stamp-3stage-done ] ; then \
543cf4ac 257 echo "3staging $(canonhost) native" ; \
21412832 258 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) $(canonhost)-stamp-3stage-done $(log) && \
543cf4ac 259 echo " completed successfully" ; \
75217b36
ILT
260 else \
261 true ; \
1900e815 262 fi ; \
543cf4ac
DZ
263 else \
264 echo "building $(canonhost) cross to $$i" ; \
f74859e4 265 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i do-cygnus $(cyglog) && \
543cf4ac
DZ
266 echo " completed successfully" ; \
267 fi ; \
268 done
0689f73a
ME
269 @if [ ! -f $(canonhost)-stamp-3stage-checked ] ; then \
270 echo checking $(canonhost) native ; \
271 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) $(canonhost)-check-3stage $(clog) ; \
272 touch $(canonhost)-stamp-3stage-checked ; \
273 else \
274 true ; \
275 fi
543cf4ac
DZ
276 @echo done at `date`
277
c676f606
DZ
278native:
279 @echo build started at `date`
280 [ -d $(INSTALLDIR) ] || mkdir $(INSTALLDIR)
022f8f67
DZ
281 rm -f $(ROOTING)/$(RELEASE_TAG)
282 ln -s $(INSTALLDIR) $(ROOTING)/$(RELEASE_TAG)
21412832 283 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) $(canonhost)-stamp-3stage-done $(log)
c676f606
DZ
284 @echo done at `date`
285
5ba00487
DZ
286build-cygnus:
287 @echo build started at `date`
288 @for i in $(TARGETS) ; do \
289 if [ "$$i" = "native" ] ; then \
290 if [ ! -f $(canonhost)-3stage-done ] ; then \
291 echo "3staging $(canonhost) native" ; \
21412832 292 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) $(canonhost)-stamp-3stage-done $(log) && \
5ba00487 293 echo " completed successfully" ; \
1900e815 294 fi ; \
5ba00487 295 else \
13ec8aad 296 echo "building $(canonhost) cross to $$i:" `date` ; \
f74859e4 297 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build-cygnus $(cyglog) && \
5ba00487
DZ
298 echo " completed successfully" ; \
299 fi ; \
300 done
301 @echo done at `date`
302
39ad69d8
DZ
303build-latest:
304 @echo build started at `date`
305 @for i in $(TARGETS) ; do \
306 if [ "$$i" != "native" ] ; then \
307 echo "building $(canonhost) cross to $$i:" `date` ; \
308 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build-latest $(latestlog) && \
309 echo " completed successfully" ; \
310 fi ; \
311 done
312 @echo done at `date`
313
543cf4ac
DZ
314all-native:
315 [ -d $(INSTALLDIR) ] || mkdir $(INSTALLDIR)
022f8f67
DZ
316 rm -f $(ROOTING)/$(RELEASE_TAG)
317 ln -s $(INSTALLDIR) $(ROOTING)/$(RELEASE_TAG)
543cf4ac
DZ
318 @for i in $(TARGETS) ; do \
319 echo "building $(canonhost) cross to $$i" ; \
f74859e4 320 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i do-native $(natlog) && \
543cf4ac
DZ
321 echo " completed successfully" ; \
322 done
323
60986901
ILT
324all-cross:
325 [ -d $(INSTALLDIR) ] || mkdir $(INSTALLDIR)
a9377e86
ILT
326 rm -f $(ROOTING)/$(RELEASE_TAG)
327 ln -s $(INSTALLDIR) $(ROOTING)/$(RELEASE_TAG)
60986901
ILT
328 @for i in $(TARGETS) ; do \
329 echo "building $(canonhost) cross to $$i" ; \
f74859e4 330 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build=$(build) do-cygnus $(cyglog) && \
60986901
ILT
331 echo " completed successfully" ; \
332 done
333
8456a631
KC
334do-dos:
335 $(MAKE) -f build-all.mk build=$(host) host=i386-go32 all-dos
336all-dos:
337 @for i in $(TARGETS) ; do \
338 echo "building $(canonhost) cross to $$i" ; \
339 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) host=$(host) target=$$i do-dos $
340(cyglog) && \
341 echo " completed successfully at `date`" ; \
342 done
343
543cf4ac
DZ
344config:
345 @for i in $(TARGETS) ; do \
346 if [ "$$i" = "native" ] ; then \
347 echo "config stage1 for $(canonhost)" ; \
348 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) do1-config $(log) && \
349 echo " completed successfully" ; \
350 else \
351 echo "config $(canonhost) cross to $$i" ; \
f74859e4 352 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i do-native-config $(cyglog) && \
543cf4ac
DZ
353 echo " completed successfully" ; \
354 fi ; \
355 done
356
357
358build:
359 @for i in $(TARGETS) ; do \
360 if [ "$$i" = "native" ] ; then \
361 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) do1-build $(log) && \
362 echo " completed successfully" ; \
363 else \
364 echo "building $(canonhost) cross to $$i" ; \
c262769a 365 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build-native $(natlog) && \
543cf4ac
DZ
366 echo " completed successfully" ; \
367 fi ; \
368 done
369
370
3713build:
372 @for i in $(TARGETS) ; do \
373 if [ "$$i" = "native" ] ; then \
374 echo "building 3stage for $(canonhost)" ; \
375 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) all $(log) && \
376 echo " completed successfully" ; \
377 else \
378 echo "building $(canonhost) cross to $$i" ; \
f74859e4 379 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build-cygnus $(cyglog) && \
543cf4ac
DZ
380 echo " completed successfully" ; \
381 fi ; \
382 done
383
87c6c079
DZ
384build-all-latest:
385 @for i in $(TARGETS) ; do \
386 if [ "$$i" = "native" ] ; then \
387 echo "building 3stage for $(canonhost)" ; \
388 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) $(canonhost)-stamp-3stage-done $(log) && \
389 echo " completed successfully" ; \
390 else \
391 echo "building $(canonhost) cross to $$i" ; \
392 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) target=$$i build-latest $(cyglog) && \
393 echo " completed successfully" ; \
394 fi ; \
395 done
396
44c1515d
DE
397clean:
398 $(MAKE) -f test-build.mk $(FLAGS_TO_PASS) clean $(log)
399
543cf4ac
DZ
400### Local Variables:
401### fill-column: 131
402### End:
This page took 0.091249 seconds and 4 git commands to generate.