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.
16 INSTALLDIR
= /build
/ian
/devo-test
/$(TAG
)
19 host
:= $(shell $(TREE
)/config.guess
)
25 log
= 1>$(canonhost
)-build-log
2>&1
26 tlog
= 1> $(canonhost
)-x-
$$i-build
-log
2>&1
28 canonhost
:= $(shell $(TREE
)/config.sub
$(host
))
30 # Convert config.guess results to a simpler form.
31 ifeq ($(canonhost
),mips-dec-ultrix4.2
)
32 canonhost
:= mips-dec-ultrix
34 ifeq ($(canonhost
),mips-sgi-irix4.0
.1)
35 canonhost
:= mips-sgi-irix4
37 ifeq ($(canonhost
),i486-unknown-sco3.2v4.0
)
38 canonhost
:= i386-sco3.2v4
41 ifeq ($(canonhost
),sparc-sun-sunos4.1
.1)
42 TARGETS
= $(NATIVE
) m68k-aout i386-aout a29k-amd-udi \
43 i960-vxworks m68k-coff m68k-vxworks \
44 i960-intel-nindy sparc-aout sparc-vxworks \
45 sparclite-aout sparclitefrwcompat-aout
49 ifeq ($(canonhost
),m68k-sun-sunos4.1
.1)
50 TARGETS
= $(NATIVE
) m68k-vxworks m68k-aout i386-aout
51 GCC
= gcc
-O
-msoft-float
56 ifeq ($(canonhost
),sparc-sun-solaris2
)
57 TARGETS
= $(NATIVE
) m68k-aout sparc-aout a29k-amd-udi
62 ifeq ($(canonhost
),mips-dec-ultrix
)
63 TARGETS
= $(NATIVE
) m68k-vxworks m68k-aout i960-vxworks \
64 sparc-vxworks m68k-coff i386-aout sparc-aout i960-intel-nindy
70 ifeq ($(canonhost
),mips-sgi-irix4
)
71 TARGETS
= $(NATIVE
) m68k-vxworks a29k-amd-udi
73 CC
= cc -cckr
-Wf
,-XNg1500
-Wf
,-XNk1000
-Wf
,-XNh1500
77 ifeq ($(canonhost
),rs6000-ibm-aix
)
78 TARGETS
= $(NATIVE
) m68k-vxworks i960-vxworks m68k-aout
82 ifeq ($(canonhost
),m68k-hp-hpux
)
83 TARGETS
= m68k-vxworks
84 TMPDIR
:= $(shell mkdir
$(canonhost
)-tmpdir
; cd
$(canonhost
)-tmpdir
; pwd
)
90 ifeq ($(canonhost
),hppa1.1
-hp-hpux
)
91 #TARGETS = m68k-aout m68k-coff m68k-vxworks i960-vxworks a29k-amd-udi
92 TARGETS
= m68k-aout i386-aout a29k-amd-udi \
93 i960-vxworks m68k-coff m68k-vxworks \
94 sparc-aout sparc-vxworks \
95 sparclite-aout sparclitefrwcompat-aout
100 ifeq ($(canonhost
),i386-sco3.2v4
)
101 TARGETS
= $(NATIVE
) i386-aout
109 "host=$(canonhost)" \
113 @echo build started at
`date`
114 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
115 rm -f
/usr
/cygnus
/$(TAG
)
116 ln
-s
$(INSTALLDIR
) /usr
/cygnus
/$(TAG
)
117 @for i in
$(TARGETS
) ; do \
118 if
[ "$$i" = "native" ] ; then \
119 if
[ ! -f
$(canonhost
)-3stage-done
] ; then \
120 echo
"3staging $(canonhost) native" ; \
121 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
) && \
122 echo
" completed successfully" ; \
125 echo
"building $(canonhost) cross to $$i" ; \
126 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-cygnus
$(tlog
) && \
127 echo
" completed successfully" ; \
133 @echo build started at
`date`
134 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
135 rm -f
/usr
/cygnus
/$(TAG
)
136 ln
-s
$(INSTALLDIR
) /usr
/cygnus
/$(TAG
)
137 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
)
141 @echo build started at
`date`
142 @for i in
$(TARGETS
) ; do \
143 if
[ "$$i" = "native" ] ; then \
144 if
[ ! -f
$(canonhost
)-3stage-done
] ; then \
145 echo
"3staging $(canonhost) native" ; \
146 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) $(canonhost
)-stamp-3stage-done
$(log
) && \
147 echo
" completed successfully" ; \
150 echo
"building $(canonhost) cross to $$i:" `date` ; \
151 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-cygnus
$(tlog
) && \
152 echo
" completed successfully" ; \
158 [ -d
$(INSTALLDIR
) ] || mkdir
$(INSTALLDIR
)
159 rm -f
/usr
/cygnus
/$(TAG
)
160 ln
-s
$(INSTALLDIR
) /usr
/cygnus
/$(TAG
)
161 @for i in
$(TARGETS
) ; do \
162 echo
"building $(canonhost) cross to $$i" ; \
163 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-native
$(tlog
) && \
164 echo
" completed successfully" ; \
168 @for i in
$(TARGETS
) ; do \
169 if
[ "$$i" = "native" ] ; then \
170 echo
"config stage1 for $(canonhost)" ; \
171 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do1-config
$(log
) && \
172 echo
" completed successfully" ; \
174 echo
"config $(canonhost) cross to $$i" ; \
175 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i do-native-config
$(tlog
) && \
176 echo
" completed successfully" ; \
182 @for i in
$(TARGETS
) ; do \
183 if
[ "$$i" = "native" ] ; then \
184 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) do1-build
$(log
) && \
185 echo
" completed successfully" ; \
187 echo
"building $(canonhost) cross to $$i" ; \
188 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-native
$(tlog
) && \
189 echo
" completed successfully" ; \
195 @for i in
$(TARGETS
) ; do \
196 if
[ "$$i" = "native" ] ; then \
197 echo
"building 3stage for $(canonhost)" ; \
198 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) all $(log
) && \
199 echo
" completed successfully" ; \
201 echo
"building $(canonhost) cross to $$i" ; \
202 $(MAKE
) -f test-build.mk
$(FLAGS_TO_PASS
) target
=$$i build-cygnus
$(tlog
) && \
203 echo
" completed successfully" ; \