diff options
author | rene <rene@FreeBSD.org> | 2013-11-08 17:44:24 +0800 |
---|---|---|
committer | rene <rene@FreeBSD.org> | 2013-11-08 17:44:24 +0800 |
commit | e8948e9d1bcbaa544f76ea1982db00bfb65524cf (patch) | |
tree | ef56ecb21b04962f8e28ccefa8605b9cfd69e2d8 /Mk/Uses | |
parent | 4b0892fb6455e762e4241175d5b2e505bf0230bf (diff) | |
download | freebsd-ports-gnome-e8948e9d1bcbaa544f76ea1982db00bfb65524cf.tar.gz freebsd-ports-gnome-e8948e9d1bcbaa544f76ea1982db00bfb65524cf.tar.zst freebsd-ports-gnome-e8948e9d1bcbaa544f76ea1982db00bfb65524cf.zip |
Change KMODDDIR to /boot/modules if it is set to /boot/kernel
This allows upgrading a kernel without breaking any installed kernel ports
because during the upgrade /boot/kernel is renamed to /boot/kernel.old ,
resulting in moved files.
While /boot/modules is the default, it might be overridden by bsd.own.mk to
/boot/kernel before kmod is included, so setting MODULES_WITH_WORLD has no
effect.
Diffstat (limited to 'Mk/Uses')
-rw-r--r-- | Mk/Uses/kmod.mk | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Mk/Uses/kmod.mk b/Mk/Uses/kmod.mk index bb0cc92d2e6e..372551a6acdb 100644 --- a/Mk/Uses/kmod.mk +++ b/Mk/Uses/kmod.mk @@ -23,6 +23,9 @@ CATEGORIES+= kld SSP_UNSAFE= kernel module does not support SSP +.if ${KMODDIR} == "/boot/kernel" +KMODDIR= /boot/modules +.endif KMODDIR?= /boot/modules PLIST_SUB+= KMODDIR="${KMODDIR:C,^/,,}" MAKE_ENV+= KMODDIR="${KMODDIR}" SYSDIR="${SRC_BASE}/sys" |