zfs-builds-mm/zfs-2.0.0-rc5/scripts/dkms.postbuild
2020-11-03 21:32:00 +01:00

24 lines
595 B
Bash
Executable file

#!/bin/sh
PROG=$0
while getopts "a:k:n:t:v:" opt; do
case $opt in
a) arch=$OPTARG ;;
k) kver=$OPTARG ;;
n) pkgname=$OPTARG ;;
t) tree=$OPTARG ;;
v) pkgver=$OPTARG ;;
esac
done
if [ -z "${arch}" ] || [ -z "${kver}" ] || [ -z "${pkgname}" ] || \
[ -z "${tree}" ] || [ -z "${pkgver}" ]; then
echo "Usage: $PROG -a <arch> -k <kver> -n <pkgname>" \
"-t <tree> -v <pkgver>"
exit 1
fi
cp "${tree}/${pkgname}/${pkgver}/build/zfs_config.h" \
"${tree}/${pkgname}/${pkgver}/build/module/Module.symvers" \
"${tree}/${pkgname}/${pkgver}/${kver}/${arch}/"