1 # Build all of the targets for any given host.....
3 # This file is going to be ugly. It will be VERY specific to the
4 # Cygnus environment and build-process.
9 include $(TREE
)/release-info
11 TEST_INSTALL_DISK
= /cirdan
/abc
13 INSTALLDIR
= $(TEST_INSTALL_DISK
)/$(TREE
)-test/$(RELEASE_TAG
)
16 host
:= $(shell $(TREE
)/config.guess
)
24 log
= 1>$(canonhost
)-build-log
2>&1
25 tlog
= 1> $(canonhost
)-x-
$$i-build
-log
2>&1
27 canonhost
:= $(shell $(TREE
)/config.sub
$(host
))
29 # Convert config.guess results to a simpler form.
30 ifeq ($(canonhost
),mips-dec-ultrix4.2
)
31 canonhost
:= mips-dec-ultrix
33 ifeq ($(canonhost
),mips-sgi-irix4.0
.1)
34 canonhost
:= mips-sgi-irix4
36 ifeq ($(canonhost
),rs6000-ibm-aix3.2
)
37 canonhost
:= rs6000-ibm-aix
39 ifeq ($(canonhost
),i486-unknown-sco3.2v4.0
)
40 canonhost
:= i386-sco3.2v4
42 ifeq ($(canonhost
),i386-unknown-go32
)
43 canonhost
:= i386-go32
46 ifeq ($(canonhost
),sparc-sun-sunos4.1
.1)
47 TARGETS
= $(NATIVE
) i386-go32 m68k-aout m68k-vxworks \
48 i960-intel-nindy i386-aout a29k-amd-udi \
49 sparc-vxworks m68k-coff i960-vxworks sparc-aout \
50 sparclite-aout sparclitefrwcompat-aout h8300-hms \
51 z8k-sim mips-idt-ecoff
55 ifeq ($(canonhost
),m68k-sun-sunos4.1
.1)
56 TARGETS
= $(NATIVE
) m68k-aout m68k-vxworks m68k-coff
57 GCC
= gcc
-O
-msoft-float
62 ifeq ($(canonhost
),sparc-sun-solaris2
)
63 TARGETS
= $(NATIVE
) m68k-vxworks m68k-aout sparc-aout mips-idt-ecoff
68 ifeq ($(canonhost
),mips-dec-ultrix
)
69 TARGETS
= $(NATIVE
) m68k-aout
70 # TARGETS = $(NATIVE) m68k-vxworks m68k-aout i960-vxworks \
71 # sparc-vxworks m68k-coff i386-aout sparc-aout i960-intel-nindy
76 ifeq ($(canonhost
),mips-sgi-irix4
)
77 TARGETS
= $(NATIVE
) m68k-vxworks
78 CC
= cc -cckr
-Wf
,-XNg1500
-Wf
,-XNk1000
-Wf
,-XNh1500
82 ifeq ($(canonhost
),rs6000-ibm-aix
)
83 TARGETS
= $(NATIVE
) m68k-aout m68k-vxworks i960-vxworks
87 ifeq ($(canonhost
),m68k-hp-hpux
)
88 TARGETS
= $(NATIVE
) m68k-vxworks
89 TMPDIR
:= $(shell mkdir
$(canonhost
)-tmpdir
; cd
$(canonhost
)-tmpdir
; pwd
)
95 ifeq ($(canonhost
),hppa1.1
-hp-hpux
)
96 TARGETS
= i960-vxworks m68k-aout m68k-vxworks m68k-hp-hpux
97 #TARGETS = m68k-aout m68k-coff m68k-vxworks i960-vxworks a29k-amd-udi
98 #TARGETS = m68k-aout i386-aout a29k-amd-udi \
99 # i960-vxworks m68k-coff m68k-vxworks \
100 # sparc-aout sparc-vxworks \
101 # sparclite-aout sparclitefrwcompat-aout
106 ifeq ($(canonhost
),i386-sco3.2v4
)
107 TARGETS
= $(NATIVE
) i386-aout
111 ifeq ($(canonhost
),i386-go32
)
112 TARGETS
= m68k-aout a29k-amd-udi m68k-coff i386-aout sparclite-aout \
113 h8300-sim mips-idt-ecoff
115 build
:= $(shell $(TREE
)/config.guess
)
118 GCC
= i386-go32-gcc
-O
126 "host=$(canonhost)" \
127 "RELEASE_TAG=$(RELEASE_TAG)"
130 @echo build started at
`date`
131 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
132 rm -f
$(ROOTING
)/$(RELEASE_TAG
)
133 ln
-s
$(INSTALLDIR
) $(ROOTING
)/$(RELEASE_TAG
)
134 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do1
> $(canonhost
)-native-log
2>&1
135 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do-latest
> $(canonhost
)-latest-log
2>&1
139 @echo build started at
`date`
140 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
141 rm -f
$(ROOTING
)/$(RELEASE_TAG
)
142 ln
-s
$(INSTALLDIR
) $(ROOTING
)/$(RELEASE_TAG
)
143 @for i in
$(TARGETS
) ; do \
144 if
[ "$$i" = "native" ] ; then \
145 if
[ ! -f
$(canonhost
)-3stage-done
] ; then \
146 echo
"3staging $(canonhost) native" ; \
147 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
) && \
148 echo
" completed successfully" ; \
151 echo
"building $(canonhost) cross to $$i" ; \
152 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-cygnus
$(tlog
) && \
153 echo
" completed successfully" ; \
159 @echo build started at
`date`
160 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
161 rm -f
$(ROOTING
)/$(RELEASE_TAG
)
162 ln
-s
$(INSTALLDIR
) $(ROOTING
)/$(RELEASE_TAG
)
163 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
)
167 @echo build started at
`date`
168 @for i in
$(TARGETS
) ; do \
169 if
[ "$$i" = "native" ] ; then \
170 if
[ ! -f
$(canonhost
)-3stage-done
] ; then \
171 echo
"3staging $(canonhost) native" ; \
172 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
) && \
173 echo
" completed successfully" ; \
176 echo
"building $(canonhost) cross to $$i:" `date` ; \
177 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-cygnus
$(tlog
) && \
178 echo
" completed successfully" ; \
184 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
185 rm -f
$(ROOTING
)/$(RELEASE_TAG
)
186 ln
-s
$(INSTALLDIR
) $(ROOTING
)/$(RELEASE_TAG
)
187 @for i in
$(TARGETS
) ; do \
188 echo
"building $(canonhost) cross to $$i" ; \
189 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-native
$(tlog
) && \
190 echo
" completed successfully" ; \
194 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
195 rm -f
/usr
/cygnus
/$(TAG
)
196 ln
-s
$(INSTALLDIR
) /usr
/cygnus
/$(TAG
)
197 @for i in
$(TARGETS
) ; do \
198 echo
"building $(canonhost) cross to $$i" ; \
199 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build
=$(build
) do-cygnus
$(tlog
) && \
200 echo
" completed successfully" ; \
204 @for i in
$(TARGETS
) ; do \
205 if
[ "$$i" = "native" ] ; then \
206 echo
"config stage1 for $(canonhost)" ; \
207 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do1-config
$(log
) && \
208 echo
" completed successfully" ; \
210 echo
"config $(canonhost) cross to $$i" ; \
211 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-native-config
$(tlog
) && \
212 echo
" completed successfully" ; \
218 @for i in
$(TARGETS
) ; do \
219 if
[ "$$i" = "native" ] ; then \
220 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do1-build
$(log
) && \
221 echo
" completed successfully" ; \
223 echo
"building $(canonhost) cross to $$i" ; \
224 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-native
$(tlog
) && \
225 echo
" completed successfully" ; \
231 @for i in
$(TARGETS
) ; do \
232 if
[ "$$i" = "native" ] ; then \
233 echo
"building 3stage for $(canonhost)" ; \
234 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) all $(log
) && \
235 echo
" completed successfully" ; \
237 echo
"building $(canonhost) cross to $$i" ; \
238 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-cygnus
$(tlog
) && \
239 echo
" completed successfully" ; \