- add-option-for-stripping-modules-while-installing-them.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     Add option for stripping modules while installing them

has been removed from the -mm tree.  Its filename is

     add-option-for-stripping-modules-while-installing-them.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
Subject: Add option for stripping modules while installing them
From: "Theodore Ts'o" <tytso@xxxxxxx>


Add option for stripping modules while installing them

This function adds support for stripping modules while they are being
installed.  CONFIG_DEBUG_KERNEL (which will probably become more popular as
developers use kdump) causes the size of the installed modules to grow by a
factor of 9 or so.

Some kernel package systems solve this problem by stripping the debug
information from /lib/modules after running "make modules_install", but
that may not work for people who are installing directly into /lib/modules
--- root partitions that were sized to handle 16 megs worth of modules may
not be quite so happy with 145 megs of modules, so the "make
modules_install" never succeeds.

This patch allows such users to request modules_install to strip the
modules as they are installed.

Signed-off-by: "Theodore Ts'o" <tytso@xxxxxxx>
Cc: Sam Ravnborg <sam@xxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 Documentation/kbuild/makefiles.txt |    8 ++++++++
 Makefile                           |   17 +++++++++++++++++
 scripts/Makefile.modinst           |    2 +-
 3 files changed, 26 insertions(+), 1 deletion(-)

diff -puN Documentation/kbuild/makefiles.txt~add-option-for-stripping-modules-while-installing-them Documentation/kbuild/makefiles.txt
--- a/Documentation/kbuild/makefiles.txt~add-option-for-stripping-modules-while-installing-them
+++ a/Documentation/kbuild/makefiles.txt
@@ -1123,6 +1123,14 @@ The top Makefile exports the following v
 	$(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE).  The user may
 	override this value on the command line if desired.
 
+    INSTALL_MOD_STRIP
+
+	If this variable is specified, will cause modules to be stripped
+	after they are installed.  If INSTALL_MOD_STRIP is '1', then the
+	default option --strip-debug will be used.  Otherwise,
+	INSTALL_MOD_STRIP will used as the option(s) to the strip command.
+
+
 === 8 Makefile language
 
 The kernel Makefiles are designed to run with GNU Make.  The Makefiles
diff -puN Makefile~add-option-for-stripping-modules-while-installing-them Makefile
--- a/Makefile~add-option-for-stripping-modules-while-installing-them
+++ a/Makefile
@@ -523,6 +523,23 @@ export	INSTALL_PATH ?= /boot
 MODLIB	= $(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE)
 export MODLIB
 
+#
+#  INSTALL_MOD_STRIP, if defined, will cause modules to be
+#  stripped after they are installed.  If INSTALL_MOD_STRIP is '1', then
+#  the default option --strip-debug will be used.  Otherwise,
+#  INSTALL_MOD_STRIP will used as the options to the strip command.
+
+ifdef INSTALL_MOD_STRIP
+ifeq ($(INSTALL_MOD_STRIP),1)
+mod_strip_cmd = strip --strip-debug
+else
+mod_strip_cmd = strip $(INSTALL_MOD_STRIP)
+endif # INSTALL_MOD_STRIP=1
+else
+mod_strip_cmd = true
+endif # INSTALL_MOD_STRIP
+export mod_strip_cmd
+
 
 ifeq ($(KBUILD_EXTMOD),)
 core-y		+= kernel/ mm/ fs/ ipc/ security/ crypto/ block/
diff -puN scripts/Makefile.modinst~add-option-for-stripping-modules-while-installing-them scripts/Makefile.modinst
--- a/scripts/Makefile.modinst~add-option-for-stripping-modules-while-installing-them
+++ a/scripts/Makefile.modinst
@@ -17,7 +17,7 @@ __modinst: $(modules)
 	@:
 
 quiet_cmd_modules_install = INSTALL $@
-      cmd_modules_install = mkdir -p $(2); cp $@ $(2)
+      cmd_modules_install = mkdir -p $(2); cp $@ $(2) ; $(mod_strip_cmd) $(2)/$(notdir $@)
 
 # Modules built outside the kernel source tree go into extra by default
 INSTALL_MOD_DIR ?= extra
_

Patches currently in -mm which might be from tytso@xxxxxxx are

git-kbuild.patch
cleanup-dead-code-from-ext2-mount-code.patch
fix-memory-leak-when-the-ext3s-journal-file-is-corrupted.patch
remove-inconsistent-space-before-exclamation-point-in-ext3s-mount-code.patch
remove-tty_dont_flip.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux