diff options
author | Brian Gerst <bgerst@didntduck.org> | 2004-07-10 19:29:48 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2004-07-10 19:29:48 -0700 |
commit | 5cfce8960087fb21821356b81972d580baea3a36 (patch) | |
tree | a4ea519d78b4ee02d2552bc3ccadc748c223208b /scripts | |
parent | 43610b32a9f5179be7511a44392850896d5aa3f3 (diff) | |
download | history-5cfce8960087fb21821356b81972d580baea3a36.tar.gz |
[PATCH] kbuild: clean up module install rules
Consolidate rules for installing internal and external modules.
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/Makefile.modinst | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst index 5431acb148e052..cef0b1142f2e01 100644 --- a/scripts/Makefile.modinst +++ b/scripts/Makefile.modinst @@ -16,20 +16,10 @@ modules := $(patsubst %.o,%.ko,$(wildcard $(__modules:.ko=.o))) __modinst: $(modules) @: -# Modules built within the kernel tree - quiet_cmd_modules_install = INSTALL $@ - cmd_modules_install = mkdir -p $(MODLIB)/kernel/$(@D); \ - cp $@ $(MODLIB)/kernel/$(@D) - -$(filter-out ../% /%,$(modules)): - $(call cmd,modules_install) - -# Modules built outside just go into extra + cmd_modules_install = mkdir -p $(2); cp $@ $(2) -quiet_cmd_modules_install_extra = INSTALL $(obj-m:.o=.ko) - cmd_modules_install_extra = mkdir -p $(MODLIB)/extra; \ - cp $@ $(MODLIB)/extra +modinst_dir = $(MODLIB)/$(if $(filter ../% /%,$@),extra/,kernel/$(@D)) -$(filter ../% /%,$(modules)): - $(call cmd,modules_install_extra) +$(modules): + $(call cmd,modules_install,$(modinst_dir)) |