| # fitImage kernel compression algorithm |
| FIT_KERNEL_COMP_ALG ?= "gzip" |
| FIT_KERNEL_COMP_ALG_EXTENSION ?= ".gz" |
| if [ -e arch/${ARCH}/boot/compressed/vmlinux ]; then |
| vmlinux_path="arch/${ARCH}/boot/compressed/vmlinux" |
| elif [ -e arch/${ARCH}/boot/vmlinuz.bin ]; then |
| cp -l arch/${ARCH}/boot/vmlinuz.bin linux.bin |
| linux_suffix="${FIT_KERNEL_COMP_ALG_EXTENSION}" |
| linux_comp="${FIT_KERNEL_COMP_ALG}" |
| [ -n "${vmlinux_path}" ] && ${OBJCOPY} -O binary -R .note -R .comment -S "${vmlinux_path}" linux.bin |
| if [ "${linux_comp}" != "none" ] ; then |
| mv -f "linux.bin${linux_suffix}" linux.bin |