diff options
author | David Barksdale <amatus@amatus.name> | 2014-08-13 16:14:13 -0500 |
---|---|---|
committer | David Barksdale <amatus@amatus.name> | 2014-08-13 16:14:13 -0500 |
commit | ace6c6d243016e272050787c14e27a83ecd94a25 (patch) | |
tree | c837edb1ca98b2552fbc7edba47aeb63f98ca1f0 /build.sh | |
parent | 1b6e1688bd215cd7c9cb75650fa815a1ec6567e1 (diff) |
gpl-source-mybooklive-010002-update.zipgpl-source-mybooklive-010103-update.zipgpl-source-mybooklive-010002-update.zip
Diffstat (limited to 'build.sh')
-rwxr-xr-x | build.sh | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/build.sh b/build.sh new file mode 100755 index 00000000000..6497ca2b509 --- /dev/null +++ b/build.sh @@ -0,0 +1,54 @@ +#!/bin/sh + +# +# build support for apollo3g +# +local _CROSS_COMPILE=${1:-"ppc_4xxFP-"} +local _ARCH=${2:-"powerpc"} + +if [ ! -z ${3} ]; then + if [ ! -d ${3} ]; then + mkdir -p "${3}" + fi + OUTPREFIX="${3}/" + OUTLOC="O=${3}" +fi + +#echo "CROSS_COMPILE=${_CROSS_COMPILE} ARCH=${_ARCH} OUTLOC=${OUTLOC}" + +echo =========== Building Linux =============== +make distclean +make mrproper +make ${OUTLOC} CROSS_COMPILE=${_CROSS_COMPILE} ARCH=${_ARCH} 44x/apollo_3G_nas_defconfig +make ${OUTLOC} CROSS_COMPILE=${_CROSS_COMPILE} ARCH=${_ARCH} -j 5 uImage + +echo +echo =========== Building device tree =========== +make ${OUTLOC} CROSS_COMPILE=${_CROSS_COMPILE} ARCH=${_ARCH} -j 5 apollo3g.dtb + +echo +echo =========== Combining images =============== +dd if=/dev/zero of=apollo3g_boot.img bs=1 count=5M +dd if=${OUTPREFIX}arch/powerpc/boot/uImage of=apollo3g_boot.img conv=notrunc bs=1 +dd if=${OUTPREFIX}arch/powerpc/boot/apollo3g.dtb of=apollo3g_boot.img conv=notrunc bs=1 seek=4M + +echo +ls -ll apollo3g_boot.img + +# +# beech ? +# + +#echo =========== Building Linux =============== +#make distclean +#make 44x/beech_nas_optimized_defconfig +#make uImage +# +#echo =========== Building device tree =========== +#make beech.dtb +# +#echo =========== Combining images =============== +#dd if=/dev/zero of=beech_boot.img bs=1 count=5M +#dd if=arch/powerpc/boot/uImage of=beech_boot.img conv=notrunc bs=1 +#dd if=arch/powerpc/boot/beech.dtb of=beech_boot.img conv=notrunc bs=1 seek=4M + |