linux/debian/bin/sparc32-image-postproc

11 lines
428 B
Bash
Executable File

#!/bin/sh
# It is a bit cumbersome here. Since we are executed when
# the image is already installed and in place, we must
# unpack it, then strip it, then gzip it again.
image_dest="${IMAGE_TOP}/boot/vmlinuz-${version}"
image_temp="$(mktemp)"
gzip -dc "${image_dest}" > "${image_temp}"
strip -R .comment -R .note -K sun4u_init -K _end -K _start "${image_temp}"
gzip -9c "${image_temp}" > "${image_dest}"
rm -rf "${image_temp}"