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