85xx if NUM_CPUS>1, print cpu number
[platform/kernel/u-boot.git] / MAKEALL
1 #!/bin/sh
2
3 : ${JOBS:=}
4
5 if [ "${CROSS_COMPILE}" ] ; then
6         MAKE="make CROSS_COMPILE=${CROSS_COMPILE}"
7 else
8         MAKE=make
9 fi
10
11 if [ "${MAKEALL_LOGDIR}" ] ; then
12         LOG_DIR=${MAKEALL_LOGDIR}
13 else
14         LOG_DIR="LOG"
15 fi
16
17 if [ ! "${BUILD_DIR}" ] ; then
18         BUILD_DIR="."
19 fi
20
21 [ -d ${LOG_DIR} ] || mkdir ${LOG_DIR} || exit 1
22
23 LIST=""
24
25 #########################################################################
26 ## MPC5xx Systems
27 #########################################################################
28
29 LIST_5xx="              \
30         cmi_mpc5xx      \
31 "
32
33 #########################################################################
34 ## MPC5xxx Systems
35 #########################################################################
36
37 LIST_5xxx="             \
38         BC3450          \
39         cm5200          \
40         cpci5200        \
41         EVAL5200        \
42         fo300           \
43         icecube_5100    \
44         icecube_5200    \
45         inka4x0         \
46         lite5200b       \
47         mcc200          \
48         mecp5200        \
49         motionpro       \
50         munices         \
51         MVBC_P          \
52         o2dnt           \
53         pf5200          \
54         PM520           \
55         TB5200          \
56         Total5100       \
57         Total5200       \
58         Total5200_Rev2  \
59         TQM5200         \
60         TQM5200_B       \
61         TQM5200S        \
62         v38b            \
63 "
64
65 #########################################################################
66 ## MPC512x Systems
67 #########################################################################
68
69 LIST_512x="             \
70         ads5121         \
71 "
72
73 #########################################################################
74 ## MPC8xx Systems
75 #########################################################################
76 LIST_8xx="              \
77         Adder87x        \
78         AdderII         \
79         ADS860          \
80         AMX860          \
81         c2mon           \
82         CCM             \
83         cogent_mpc8xx   \
84         ELPT860         \
85         EP88x           \
86         ESTEEM192E      \
87         ETX094          \
88         FADS823         \
89         FADS850SAR      \
90         FADS860T        \
91         FLAGADM         \
92         FPS850L         \
93         GEN860T         \
94         GEN860T_SC      \
95         GENIETV         \
96         GTH             \
97         hermes          \
98         IAD210          \
99         ICU862_100MHz   \
100         IP860           \
101         IVML24          \
102         IVML24_128      \
103         IVML24_256      \
104         IVMS8           \
105         IVMS8_128       \
106         IVMS8_256       \
107         KUP4K           \
108         KUP4X           \
109         LANTEC          \
110         lwmon           \
111         MBX             \
112         MBX860T         \
113         mgsuvd          \
114         MHPC            \
115         MPC86xADS       \
116         MPC885ADS       \
117         NETPHONE        \
118         NETTA           \
119         NETTA2          \
120         NETTA_ISDN      \
121         NETVIA          \
122         NETVIA_V2       \
123         NX823           \
124         pcu_e           \
125         QS823           \
126         QS850           \
127         QS860T          \
128         quantum         \
129         R360MPI         \
130         RBC823          \
131         rmu             \
132         RPXClassic      \
133         RPXlite         \
134         RPXlite_DW      \
135         RRvision        \
136         SM850           \
137         spc1920         \
138         SPD823TS        \
139         svm_sc8xx       \
140         SXNI855T        \
141         TK885D          \
142         TOP860          \
143         TQM823L         \
144         TQM823L_LCD     \
145         TQM850L         \
146         TQM855L         \
147         TQM860L         \
148         TQM885D         \
149         uc100           \
150         v37             \
151 "
152
153 #########################################################################
154 ## PPC4xx Systems
155 #########################################################################
156
157 LIST_4xx="              \
158         acadia          \
159         acadia_nand     \
160         ADCIOP          \
161         alpr            \
162         AP1000          \
163         AR405           \
164         ASH405          \
165         bamboo          \
166         bamboo_nand     \
167         bubinga         \
168         CANBT           \
169         canyonlands     \
170         canyonlands_nand \
171         CMS700          \
172         CPCI2DP         \
173         CPCI405         \
174         CPCI4052        \
175         CPCI405AB       \
176         CPCI405DT       \
177         CPCIISER4       \
178         CRAYL1          \
179         csb272          \
180         csb472          \
181         DASA_SIM        \
182         DP405           \
183         DU405           \
184         DU440           \
185         ebony           \
186         ERIC            \
187         EXBITGEN        \
188         G2000           \
189         glacier         \
190         haleakala       \
191         haleakala_nand  \
192         hcu4            \
193         hcu5            \
194         HH405           \
195         HUB405          \
196         JSE             \
197         KAREF           \
198         katmai          \
199         kilauea         \
200         kilauea_nand    \
201         korat           \
202         luan            \
203         lwmon5          \
204         makalu          \
205         mcu25           \
206         METROBOX        \
207         MIP405          \
208         MIP405T         \
209         ML2             \
210         ml300           \
211         ml507           \
212         ml507_flash     \
213         ocotea          \
214         OCRTC           \
215         ORSG            \
216         p3p440          \
217         PCI405          \
218         pcs440ep        \
219         PIP405          \
220         PLU405          \
221         PMC405          \
222         PMC440          \
223         PPChameleonEVB  \
224         quad100hd       \
225         rainier         \
226         redwood         \
227         sbc405          \
228         sc3             \
229         sequoia         \
230         sequoia_nand    \
231         taihu           \
232         taishan         \
233         v5fx30teval     \
234         v5fx30teval_flash \
235         VOH405          \
236         VOM405          \
237         W7OLMC          \
238         W7OLMG          \
239         walnut          \
240         WUH405          \
241         xilinx-ppc440-generic \
242         xilinx-ppc440-generic_flash \
243         XPEDITE1K       \
244         yellowstone     \
245         yosemite        \
246         yucca           \
247         zeus            \
248 "
249
250 #########################################################################
251 ## MPC8220 Systems
252 #########################################################################
253
254 LIST_8220="             \
255         Alaska8220      \
256         Yukon8220       \
257 "
258
259 #########################################################################
260 ## MPC824x Systems
261 #########################################################################
262
263 LIST_824x="             \
264         A3000           \
265         barco           \
266         BMW             \
267         CPC45           \
268         CU824           \
269         debris          \
270         eXalion         \
271         HIDDEN_DRAGON   \
272         linkstation_HGLAN       \
273         MOUSSE          \
274         MUSENKI         \
275         MVBLUE          \
276         OXC             \
277         PN62            \
278         Sandpoint8240   \
279         Sandpoint8245   \
280         sbc8240         \
281         SL8245          \
282         utx8245         \
283 "
284
285 #########################################################################
286 ## MPC8260 Systems (includes 8250, 8255 etc.)
287 #########################################################################
288
289 LIST_8260="             \
290         atc             \
291         cogent_mpc8260  \
292         CPU86           \
293         CPU87           \
294         ep8248          \
295         ep8260          \
296         ep82xxm         \
297         gw8260          \
298         hymod           \
299         IPHASE4539      \
300         ISPAN           \
301         mgcoge          \
302         MPC8260ADS      \
303         MPC8266ADS      \
304         MPC8272ADS      \
305         PM826           \
306         PM828           \
307         ppmc8260        \
308         Rattler8248     \
309         RPXsuper        \
310         rsdproto        \
311         sacsng          \
312         sbc8260         \
313         SCM             \
314         TQM8260_AC      \
315         TQM8260_AD      \
316         TQM8260_AE      \
317         TQM8272         \
318         ZPC1900         \
319 "
320
321 #########################################################################
322 ## MPC83xx Systems (includes 8349, etc.)
323 #########################################################################
324
325 LIST_83xx="             \
326         MPC8313ERDB_33  \
327         MPC8313ERDB_NAND_66     \
328         MPC8315ERDB     \
329         MPC8323ERDB     \
330         MPC832XEMDS     \
331         MPC832XEMDS_ATM \
332         MPC8349EMDS     \
333         MPC8349ITX      \
334         MPC8349ITXGP    \
335         MPC8360EMDS     \
336         MPC8360EMDS_ATM \
337         MPC8360ERDK_33  \
338         MPC8360ERDK_66  \
339         MPC837XEMDS     \
340         MPC837XERDB     \
341         MVBLM7          \
342         sbc8349         \
343         TQM834x         \
344 "
345
346
347 #########################################################################
348 ## MPC85xx Systems (includes 8540, 8560 etc.)
349 #########################################################################
350
351 LIST_85xx="             \
352         ATUM8548        \
353         MPC8536DS       \
354         MPC8540ADS      \
355         MPC8540EVAL     \
356         MPC8541CDS      \
357         MPC8544DS       \
358         MPC8548CDS      \
359         MPC8555CDS      \
360         MPC8560ADS      \
361         MPC8568MDS      \
362         MPC8572DS       \
363         PM854           \
364         PM856           \
365         sbc8540         \
366         sbc8548         \
367         sbc8560         \
368         socrates        \
369         stxgp3          \
370         stxssa          \
371         TQM8540         \
372         TQM8541         \
373         TQM8548         \
374         TQM8555         \
375         TQM8560         \
376 "
377
378 #########################################################################
379 ## MPC86xx Systems
380 #########################################################################
381
382 LIST_86xx="             \
383         MPC8610HPCD     \
384         MPC8641HPCN     \
385         sbc8641d        \
386 "
387
388 #########################################################################
389 ## 74xx/7xx Systems
390 #########################################################################
391
392 LIST_74xx="             \
393         DB64360         \
394         DB64460         \
395         EVB64260        \
396         mpc7448hpc2     \
397         P3G4            \
398         p3m7448         \
399         PCIPPC2         \
400         PCIPPC6         \
401         ZUMA            \
402 "
403
404 LIST_7xx="              \
405         BAB7xx          \
406         CPCI750         \
407         ELPPC           \
408         p3m750          \
409         ppmc7xx         \
410 "
411
412 #########################################################################
413 ## PowerPC groups
414 #########################################################################
415
416 LIST_TSEC="             \
417         ${LIST_83xx}    \
418         ${LIST_85xx}    \
419         ${LIST_86xx}    \
420 "
421
422 LIST_ppc="              \
423         ${LIST_5xx}     \
424         ${LIST_512x}    \
425         ${LIST_5xxx}    \
426         ${LIST_8xx}     \
427         ${LIST_8220}    \
428         ${LIST_824x}    \
429         ${LIST_8260}    \
430         ${LIST_83xx}    \
431         ${LIST_85xx}    \
432         ${LIST_86xx}    \
433         ${LIST_4xx}     \
434         ${LIST_74xx}    \
435         ${LIST_7xx}     \
436 "
437
438 #########################################################################
439 ## StrongARM Systems
440 #########################################################################
441
442 LIST_SA="               \
443         assabet         \
444         dnp1110         \
445         gcplus          \
446         lart            \
447         shannon         \
448 "
449
450 #########################################################################
451 ## ARM7 Systems
452 #########################################################################
453
454 LIST_ARM7="             \
455         ap7             \
456         ap720t          \
457         armadillo       \
458         B2              \
459         ep7312          \
460         evb4510         \
461         impa7           \
462         integratorap    \
463         lpc2292sodimm   \
464         modnet50        \
465         SMN42           \
466 "
467
468 #########################################################################
469 ## ARM9 Systems
470 #########################################################################
471
472 LIST_ARM9="                     \
473         ap920t                  \
474         ap922_XA10              \
475         ap926ejs                \
476         ap946es                 \
477         ap966                   \
478         cp920t                  \
479         cp922_XA10              \
480         cp926ejs                \
481         cp946es                 \
482         cp966                   \
483         lpd7a400                \
484         mx1ads                  \
485         mx1fs2                  \
486         netstar                 \
487         omap1510inn             \
488         omap1610h2              \
489         omap1610inn             \
490         omap5912osk             \
491         omap730p2               \
492         sbc2410x                \
493         scb9328                 \
494         smdk2400                \
495         smdk2410                \
496         trab                    \
497         VCMA9                   \
498         versatile               \
499         versatileab             \
500         versatilepb             \
501         voiceblue               \
502         davinci_dvevm           \
503         davinci_schmoogie       \
504         davinci_sffsdr          \
505         davinci_sonata          \
506 "
507
508 #########################################################################
509 ## ARM10 Systems
510 #########################################################################
511 LIST_ARM10="            \
512         integratorcp    \
513         cp1026          \
514 "
515
516 #########################################################################
517 ## ARM11 Systems
518 #########################################################################
519 LIST_ARM11="            \
520         cp1136          \
521         omap2420h4      \
522         apollon         \
523         imx31_litekit   \
524         imx31_phycore   \
525         mx31ads         \
526         smdk6400        \
527 "
528
529 #########################################################################
530 ## AT91 Systems
531 #########################################################################
532
533 LIST_at91="             \
534         at91cap9adk     \
535         at91rm9200dk    \
536         at91sam9260ek   \
537         at91sam9261ek   \
538         at91sam9263ek   \
539         at91sam9rlek    \
540         cmc_pu2         \
541         csb637          \
542         kb9202          \
543         mp2usb          \
544         m501sk          \
545 "
546
547 #########################################################################
548 ## Xscale Systems
549 #########################################################################
550
551 LIST_pxa="              \
552         cerf250         \
553         cradle          \
554         csb226          \
555         delta           \
556         innokom         \
557         lubbock         \
558         pleb2           \
559         pxa255_idp      \
560         wepep250        \
561         xaeniax         \
562         xm250           \
563         xsengine        \
564         zylonite        \
565 "
566
567 LIST_ixp="              \
568         actux1          \
569         actux2          \
570         actux3          \
571         actux4          \
572         ixdp425         \
573         ixdpg425        \
574         pdnb3           \
575         scpu            \
576 "
577
578 #########################################################################
579 ## ARM groups
580 #########################################################################
581
582 LIST_arm="              \
583         ${LIST_SA}      \
584         ${LIST_ARM7}    \
585         ${LIST_ARM9}    \
586         ${LIST_ARM10}   \
587         ${LIST_ARM11}   \
588         ${LIST_at91}    \
589         ${LIST_pxa}     \
590         ${LIST_ixp}     \
591 "
592
593 #########################################################################
594 ## MIPS Systems         (default = big endian)
595 #########################################################################
596
597 LIST_mips4kc="          \
598         incaip          \
599         qemu_mips       \
600 "
601
602 LIST_mips5kc="          \
603         purple          \
604 "
605
606 LIST_au1xx0="           \
607         dbau1000        \
608         dbau1100        \
609         dbau1500        \
610         dbau1550        \
611         dbau1550_el     \
612         gth2            \
613 "
614
615 LIST_mips="             \
616         ${LIST_mips4kc} \
617         ${LIST_mips5kc} \
618         ${LIST_au1xx0}  \
619 "
620
621 #########################################################################
622 ## MIPS Systems         (little endian)
623 #########################################################################
624
625 LIST_mips4kc_el=""
626
627 LIST_mips5kc_el=""
628
629 LIST_au1xx0_el="        \
630         dbau1550_el     \
631         pb1000          \
632 "
633
634 LIST_mips_el="                  \
635         ${LIST_mips4kc_el}      \
636         ${LIST_mips5kc_el}      \
637         ${LIST_au1xx0_el}       \
638 "
639
640 #########################################################################
641 ## i386 Systems
642 #########################################################################
643
644 LIST_I486="             \
645         sc520_cdp       \
646         sc520_spunk     \
647         sc520_spunk_rel \
648 "
649
650 LIST_x86="              \
651         ${LIST_I486}    \
652 "
653
654 #########################################################################
655 ## NIOS Systems
656 #########################################################################
657
658 LIST_nios="                     \
659         ADNPESC1                \
660         ADNPESC1_base_32        \
661         ADNPESC1_DNPEVA2_base_32\
662         DK1C20                  \
663         DK1C20_standard_32      \
664         DK1S10                  \
665         DK1S10_standard_32      \
666         DK1S10_mtx_ldk_20       \
667 "
668
669 #########################################################################
670 ## Nios-II Systems
671 #########################################################################
672
673 LIST_nios2="            \
674         EP1C20          \
675         EP1S10          \
676         EP1S40          \
677         PCI5441         \
678         PK1C20          \
679 "
680
681 #########################################################################
682 ## MicroBlaze Systems
683 #########################################################################
684
685 LIST_microblaze="       \
686         ml401           \
687         suzaku          \
688         xupv2p          \
689 "
690
691 #########################################################################
692 ## ColdFire Systems
693 #########################################################################
694
695 LIST_coldfire="                 \
696         cobra5272               \
697         EB+MCF-EV123            \
698         EB+MCF-EV123_internal   \
699         idmr                    \
700         M52277EVB               \
701         M5235EVB                \
702         M5249EVB                \
703         M5253DEMO               \
704         M5253EVBE               \
705         M5271EVB                \
706         M5272C3                 \
707         M5275EVB                \
708         M5282EVB                \
709         M5329AFEE               \
710         M5373EVB                \
711         M54451EVB               \
712         M54455EVB               \
713         M5475AFE                \
714         M5485AFE                \
715         TASREG                  \
716 "
717
718 #########################################################################
719 ## AVR32 Systems
720 #########################################################################
721
722 LIST_avr32="            \
723         atstk1002       \
724         atstk1003       \
725         atstk1004       \
726         atstk1006       \
727         atngw100        \
728         favr-32-ezkit   \
729         hammerhead      \
730         mimc200         \
731 "
732
733 #########################################################################
734 ## Blackfin Systems
735 #########################################################################
736
737 LIST_blackfin="         \
738         bf533-ezkit     \
739         bf533-stamp     \
740         bf537-stamp     \
741         bf561-ezkit     \
742 "
743
744 #########################################################################
745 ## SH Systems
746 #########################################################################
747
748 LIST_sh2="              \
749         rsk7203         \
750 "
751 LIST_sh3="              \
752         mpr2            \
753         ms7720se        \
754 "
755
756 LIST_sh4="              \
757         ms7750se        \
758         ms7722se        \
759         MigoR           \
760         r7780mp         \
761         r2dplus         \
762         sh7763rdp       \
763         sh7785lcr       \
764         ap325rxa        \
765 "
766
767 LIST_sh="               \
768         ${LIST_sh2}     \
769         ${LIST_sh3}     \
770         ${LIST_sh4}     \
771 "
772
773 #########################################################################
774 ## SPARC Systems
775 #########################################################################
776
777 LIST_sparc="gr_xc3s_1500        gr_cpci_ax2000  gr_ep2s60       grsim   grsim_leon2"
778
779 #-----------------------------------------------------------------------
780
781 #----- for now, just run PPC by default -----
782 [ $# = 0 ] && set $LIST_ppc
783
784 #-----------------------------------------------------------------------
785
786 build_target() {
787         target=$1
788
789         ${MAKE} distclean >/dev/null
790         ${MAKE} ${target}_config
791
792         ${MAKE} ${JOBS} all 2>&1 >${LOG_DIR}/$target.MAKELOG \
793                                 | tee ${LOG_DIR}/$target.ERR
794
795         ${CROSS_COMPILE}size ${BUILD_DIR}/u-boot \
796                                 | tee -a ${LOG_DIR}/$target.MAKELOG
797 }
798
799 #-----------------------------------------------------------------------
800
801
802 for arg in $@
803 do
804         case "$arg" in
805         arm|SA|ARM7|ARM9|ARM10|ARM11|at91|ixp|pxa \
806         |avr32 \
807         |blackfin \
808         |coldfire \
809         |microblaze \
810         |mips|mips_el \
811         |nios|nios2 \
812         |ppc|5xx|5xxx|512x|8xx|8220|824x|8260|83xx|85xx|86xx|4xx|7xx|74xx|TSEC \
813         |sh|sh2|sh3|sh4 \
814         |sparc \
815         |x86|I486 \
816         )
817                         for target in `eval echo '$LIST_'${arg}`
818                         do
819                                 build_target ${target}
820                         done
821                         ;;
822         *)              build_target ${arg}
823                         ;;
824         esac
825 done