diff --git a/debugedit-bnc1076819.diff b/debugedit-bnc1076819.diff new file mode 100644 index 0000000..771eafa --- /dev/null +++ b/debugedit-bnc1076819.diff @@ -0,0 +1,15 @@ +--- tools/debugedit.c.orig 2018-01-22 12:09:07.477955907 +0100 ++++ tools/debugedit.c 2018-01-22 12:09:22.210197759 +0100 +@@ -2154,9 +2154,9 @@ + /* Offset (pointing into the line program) moves + from old to new index including the header + size diff. */ +- r_offset += ((dso->lines.table[lndx].new_idx +- - dso->lines.table[lndx].old_idx) +- + dso->lines.table[lndx].size_diff); ++ r_offset += (ssize_t)((dso->lines.table[lndx].new_idx ++ - dso->lines.table[lndx].old_idx) ++ + dso->lines.table[lndx].size_diff); + + if (rtype == SHT_RELA) + { diff --git a/rpm.changes b/rpm.changes index 17ee250..859dbc4 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Jan 22 11:13:48 UTC 2018 - rguenther@suse.com + +- fix debugedit relocation offset computation (boo#1076819) + new patch: debugedit-bnc1076819.diff + ------------------------------------------------------------------- Fri Jan 5 13:26:50 CET 2018 - mls@suse.de diff --git a/rpm.spec b/rpm.spec index 8a85ea7..8e535f5 100644 --- a/rpm.spec +++ b/rpm.spec @@ -134,6 +134,7 @@ Patch107: hardlink.diff Patch108: debugedit-macro.diff Patch109: pythondistdeps.diff Patch110: bigarchive.diff +Patch111: debugedit-bnc1076819.diff Patch6464: auto-config-update-aarch64-ppc64le.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build # @@ -230,7 +231,7 @@ rm -f rpmdb/db.h %patch -P 85 %patch -P 93 -P 94 -P 99 %patch -P 100 -P 102 -P 103 -P 104 -P 105 -P 106 -P 107 -P 108 -%patch -P 109 -P 110 +%patch -P 109 -P 110 -P 111 %ifarch aarch64 ppc64le %patch6464 @@ -255,7 +256,7 @@ rm -f m4/libtool.m4 rm -f m4/lt*.m4 %build -export CFLAGS="%{optflags} -ffunction-sections" +export CFLAGS="-g -O0" export LDFLAGS="-Wl,-Bsymbolic-functions -ffunction-sections" %ifarch alpha export CFLAGS="-g -O0 -fno-strict-aliasing -ffunction-sections"