Newer
Older
Import / research / other / WakeXBMC / Router / DGN2000_V1.1.1_src / build.sh
@John Ryland John Ryland on 29 Dec 2020 780 bytes Revert "remove not needed files"
#!/bin/sh

if [ "$1" = "" ] || [ "$2" = "" ] || [ "$3" = "" ]; then
	echo "Usage:" $0 "orignal_image fs_dir new_image"
	exit
fi

echo
echo "Original Image:" $1
echo "Your Filesystem:" $2
echo "New Image:" $3
echo
echo "Press 'y' to continue"

read yn

if [ "$yn" = "y" ]; then
#	tools/mkcramfs $2 fs.bin
#	make -C ./tools/tool/ clean > /dev/null 2>&1
#	make -C ./tools/tool/mksquashfs > /dev/null 2>&1
	tools/mksquashfs $2 fs.bin -noappend -be -lzma -no-fragments -noI -b 8192
	tools/bcmImageBuilder --output bcm963xx_fs_kernel --chip 6348 --board "96348W3" --blocksize 64 --cfefile tools/cfe6348.bin --rootfsfile fs.bin  --kernelfile tools/vmlinux.lz
	tools/makeImage $3 $1 bcm963xx_fs_kernel
	rm -rf fs.bin bcm963xx_fs_kernel
       	echo $3 "Created!"	
else
	echo "EXIT!"
fi