Skip to content

Commit 2db6246

Browse files
author
hyphop
committed
legacy uboot for all vims
1 parent 6cce6c0 commit 2db6246

File tree

5 files changed

+80
-12
lines changed

5 files changed

+80
-12
lines changed

patches/vim3

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
vim1

patches/vim3l

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
vim1

scripts/VIM3.inc

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#!/bin/sh
2+
13
# UBOOT_DIR FIP FIP_BUILD
24

35
CMD(){
@@ -42,6 +44,8 @@ uboot_custom_postprocess() {
4244

4345
CUR_SOC=${CONFIG_SYS_SOC}
4446

47+
echo "[i] CUR_SOC $CUR_SOC"
48+
4549
if [ "y" == "${CONFIG_NEED_BL32}" ]; then
4650
BLX_NEEDFUL[3]="true"
4751
fi

scripts/make_uboot_vim3

+13-12
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,18 @@
22

33
## hyphop ##
44

5-
#= build wrapper for mailline uboot vim3
5+
#= build wrapper for mailline uboot
66

77
#/ menuconfig
88
# savedefconfig
99
# -j14
1010

1111
set -e
1212

13-
P="$(dirname $0)"
13+
P=$(dirname $0)
1414

15-
export PATH=$(realpath $P/../../fenix/build/toolchains/gcc-linaro-aarch64-none-elf/bin):$PATH
16-
export PATH=$(realpath $P/../../fenix/build/toolchains/gcc-arm-none-eabi/bin):$PATH
15+
export PATH=$PWD/../../fenix/build/toolchains/gcc-linaro-aarch64-none-elf/bin:$PATH
16+
export PATH=$PWD/../../fenix/build/toolchains/gcc-arm-none-eabi/bin:$PATH
1717

1818
export ARCH=arm64
1919
export CROSS_COMPILE=aarch64-none-elf-
@@ -23,27 +23,28 @@ CMD(){
2323
"$@"
2424
}
2525

26-
for DIR in /tmp/u-boot.vim3; do
26+
for DIR in ../../u-boot-vim3; do
2727
[ -d "$DIR" ] && break
2828
done
2929

3030
[ -f $DIR/build/.config ] || {
31-
# CMD make -C "$DIR" kvim2_defconfig
32-
echo "[i] def config">&2
33-
31+
CMD make -C "$DIR" kvim3_defconfig
3432
}
3533

3634
CMD make -C "$DIR" "$@"
3735

38-
F=/tmp/uboot-legacy-aml
36+
#exit 0
37+
3938
F=/tmp/uboot_vim3
4039

41-
[ -d $F ] && rm -rd $F
40+
[ -d $F ] && rm -rf $F
4241
[ -d $F ] || mkdir $F
4342

44-
. $P/VIM3.inc
43+
. $P/VIM2.inc
44+
45+
echo "[i] post process">&2
4546

46-
uboot_custom_postprocess "$DIR" "$(realpath ../../fip)" "$F"
47+
uboot_custom_postprocess "$(realpath $DIR)" "$(realpath ../../fip)" "$F"
4748

4849
cd $F
4950

scripts/make_uboot_vim3l

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
#!/bin/bash
2+
3+
## hyphop ##
4+
5+
#= build wrapper for mailline uboot
6+
7+
#/ menuconfig
8+
# savedefconfig
9+
# -j14
10+
11+
set -e
12+
13+
P=$(dirname $0)
14+
15+
export PATH=$PWD/../../fenix/build/toolchains/gcc-linaro-aarch64-none-elf/bin:$PATH
16+
export PATH=$PWD/../../fenix/build/toolchains/gcc-arm-none-eabi/bin:$PATH
17+
18+
export ARCH=arm64
19+
export CROSS_COMPILE=aarch64-none-elf-
20+
21+
CMD(){
22+
echo "[#] $@">&2
23+
"$@"
24+
}
25+
26+
for DIR in ../../u-boot-vim3l; do
27+
[ -d "$DIR" ] && break
28+
done
29+
30+
[ -f $DIR/build/.config ] || {
31+
CMD make -C "$DIR" kvim3l_defconfig
32+
}
33+
34+
CMD make -C "$DIR" "$@"
35+
36+
#exit 0
37+
38+
F=/tmp/uboot_vim3l
39+
40+
[ -d $F ] && rm -rf $F
41+
[ -d $F ] || mkdir $F
42+
43+
. $P/VIM2.inc
44+
45+
echo "[i] post process">&2
46+
47+
uboot_custom_postprocess "$(realpath $DIR)" "$(realpath ../../fip)" "$F"
48+
49+
cd $F
50+
51+
mv u-boot.bin u-boot.spi.bin
52+
mv u-boot.bin.sd.bin u-boot.sd.bin
53+
rm bl* a* *.tpl *.bl2
54+
rm fip.bin *_new.bin *encrypt*
55+
56+
for b in *.bin; do
57+
gzip -c $b > $b.gz
58+
done
59+
60+
echo "[i] output: $F">&2
61+
ls -l1 $F

0 commit comments

Comments
 (0)