diff options
Diffstat (limited to 'build.sh')
-rwxr-xr-x | build.sh | 48 |
1 files changed, 24 insertions, 24 deletions
@@ -1,44 +1,44 @@ #!/bin/sh - # -# build support for apollo3g +# kernel build script 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}" +# Usage: 'sh build.sh' to just use defaults (need to have the ELDK installed) +# 'sh build.sh CROSS_COMPILE ARCH OUTLOC' to specifiy all parameters +# +_CROSS_COMPILE=${1:-ppc_4xxFP-} +_ARCH=${2:-powerpc} +OUTLOC=${3:-_BuildOutput} +if [ ! -d ${OUTLOC} ]; then + mkdir -p "${OUTLOC}" 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 +make O=${OUTLOC} CROSS_COMPILE=${_CROSS_COMPILE} ARCH=${_ARCH} 44x/apollo_3G_nas_defconfig +make O=${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 +make O=${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 "=========== Copying images to directory $(pwd) ===============" +cp -v ${OUTLOC}/arch/powerpc/boot/uImage . +cp -v ${OUTLOC}/arch/powerpc/boot/apollo3g.dtb . +ls -ll *.dtb uImage + +# We don't use the combined image +#echo +#echo =========== Combining images =============== +#dd if=/dev/zero of=apollo3g_boot.img bs=1 count=5M +#dd if=${OUTLOC}/arch/powerpc/boot/uImage of=apollo3g_boot.img conv=notrunc bs=1 +#dd if=${OUTLOC}/arch/powerpc/boot/apollo3g.dtb of=apollo3g_boot.img conv=notrunc bs=1 seek=4M -echo -ls -ll apollo3g_boot.img # -# beech ? +# original beech script... # - #echo =========== Building Linux =============== #make distclean #make 44x/beech_nas_optimized_defconfig |