.. | .. |
---|
1 | 1 | #!/bin/bash |
---|
2 | 2 | |
---|
3 | | -if [ x"$1" == "xu" ] ;then |
---|
4 | | - cd longan/brandy/brandy-2.0 |
---|
5 | | - ./build.sh -p sun50iw10p1 |
---|
6 | | - cd - |
---|
| 3 | +if [ x"$1" == "xuboot" ] || [ x"$1" == "xu" ] || [ x"$1" == "x" ] ;then |
---|
| 4 | + echo "Start build uboot" |
---|
| 5 | + cd longan/brandy/brandy-2.0 && ./build.sh -p sun50iw10p1 && cd - |
---|
| 6 | + if [ $? -eq 0 ]; then |
---|
| 7 | + echo "Build uboot ok!" |
---|
| 8 | + else |
---|
| 9 | + echo "Build uboot failed!" |
---|
| 10 | + exit 1 |
---|
| 11 | + fi |
---|
7 | 12 | fi |
---|
8 | 13 | |
---|
9 | | -if [ x"$1" == "xk" ] ;then |
---|
10 | | - cd longan && ./build.sh && cd - |
---|
11 | | - if [ $? -eq 0 ]; then |
---|
12 | | - echo "Build kernel ok!" |
---|
13 | | - else |
---|
14 | | - echo "Build kernel failed!" |
---|
15 | | - exit 1 |
---|
16 | | - fi |
---|
17 | | - |
---|
18 | | - cd android |
---|
19 | | - . ./build/envsetup.sh |
---|
20 | | - lunch ceres_c3-userdebug |
---|
21 | | - extract-bsp && pack |
---|
22 | | - cd - |
---|
| 14 | +if [ x"$1" == "xkernel" ] || [ x"$1" == "xk" ] || [ x"$1" == "x" ] ;then |
---|
| 15 | + echo "Start build kernel" |
---|
| 16 | + cd longan && ./build.sh autoconfig -o android -i a133 -b c3 && ./build.sh && cd - |
---|
| 17 | + if [ $? -eq 0 ]; then |
---|
| 18 | + echo "Build kernel ok!" |
---|
| 19 | + else |
---|
| 20 | + echo "Build kernel failed!" |
---|
| 21 | + exit 1 |
---|
| 22 | + fi |
---|
23 | 23 | fi |
---|
24 | 24 | |
---|
25 | | -if [ x"$1" == "xa" ] ;then |
---|
26 | | - cd android |
---|
27 | | - . ./build/envsetup.sh |
---|
28 | | - lunch ceres_c3-userdebug |
---|
29 | | - extract-bsp |
---|
| 25 | +# android envsetup |
---|
| 26 | +cd android |
---|
| 27 | +. ./build/envsetup.sh |
---|
| 28 | +lunch ceres_c3-userdebug |
---|
| 29 | +extract-bsp |
---|
| 30 | +cd - |
---|
| 31 | + |
---|
| 32 | +if [ x"$1" == "xandroid" ] || [ x"$1" == "xa" ] || [ x"$1" == "x" ] ;then |
---|
| 33 | + echo "Start build Android" |
---|
| 34 | + cd android |
---|
30 | 35 | make installclean |
---|
31 | | - make BUILD_NUMBER=ido-a133 -j32 && pack |
---|
32 | | -# make -j10 && pack -v |
---|
33 | | - cd - |
---|
| 36 | + make BUILD_NUMBER=ido-a133 -j32 |
---|
| 37 | + cd - |
---|
34 | 38 | fi |
---|
35 | 39 | |
---|
36 | | -if [ x"$1" == "xp" ] ;then |
---|
37 | | - cd android |
---|
38 | | - . ./build/envsetup.sh |
---|
39 | | - lunch ceres_c3-userdebug |
---|
40 | | - extract-bsp && pack |
---|
41 | | - cd - |
---|
42 | | -fi |
---|
| 40 | +# pack image |
---|
| 41 | +echo "Start pack image" |
---|
| 42 | +cd android |
---|
| 43 | +pack |
---|
| 44 | +cd - |
---|
| 45 | + |
---|
43 | 46 | |
---|