aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortuxoko <[email protected]>2015-11-19 17:42:41 -0800
committerBrian Behlendorf <[email protected]>2015-12-02 14:39:12 -0800
commitb0fe1adeb1f24192c9a3358a4c9a29a34b9537fe (patch)
tree063b2f1b7a1b640dbabbc27d1c7604900055183f
parent60bd953ca4905e8720513d2d9e12932c0ea9cc83 (diff)
Prevent rm modules.* when make install
This was originally in fe0ed8f910c1e4288dc190546cfe98ecf545b547, but somehow was changed and not working anymore. And it will cause the following error: modprobe: ERROR: ../libkmod/libkmod.c:506 lookup_builtin_file() could not open builtin file '/lib/modules/4.2.0-18-generic/modules.builtin.bin' Signed-off-by: Chunwei Chen <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #4027
-rw-r--r--module/Makefile.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/module/Makefile.in b/module/Makefile.in
index e8d34c894..d4ddee2f4 100644
--- a/module/Makefile.in
+++ b/module/Makefile.in
@@ -47,7 +47,7 @@ modules_install:
KERNELRELEASE=@LINUX_VERSION@
@# Remove extraneous build products when packaging
kmoddir=$(DESTDIR)$(INSTALL_MOD_PATH)/lib/modules/@LINUX_VERSION@; \
- if [ -n $$kmoddir ]; then \
+ if [ -n "$(DESTDIR)" ]; then \
find $$kmoddir -name 'modules.*' | xargs $(RM); \
fi
sysmap=$(DESTDIR)$(INSTALL_MOD_PATH)/boot/System.map-@LINUX_VERSION@; \