[kernel] r16153 - dists/trunk/linux-2.6/debian

Ben Hutchings benh at alioth.debian.org
Wed Aug 18 01:48:22 UTC 2010


Author: benh
Date: Wed Aug 18 01:48:19 2010
New Revision: 16153

Log:
Add .gnu_debuglink information into kernel modules (Closes: #555549)

From: Ritesh Raj Sarraf

Add .gnu_debuglink information into kernel modules to point to the
correct DWARF enabled kernel module. This is needed by SystemTap to
instrument a kernel module.

Modified:
   dists/trunk/linux-2.6/debian/changelog
   dists/trunk/linux-2.6/debian/rules.real

Modified: dists/trunk/linux-2.6/debian/changelog
==============================================================================
--- dists/trunk/linux-2.6/debian/changelog	Tue Aug 17 20:37:46 2010	(r16152)
+++ dists/trunk/linux-2.6/debian/changelog	Wed Aug 18 01:48:19 2010	(r16153)
@@ -1,3 +1,10 @@
+linux-2.6 (2.6.35-1~experimental.3) UNRELEASED; urgency=low
+
+  [ Ritesh Raj Sarraf ]
+  * Add .gnu_debuglink information into kernel modules (Closes: #555549)
+
+ -- Ben Hutchings <ben at decadent.org.uk>  Wed, 18 Aug 2010 02:45:21 +0100
+
 linux-2.6 (2.6.35-1~experimental.2) experimental; urgency=low
 
   * images: Nuke modules.devname on removal. (closes: #590607)

Modified: dists/trunk/linux-2.6/debian/rules.real
==============================================================================
--- dists/trunk/linux-2.6/debian/rules.real	Tue Aug 17 20:37:46 2010	(r16152)
+++ dists/trunk/linux-2.6/debian/rules.real	Wed Aug 18 01:48:19 2010	(r16153)
@@ -345,6 +345,11 @@
 	  DIR='$(DIR)' PACKAGE_DIR='$(PACKAGE_DIR)' INSTALL_DIR='$(INSTALL_DIR)' REAL_VERSION='$(REAL_VERSION)'
 ifeq ($(MODULES),True)
 	+$(MAKE_CLEAN) -C $(DIR) modules_install INSTALL_MOD_PATH='$(CURDIR)'/$(PACKAGE_DIR) INSTALL_MOD_STRIP=1
+ifeq ($(DEBUG),True)
+	find $(PACKAGE_DIR) -name '*.ko' | sed 's|$(PACKAGE_DIR)/lib/modules/$(REAL_VERSION)/kernel/||' | while read module ; do \
+	  objcopy --add-gnu-debuglink=$(DIR)/$$module $(PACKAGE_DIR)/lib/modules/$(REAL_VERSION)/kernel/$$module; \
+	done
+endif
 	cp $(DIR)/.config $(PACKAGE_DIR)/boot/config-$(REAL_VERSION)
 	cp $(DIR)/System.map $(PACKAGE_DIR)/boot/System.map-$(REAL_VERSION)
 	rm $(PACKAGE_DIR)/lib/modules/$(REAL_VERSION)/{build,source,modules.*}



More information about the Kernel-svn-changes mailing list