#!/bin/ash -efu
#
# mki-pack
#
# This file is part of mkimage
# Copyright (C) 2007-2009  Alexey Gladkov <gladkov.alexey@gmail.com>
#
# This file is covered by the GNU General Public License,
# which should be included with mkimage as the file COPYING.
#

. "${0%/*}"/mki-sh-functions

verbose "has started executing."

type="${MKI_PACKTYPE:?pack type required}"

case "$type" in
	tarbz2)
		MKI_TAR_COMPRESS='bzip2'
		type='tar'
		;;
	boot|isoboot|isodata|yaboot|squash|tar|cpio|data) ;;
	*) type='custom' ;;
esac
exec mki-pack-$type
