summaryrefslogtreecommitdiff
path: root/packaging
diff options
context:
space:
mode:
authorWilliam Douglas <william.douglas@intel.com>2012-08-21 15:39:53 -0700
committerWilliam Douglas <william.douglas@intel.com>2012-08-23 12:26:13 -0700
commitb82d2ee0f31f5a96b21accc4519ad262d0b54fc5 (patch)
tree9050a6530d8fa20a8687f2afb04fe569e7a96f6b /packaging
parentd87c0a3e421f37c8717af74d0a7d8a74b5413566 (diff)
downloadrpm-b82d2ee0f31f5a96b21accc4519ad262d0b54fc5.tar.gz
rpm-b82d2ee0f31f5a96b21accc4519ad262d0b54fc5.tar.bz2
rpm-b82d2ee0f31f5a96b21accc4519ad262d0b54fc5.zip
Reapply the elfutils stripping change but check if the file is a kernel module and if it is, don't try to keep function symbols for minimal backtraces. Otherwise run eu-strip to keep function symbols for shared libraries and executable binaries. Signed-off-by: William Douglas <william.douglas@intel.com>
Diffstat (limited to 'packaging')
-rw-r--r--packaging/eu-strip.patch22
-rw-r--r--packaging/rpm.changes3
-rw-r--r--packaging/rpm.spec2
3 files changed, 19 insertions, 8 deletions
diff --git a/packaging/eu-strip.patch b/packaging/eu-strip.patch
index 7b535a1..bacef74 100644
--- a/packaging/eu-strip.patch
+++ b/packaging/eu-strip.patch
@@ -1,8 +1,8 @@
Index: rpm-4.9.1/scripts/find-debuginfo.sh
===================================================================
---- rpm-4.9.1.orig/scripts/find-debuginfo.sh 2012-08-02 14:00:14.103432963 -0700
-+++ rpm-4.9.1/scripts/find-debuginfo.sh 2012-08-02 14:38:44.723358399 -0700
-@@ -95,13 +95,9 @@
+--- rpm-4.9.1.orig/scripts/find-debuginfo.sh
++++ rpm-4.9.1/scripts/find-debuginfo.sh
+@@ -95,13 +95,18 @@ debugdir="${RPM_BUILD_ROOT}/usr/lib/debu
strip_to_debug()
{
@@ -11,13 +11,21 @@ Index: rpm-4.9.1/scripts/find-debuginfo.sh
$strip_r && r=--reloc-debug-sections
- $strip_g && case "$(file -bi "$2")" in
- application/x-sharedlib*) g=-g ;;
-- esac
++ case $2 in
++ *.ko)
++ # don't attempt to create a minimal backtrace binary for
++ # kernel modules as this just causes the stripping process
++ # to be skipped entirely
++ eu-strip --remove-comment $r -f "$1" "$2" || exit
++ ;;
++ *)
++ eu-strip --remove-comment -g -f "$1" "$2" || exit
+ esac
- eu-strip --remove-comment $r $g -f "$1" "$2" || exit
-+ eu-strip --remove-comment $r -g -f "$1" "$2" || exit
chmod 444 "$1" || exit
}
-@@ -229,8 +225,6 @@
+@@ -229,8 +234,6 @@ while read nlinks inum f; do
fi
echo "extracting debug info from $f"
@@ -26,7 +34,7 @@ Index: rpm-4.9.1/scripts/find-debuginfo.sh
id=$($(DEBUGEDIT=$(which debugedit 2>/dev/null); \
echo ${DEBUGEDIT:-/usr/lib/rpm/debugedit}) -b "$RPM_BUILD_DIR" \
-d /usr/src/debug -i -l "$SOURCEFILE" "$f") || exit
-@@ -250,25 +244,13 @@
+@@ -250,25 +253,13 @@ while read nlinks inum f; do
esac
mkdir -p "${debugdn}"
diff --git a/packaging/rpm.changes b/packaging/rpm.changes
index 5692d17..a192645 100644
--- a/packaging/rpm.changes
+++ b/packaging/rpm.changes
@@ -1,3 +1,6 @@
+* Tue Aug 21 2012 William Douglas <william.douglas@intel.com> submit/trunk/2012-08-08.064212@5befd2c
+- Fix stripping for kernel modules.
+
* Tue Aug 21 2012 William Douglas <william.douglas@intel.com> submit/trunk/2012-08-08.064212@aa8ef92
- Revert 88da3b2439b41193f3d964db7d4a7f0e8321c8f1
diff --git a/packaging/rpm.spec b/packaging/rpm.spec
index a9a0c8f..cebe019 100644
--- a/packaging/rpm.spec
+++ b/packaging/rpm.spec
@@ -181,7 +181,7 @@ rm -f rpmdb/db.h
%patch86 -p1
%patch87 -p1 -b .msm
%patch90 -p1
-#%patch100 -p1
+%patch100 -p1
rm -f m4/libtool.m4