#!/bin/sh
# SPDX-License-Identifier: GPL-2.0
set -eu

version=$1
image=$2

set -- $DEB_MAINT_PARAMS

if [ "$1" = configure ]; then
  image_input=/usr/lib/modules/${version}/vmlinuz
  if [ -e "$image_input" ]; then
    cp -l "$image_input" "$image" 2>/dev/null || cp -p "$image_input" "$image"
  fi
fi
