Compile librem-ec for user chosen kernel

This commit is contained in:
projectmoon 2021-07-12 21:56:04 +00:00
parent 4bcaa5c9f5
commit 441359e5e7
1 changed files with 9 additions and 0 deletions

View File

@ -17,6 +17,15 @@ S="${WORKDIR}/librem-ec-acpi-dkms-v${PV}/"
MODULE_NAMES="librem_ec_acpi(librem:${S}:${S})" MODULE_NAMES="librem_ec_acpi(librem:${S}:${S})"
BUILD_TARGETS="clean all" BUILD_TARGETS="clean all"
src_prepare() {
default
# Makefile hardcoded to point at running kernel
# but we want the user-chosen kernel.
linux-info_get_any_version
sed -i "s/\$(shell uname -r)/${KV_FULL}/" Makefile \
|| die "could not set kernel version in makefile"
}
pkg_setup() { pkg_setup() {
linux-mod_pkg_setup linux-mod_pkg_setup
BUILD_PARAMS="KERNELDIR=${KV_DIR}" BUILD_PARAMS="KERNELDIR=${KV_DIR}"