]> err.no Git - linux-2.6/commitdiff
kbuild: modules_install for external modules must not remove existing modules
authorAndreas Gruenbacher <agruen@suse.de>
Wed, 5 Apr 2006 21:33:50 +0000 (23:33 +0200)
committerSam Ravnborg <sam@mars.ravnborg.org>
Thu, 6 Apr 2006 06:42:17 +0000 (08:42 +0200)
When installing external modules with `make modules_install', the
first thing that happens is a rm -rf of the target directory. This
works only once, and breaks when installing more than one (set of)
external module(s).
With following fix we have the functionality:
- for a in-kernel modules_install the $(MODLIB)/kernel directory will be
  deleted before module installation
- for external modules the existing modules will be left as is assuming
  one may be building and installign several external modules

Signed-off-by: Andreas Gruenbacher <agruen@suse.de>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Makefile

index c380f5891f4fd6c19eb098b0ad5bc81205e69c35..fc8e08c419f09e81252f3aa41cb7f47524c0af60 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1112,7 +1112,6 @@ modules_install: _emodinst_ _emodinst_post
 install-dir := $(if $(INSTALL_MOD_DIR),$(INSTALL_MOD_DIR),extra)
 PHONY += _emodinst_
 _emodinst_:
-       $(Q)rm -rf $(MODLIB)/$(install-dir)
        $(Q)mkdir -p $(MODLIB)/$(install-dir)
        $(Q)$(MAKE) -rR -f $(srctree)/scripts/Makefile.modinst