Merge branch 'master' of git://git.denx.de/u-boot-mpc83xx
[oweals/u-boot.git] / MAKEALL
1 #!/bin/bash
2
3 # Print statistics when we exit
4 trap exit 1 2 3 15
5 trap print_stats 0
6
7 # Determine number of CPU cores if no default was set
8 : ${BUILD_NCPUS:="`getconf _NPROCESSORS_ONLN`"}
9
10 if [ "$BUILD_NCPUS" -gt 1 ]
11 then
12         JOBS="-j $((BUILD_NCPUS + 1))"
13 else
14         JOBS=""
15 fi
16
17
18 if [ "${CROSS_COMPILE}" ] ; then
19         MAKE="make CROSS_COMPILE=${CROSS_COMPILE}"
20 else
21         MAKE=make
22 fi
23
24 if [ "${MAKEALL_LOGDIR}" ] ; then
25         LOG_DIR=${MAKEALL_LOGDIR}
26 else
27         LOG_DIR="LOG"
28 fi
29
30 if [ ! "${BUILD_DIR}" ] ; then
31         BUILD_DIR="."
32 fi
33
34 [ -d ${LOG_DIR} ] || mkdir ${LOG_DIR} || exit 1
35
36 LIST=""
37
38 # Keep track of the number of builds and errors
39 ERR_CNT=0
40 ERR_LIST=""
41 TOTAL_CNT=0
42 RC=0
43
44 #########################################################################
45 ## MPC5xx Systems
46 #########################################################################
47
48 LIST_5xx="              \
49         cmi_mpc5xx      \
50 "
51
52 #########################################################################
53 ## MPC5xxx Systems
54 #########################################################################
55
56 LIST_5xxx="             \
57         BC3450          \
58         cm5200          \
59         cpci5200        \
60         digsy_mtc       \
61         EVAL5200        \
62         fo300           \
63         galaxy5200      \
64         icecube_5200    \
65         inka4x0         \
66         ipek01          \
67         lite5200b       \
68         mcc200          \
69         mecp5200        \
70         motionpro       \
71         munices         \
72         MVBC_P          \
73         MVSMR           \
74         o2dnt           \
75         pcm030          \
76         pf5200          \
77         PM520           \
78         TB5200          \
79         Total5200       \
80         Total5200_Rev2  \
81         TQM5200         \
82         TQM5200_B       \
83         TQM5200S        \
84         v38b            \
85 "
86
87 #########################################################################
88 ## MPC512x Systems
89 #########################################################################
90
91 LIST_512x="             \
92         aria            \
93         mecp5123        \
94         mpc5121ads      \
95         pdm360ng        \
96 "
97
98 #########################################################################
99 ## MPC8xx Systems
100 #########################################################################
101 LIST_8xx="              \
102         Adder87x        \
103         AdderII         \
104         ADS860          \
105         AMX860          \
106         c2mon           \
107         CCM             \
108         cogent_mpc8xx   \
109         ELPT860         \
110         EP88x           \
111         ESTEEM192E      \
112         ETX094          \
113         FADS823         \
114         FADS850SAR      \
115         FADS860T        \
116         FLAGADM         \
117         FPS850L         \
118         GEN860T         \
119         GEN860T_SC      \
120         GENIETV         \
121         GTH             \
122         hermes          \
123         IAD210          \
124         ICU862_100MHz   \
125         IP860           \
126         IVML24          \
127         IVML24_128      \
128         IVML24_256      \
129         IVMS8           \
130         IVMS8_128       \
131         IVMS8_256       \
132         KUP4K           \
133         KUP4X           \
134         LANTEC          \
135         lwmon           \
136         kmsupx4         \
137         MBX             \
138         MBX860T         \
139         mgsuvd          \
140         MHPC            \
141         MPC86xADS       \
142         MPC885ADS       \
143         NETPHONE        \
144         NETTA           \
145         NETTA2          \
146         NETTA_ISDN      \
147         NETVIA          \
148         NETVIA_V2       \
149         NX823           \
150         pcu_e           \
151         QS823           \
152         QS850           \
153         QS860T          \
154         quantum         \
155         R360MPI         \
156         RBC823          \
157         rmu             \
158         RPXClassic      \
159         RPXlite         \
160         RPXlite_DW      \
161         RRvision        \
162         SM850           \
163         spc1920         \
164         SPD823TS        \
165         svm_sc8xx       \
166         SXNI855T        \
167         TK885D          \
168         TOP860          \
169         TQM823L         \
170         TQM823L_LCD     \
171         TQM850L         \
172         TQM855L         \
173         TQM860L         \
174         TQM885D         \
175         uc100           \
176         v37             \
177 "
178
179 #########################################################################
180 ## PPC4xx Systems
181 #########################################################################
182
183 LIST_4xx="              \
184         acadia          \
185         acadia_nand     \
186         ADCIOP          \
187         alpr            \
188         AP1000          \
189         AR405           \
190         arches          \
191         ASH405          \
192         bamboo          \
193         bamboo_nand     \
194         bubinga         \
195         CANBT           \
196         canyonlands     \
197         canyonlands_nand \
198         CMS700          \
199         CPCI2DP         \
200         CPCI405         \
201         CPCI4052        \
202         CPCI405AB       \
203         CPCI405DT       \
204         CPCIISER4       \
205         CRAYL1          \
206         csb272          \
207         csb472          \
208         DASA_SIM        \
209         devconcenter    \
210         dlvision        \
211         DP405           \
212         DU405           \
213         DU440           \
214         ebony           \
215         ERIC            \
216         fx12mm          \
217         G2000           \
218         gdppc440etx     \
219         glacier         \
220         haleakala       \
221         haleakala_nand  \
222         hcu4            \
223         hcu5            \
224         HH405           \
225         HUB405          \
226         intip           \
227         JSE             \
228         KAREF           \
229         katmai          \
230         kilauea         \
231         kilauea_nand    \
232         korat           \
233         luan            \
234         lwmon5          \
235         makalu          \
236         mcu25           \
237         METROBOX        \
238         MIP405          \
239         MIP405T         \
240         ML2             \
241         ml507           \
242         ml507_flash     \
243         neo             \
244         ocotea          \
245         OCRTC           \
246         ORSG            \
247         p3p440          \
248         PCI405          \
249         pcs440ep        \
250         PIP405          \
251         PLU405          \
252         PMC405          \
253         PMC405DE        \
254         PMC440          \
255         PPChameleonEVB  \
256         quad100hd       \
257         rainier         \
258         redwood         \
259         sbc405          \
260         sc3             \
261         sequoia         \
262         sequoia_nand    \
263         taihu           \
264         taishan         \
265         v5fx30teval     \
266         v5fx30teval_flash \
267         VOH405          \
268         VOM405          \
269         W7OLMC          \
270         W7OLMG          \
271         walnut          \
272         WUH405          \
273         xilinx-ppc440-generic \
274         xilinx-ppc440-generic_flash \
275         XPEDITE1000     \
276         yellowstone     \
277         yosemite        \
278         yucca           \
279         zeus            \
280 "
281
282 #########################################################################
283 ## MPC8220 Systems
284 #########################################################################
285
286 LIST_8220="             \
287         Alaska8220      \
288         Yukon8220       \
289 "
290
291 #########################################################################
292 ## MPC824x Systems
293 #########################################################################
294
295 LIST_824x="             \
296         A3000           \
297         barco           \
298         BMW             \
299         CPC45           \
300         CU824           \
301         debris          \
302         eXalion         \
303         HIDDEN_DRAGON   \
304         IDS8247         \
305         linkstation_HGLAN       \
306         MOUSSE          \
307         MUSENKI         \
308         MVBLUE          \
309         OXC             \
310         PN62            \
311         Sandpoint8240   \
312         Sandpoint8245   \
313         sbc8240         \
314         utx8245         \
315 "
316
317 #########################################################################
318 ## MPC8260 Systems (includes 8250, 8255 etc.)
319 #########################################################################
320
321 LIST_8260="             \
322         atc             \
323         cogent_mpc8260  \
324         CPU86           \
325         CPU87           \
326         ep8248          \
327         ep8260          \
328         ep82xxm         \
329         gw8260          \
330         hymod           \
331         IPHASE4539      \
332         ISPAN           \
333         mgcoge          \
334         MPC8260ADS      \
335         MPC8266ADS      \
336         MPC8272ADS      \
337         PM826           \
338         PM828           \
339         ppmc8260        \
340         Rattler8248     \
341         RPXsuper        \
342         rsdproto        \
343         sacsng          \
344         sbc8260         \
345         SCM             \
346         TQM8260_AC      \
347         TQM8260_AD      \
348         TQM8260_AE      \
349         TQM8272         \
350         ZPC1900         \
351 "
352
353 #########################################################################
354 ## MPC83xx Systems (includes 8349, etc.)
355 #########################################################################
356
357 LIST_83xx="             \
358         caddy2          \
359         kmeter1         \
360         MPC8313ERDB_33  \
361         MPC8313ERDB_NAND_66     \
362         MPC8315ERDB     \
363         MPC8315ERDB_NAND        \
364         MPC8323ERDB     \
365         MPC832XEMDS     \
366         MPC832XEMDS_ATM \
367         MPC8349EMDS     \
368         MPC8349ITX      \
369         MPC8349ITXGP    \
370         MPC8360EMDS     \
371         MPC8360EMDS_ATM \
372         MPC8360ERDK_33  \
373         MPC8360ERDK_66  \
374         MPC837XEMDS     \
375         MPC837XERDB     \
376         MVBLM7          \
377         sbc8349         \
378         SIMPC8313_LP    \
379         TQM834x         \
380         vme8349         \
381 "
382
383
384 #########################################################################
385 ## MPC85xx Systems (includes 8540, 8560 etc.)
386 #########################################################################
387
388 LIST_85xx="             \
389         ATUM8548        \
390         MPC8536DS       \
391         MPC8536DS_NAND  \
392         MPC8536DS_SDCARD        \
393         MPC8536DS_SPIFLASH      \
394         MPC8540ADS      \
395         MPC8540EVAL     \
396         MPC8541CDS      \
397         MPC8544DS       \
398         MPC8548CDS      \
399         MPC8555CDS      \
400         MPC8560ADS      \
401         MPC8568MDS      \
402         MPC8569MDS      \
403         MPC8569MDS_ATM  \
404         MPC8569MDS_NAND \
405         MPC8572DS       \
406         MPC8572DS_36BIT \
407         P2020DS         \
408         P2020DS_36BIT   \
409         P1011RDB        \
410         P1011RDB_NAND   \
411         P1011RDB_SDCARD \
412         P1011RDB_SPIFLASH       \
413         P1020RDB        \
414         P1020RDB_NAND   \
415         P1020RDB_SDCARD \
416         P1020RDB_SPIFLASH       \
417         P2010RDB        \
418         P2010RDB_NAND   \
419         P2010RDB_SDCARD \
420         P2010RDB_SPIFLASH       \
421         P2020RDB        \
422         P2020RDB_NAND   \
423         P2020RDB_SDCARD \
424         P2020RDB_SPIFLASH       \
425         PM854           \
426         PM856           \
427         sbc8540         \
428         sbc8548         \
429         sbc8548_PCI_33  \
430         sbc8548_PCI_66  \
431         sbc8548_PCI_33_PCIE \
432         sbc8548_PCI_66_PCIE \
433         sbc8560         \
434         socrates        \
435         stxgp3          \
436         stxssa          \
437         TQM8540         \
438         TQM8541         \
439         TQM8548         \
440         TQM8548_AG      \
441         TQM8548_BE      \
442         TQM8555         \
443         TQM8560         \
444         XPEDITE5200     \
445         XPEDITE5370     \
446 "
447
448 #########################################################################
449 ## MPC86xx Systems
450 #########################################################################
451
452 LIST_86xx="             \
453         MPC8610HPCD     \
454         MPC8641HPCN     \
455         sbc8641d        \
456         XPEDITE5170     \
457 "
458
459 #########################################################################
460 ## 74xx/7xx Systems
461 #########################################################################
462
463 LIST_74xx="             \
464         DB64360         \
465         DB64460         \
466         EVB64260        \
467         mpc7448hpc2     \
468         P3G4            \
469         p3m7448         \
470         PCIPPC2         \
471         PCIPPC6         \
472         ZUMA            \
473 "
474
475 LIST_7xx="              \
476         BAB7xx          \
477         CPCI750         \
478         ELPPC           \
479         p3m750          \
480         ppmc7xx         \
481 "
482
483 #########################################################################
484 ## PowerPC groups
485 #########################################################################
486
487 LIST_TSEC="             \
488         ${LIST_83xx}    \
489         ${LIST_85xx}    \
490         ${LIST_86xx}    \
491 "
492
493 LIST_powerpc="          \
494         ${LIST_5xx}     \
495         ${LIST_512x}    \
496         ${LIST_5xxx}    \
497         ${LIST_8xx}     \
498         ${LIST_8220}    \
499         ${LIST_824x}    \
500         ${LIST_8260}    \
501         ${LIST_83xx}    \
502         ${LIST_85xx}    \
503         ${LIST_86xx}    \
504         ${LIST_4xx}     \
505         ${LIST_74xx}    \
506         ${LIST_7xx}     \
507 "
508
509 # Alias "ppc" -> "powerpc" to not break compatibility with older scripts
510 # still using "ppc" instead of "powerpc"
511 LIST_ppc="              \
512         ${LIST_powerpc} \
513 "
514
515 #########################################################################
516 ## StrongARM Systems
517 #########################################################################
518
519 LIST_SA="               \
520         assabet         \
521         dnp1110         \
522         gcplus          \
523         lart            \
524         shannon         \
525 "
526
527 #########################################################################
528 ## ARM7 Systems
529 #########################################################################
530
531 LIST_ARM7="             \
532         ap7             \
533         ap720t          \
534         armadillo       \
535         B2              \
536         ep7312          \
537         evb4510         \
538         impa7           \
539         integratorap    \
540         lpc2292sodimm   \
541         modnet50        \
542         SMN42           \
543 "
544
545 #########################################################################
546 ## ARM9 Systems
547 #########################################################################
548
549 LIST_ARM9="                     \
550         a320evb                 \
551         ap920t                  \
552         ap922_XA10              \
553         ap926ejs                \
554         ap946es                 \
555         ap966                   \
556         cp920t                  \
557         cp922_XA10              \
558         cp926ejs                \
559         cp946es                 \
560         cp966                   \
561         da830evm                \
562         edb9301                 \
563         edb9302                 \
564         edb9302a                \
565         edb9307                 \
566         edb9307a                \
567         edb9312                 \
568         edb9315                 \
569         edb9315a                \
570         imx27lite               \
571         lpd7a400                \
572         mv88f6281gtw_ge         \
573         mx1ads                  \
574         mx1fs2                  \
575         netstar                 \
576         nhk8815                 \
577         nhk8815_onenand         \
578         omap1510inn             \
579         omap1610h2              \
580         omap1610inn             \
581         omap5912osk             \
582         omap730p2               \
583         openrd_base             \
584         rd6281a                 \
585         sbc2410x                \
586         scb9328                 \
587         sheevaplug              \
588         smdk2400                \
589         smdk2410                \
590         spear300                \
591         spear310                \
592         spear320                \
593         spear600                \
594         suen3                   \
595         trab                    \
596         VCMA9                   \
597         versatile               \
598         versatileab             \
599         versatilepb             \
600         voiceblue               \
601         davinci_dvevm           \
602         davinci_schmoogie       \
603         davinci_sffsdr          \
604         davinci_sonata          \
605         davinci_dm355evm        \
606         davinci_dm355leopard    \
607         davinci_dm365evm        \
608         davinci_dm6467evm       \
609 "
610
611 #########################################################################
612 ## ARM10 Systems
613 #########################################################################
614 LIST_ARM10="            \
615         integratorcp    \
616         cp1026          \
617 "
618
619 #########################################################################
620 ## ARM11 Systems
621 #########################################################################
622 LIST_ARM11="                    \
623         cp1136                  \
624         omap2420h4              \
625         apollon                 \
626         imx31_litekit           \
627         imx31_phycore           \
628         imx31_phycore_eet       \
629         mx31ads                 \
630         mx31pdk                 \
631         mx31pdk_nand            \
632         qong                    \
633         smdk6400                \
634 "
635
636 #########################################################################
637 ## ARM Cortex-A8 Systems
638 #########################################################################
639 LIST_ARM_CORTEX_A8="            \
640         devkit8000              \
641         mx51evk                 \
642         omap3_beagle            \
643         omap3_overo             \
644         omap3_evm               \
645         omap3_pandora           \
646         omap3_sdp3430           \
647         omap3_zoom1             \
648         omap3_zoom2             \
649         smdkc100                \
650 "
651
652 #########################################################################
653 ## AT91 Systems
654 #########################################################################
655
656 LIST_at91="                     \
657         afeb9260                \
658         at91cap9adk             \
659         at91rm9200dk            \
660         at91rm9200ek            \
661         at91sam9260ek           \
662         at91sam9261ek           \
663         at91sam9263ek           \
664         at91sam9g10ek           \
665         at91sam9g20ek           \
666         at91sam9m10g45ek        \
667         at91sam9rlek            \
668         cmc_pu2                 \
669         CPUAT91                 \
670         CPU9260                 \
671         CPU9G20                 \
672         csb637                  \
673         eb_cpux9k2              \
674         kb9202                  \
675         meesc                   \
676         mp2usb                  \
677         m501sk                  \
678         otc570                  \
679         pm9261                  \
680         pm9263                  \
681         SBC35_A9G20             \
682         TNY_A9260               \
683         TNY_A9G20               \
684 "
685
686 #########################################################################
687 ## Xscale Systems
688 #########################################################################
689
690 LIST_pxa="              \
691         cerf250         \
692         cradle          \
693         csb226          \
694         delta           \
695         innokom         \
696         lubbock         \
697         pleb2           \
698         polaris         \
699         pxa255_idp      \
700         trizepsiv       \
701         wepep250        \
702         xaeniax         \
703         xm250           \
704         xsengine        \
705         zylonite        \
706 "
707
708 LIST_ixp="              \
709         actux1          \
710         actux2          \
711         actux3          \
712         actux4          \
713         ixdp425         \
714         ixdpg425        \
715         pdnb3           \
716         scpu            \
717 "
718
719 #########################################################################
720 ## ARM groups
721 #########################################################################
722
723 LIST_arm="                      \
724         ${LIST_SA}              \
725         ${LIST_ARM7}            \
726         ${LIST_ARM9}            \
727         ${LIST_ARM10}           \
728         ${LIST_ARM11}           \
729         ${LIST_ARM_CORTEX_A8}   \
730         ${LIST_at91}            \
731         ${LIST_pxa}             \
732         ${LIST_ixp}             \
733 "
734
735 #########################################################################
736 ## MIPS Systems         (default = big endian)
737 #########################################################################
738
739 LIST_mips4kc="          \
740         incaip          \
741         qemu_mips       \
742         vct_platinum    \
743         vct_platinum_small      \
744         vct_platinum_onenand    \
745         vct_platinum_onenand_small      \
746         vct_platinumavc \
747         vct_platinumavc_small   \
748         vct_platinumavc_onenand \
749         vct_platinumavc_onenand_small   \
750         vct_premium     \
751         vct_premium_small       \
752         vct_premium_onenand     \
753         vct_premium_onenand_small       \
754 "
755
756 LIST_mips5kc="          \
757         purple          \
758 "
759
760 LIST_au1xx0="           \
761         dbau1000        \
762         dbau1100        \
763         dbau1500        \
764         dbau1550        \
765         dbau1550_el     \
766         gth2            \
767 "
768
769 LIST_mips="             \
770         ${LIST_mips4kc} \
771         ${LIST_mips5kc} \
772         ${LIST_au1xx0}  \
773 "
774
775 #########################################################################
776 ## MIPS Systems         (little endian)
777 #########################################################################
778
779 LIST_mips4kc_el=""
780
781 LIST_mips5kc_el=""
782
783 LIST_au1xx0_el="        \
784         dbau1550_el     \
785         pb1000          \
786 "
787
788 LIST_mips_el="                  \
789         ${LIST_mips4kc_el}      \
790         ${LIST_mips5kc_el}      \
791         ${LIST_au1xx0_el}       \
792 "
793
794 #########################################################################
795 ## i386 Systems
796 #########################################################################
797
798 LIST_I486="             \
799         sc520_cdp       \
800         sc520_eNET      \
801         sc520_spunk     \
802         sc520_spunk_rel \
803 "
804
805 LIST_x86="              \
806         ${LIST_I486}    \
807 "
808
809 #########################################################################
810 ## NIOS Systems
811 #########################################################################
812
813 LIST_nios="                     \
814         ADNPESC1                \
815         ADNPESC1_base_32        \
816         ADNPESC1_DNPEVA2_base_32\
817         DK1C20                  \
818         DK1C20_standard_32      \
819         DK1S10                  \
820         DK1S10_standard_32      \
821         DK1S10_mtx_ldk_20       \
822 "
823
824 #########################################################################
825 ## Nios-II Systems
826 #########################################################################
827
828 LIST_nios2="            \
829         EP1C20          \
830         EP1S10          \
831         EP1S40          \
832         PCI5441         \
833         PK1C20          \
834         nios2-generic   \
835 "
836
837 #########################################################################
838 ## MicroBlaze Systems
839 #########################################################################
840
841 LIST_microblaze="                       \
842         microblaze-generic              \
843 "
844
845 #########################################################################
846 ## ColdFire Systems
847 #########################################################################
848
849 LIST_coldfire="                 \
850         astro_mcf5373l          \
851         cobra5272               \
852         EB+MCF-EV123            \
853         EB+MCF-EV123_internal   \
854         idmr                    \
855         M5208EVBE               \
856         M52277EVB               \
857         M5235EVB                \
858         M5249EVB                \
859         M5253DEMO               \
860         M5253EVBE               \
861         M5271EVB                \
862         M5272C3                 \
863         M5275EVB                \
864         M5282EVB                \
865         M53017EVB               \
866         M5329AFEE               \
867         M5373EVB                \
868         M54451EVB               \
869         M54455EVB               \
870         M5475AFE                \
871         M5485AFE                \
872         TASREG                  \
873 "
874
875 #########################################################################
876 ## AVR32 Systems
877 #########################################################################
878
879 LIST_avr32="            \
880         atstk1002       \
881         atstk1003       \
882         atstk1004       \
883         atstk1006       \
884         atngw100        \
885         favr-32-ezkit   \
886         hammerhead      \
887         mimc200         \
888 "
889
890 #########################################################################
891 ## Blackfin Systems
892 #########################################################################
893
894 LIST_blackfin="         \
895         bf518f-ezbrd    \
896         bf526-ezbrd     \
897         bf527-ezkit     \
898         bf527-ezkit-v2  \
899         bf533-ezkit     \
900         bf533-stamp     \
901         bf537-minotaur  \
902         bf537-pnav      \
903         bf537-srv1      \
904         bf537-stamp     \
905         bf538f-ezkit    \
906         bf548-ezkit     \
907         bf561-acvilon   \
908         bf561-ezkit     \
909         blackstamp      \
910         cm-bf527        \
911         cm-bf533        \
912         cm-bf537e       \
913         cm-bf537u       \
914         cm-bf548        \
915         cm-bf561        \
916         ibf-dsp561      \
917         ip04            \
918         tcm-bf518       \
919         tcm-bf537       \
920 "
921
922 #########################################################################
923 ## SH Systems
924 #########################################################################
925
926 LIST_sh2="              \
927         rsk7203         \
928 "
929 LIST_sh3="              \
930         mpr2            \
931         ms7720se        \
932 "
933
934 LIST_sh4="              \
935         ms7750se        \
936         ms7722se        \
937         MigoR           \
938         r7780mp         \
939         r2dplus         \
940         sh7763rdp       \
941         sh7785lcr       \
942         ap325rxa        \
943         espt            \
944 "
945
946 LIST_sh="               \
947         ${LIST_sh2}     \
948         ${LIST_sh3}     \
949         ${LIST_sh4}     \
950 "
951
952 #########################################################################
953 ## SPARC Systems
954 #########################################################################
955
956 LIST_sparc="gr_xc3s_1500        gr_cpci_ax2000  gr_ep2s60       grsim   grsim_leon2"
957
958 #-----------------------------------------------------------------------
959
960 #----- for now, just run PowerPC by default -----
961 [ $# = 0 ] && set $LIST_powerpc
962
963 #-----------------------------------------------------------------------
964
965 build_target() {
966         target=$1
967
968         ${MAKE} distclean >/dev/null
969         ${MAKE} ${target}_config
970
971         ${MAKE} ${JOBS} all 2>&1 >${LOG_DIR}/$target.MAKELOG \
972                                 | tee ${LOG_DIR}/$target.ERR
973
974         # Check for 'make' errors
975         if [ ${PIPESTATUS[0]} -ne 0 ] ; then
976                 RC=1
977         fi
978
979         if [ -s ${LOG_DIR}/$target.ERR ] ; then
980                 ERR_CNT=$((ERR_CNT + 1))
981                 ERR_LIST="${ERR_LIST} $target"
982         else
983                 rm ${LOG_DIR}/$target.ERR
984         fi
985
986         TOTAL_CNT=$((TOTAL_CNT + 1))
987
988         ${CROSS_COMPILE}size ${BUILD_DIR}/u-boot \
989                                 | tee -a ${LOG_DIR}/$target.MAKELOG
990 }
991
992 #-----------------------------------------------------------------------
993
994 print_stats() {
995         echo ""
996         echo "--------------------- SUMMARY ----------------------------"
997         echo "Boards compiled: ${TOTAL_CNT}"
998         if [ ${ERR_CNT} -gt 0 ] ; then
999                 echo "Boards with warnings or errors: ${ERR_CNT} (${ERR_LIST} )"
1000         fi
1001         echo "----------------------------------------------------------"
1002
1003         exit $RC
1004 }
1005
1006 #-----------------------------------------------------------------------
1007 for arg in $@
1008 do
1009         case "$arg" in
1010         arm|SA|ARM7|ARM9|ARM10|ARM11|ARM_CORTEX_A8|at91|ixp|pxa \
1011         |avr32 \
1012         |blackfin \
1013         |coldfire \
1014         |microblaze \
1015         |mips|mips_el \
1016         |nios|nios2 \
1017         |ppc|powerpc|5xx|5xxx|512x|8xx|8220|824x|8260|83xx|85xx|86xx|4xx|7xx|74xx|TSEC \
1018         |sh|sh2|sh3|sh4 \
1019         |sparc \
1020         |x86|I486 \
1021         )
1022                         for target in `eval echo '$LIST_'${arg}`
1023                         do
1024                                 build_target ${target}
1025                         done
1026                         ;;
1027         *)              build_target ${arg}
1028                         ;;
1029         esac
1030 done