summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--elfutils-0.155-alt-elflint-bss.patch (renamed from elfutils-0.147-alt-bss.patch)2
-rw-r--r--elfutils-0.155-alt-elflint-st_value.patch38
-rw-r--r--elfutils.spec12
3 files changed, 48 insertions, 4 deletions
diff --git a/elfutils-0.147-alt-bss.patch b/elfutils-0.155-alt-elflint-bss.patch
index bd0866cb..78f97295 100644
--- a/elfutils-0.147-alt-bss.patch
+++ b/elfutils-0.155-alt-elflint-bss.patch
@@ -2,7 +2,7 @@ http://lists.altlinux.org/pipermail/devel/2009-December/178481.html
--- elfutils/src/elflint.c
+++ elfutils/src/elflint.c
-@@ -3816,7 +3816,10 @@ section [%2zu] '%s' has not type NOBITS
+@@ -3750,7 +3750,10 @@ section [%2zu] '%s' has not type NOBITS but is not read from the file in segment
section [%2zu] '%s' is executable in nonexecutable segment %d\n"),
cnt, section_name (ebl, cnt), pcnt);
}
diff --git a/elfutils-0.155-alt-elflint-st_value.patch b/elfutils-0.155-alt-elflint-st_value.patch
new file mode 100644
index 00000000..e1bbcb2b
--- /dev/null
+++ b/elfutils-0.155-alt-elflint-st_value.patch
@@ -0,0 +1,38 @@
+--- elfutils/src/elflint.c
++++ elfutils/src/elflint.c
+@@ -763,7 +763,8 @@ section [%2d] '%s': symbol %zu: function in COMMON section is nonsense\n"),
+ if (! ebl_check_special_symbol (ebl, ehdr, sym, name,
+ destshdr))
+ {
+- if (sym->st_value - sh_addr > destshdr->sh_size)
++ if (sym->st_value < sh_addr
++ || sym->st_value - sh_addr > destshdr->sh_size)
+ {
+ /* GNU ld has severe bugs. When it decides to remove
+ empty sections it leaves symbols referencing them
+@@ -775,16 +776,20 @@ section [%2d] '%s': symbol %zu: function in COMMON section is nonsense\n"),
+ && strcmp (name, "__init_array_start") != 0
+ && strcmp (name, "__init_array_end") != 0
+ && strcmp (name, "__fini_array_start") != 0
+- && strcmp (name, "__fini_array_end") != 0))
++ && strcmp (name, "__fini_array_end") != 0
++ && strcmp (name, "__bss_start") != 0))
+ ERROR (gettext ("\
+-section [%2d] '%s': symbol %zu: st_value out of bounds\n"),
+- idx, section_name (ebl, idx), cnt);
++section [%2d] '%s': symbol [%zu] '%s': st_value[%lx] out of bounds [%lx+%lx]\n"),
++ idx, section_name (ebl, idx), cnt, name,
++ (unsigned long) sym->st_value,
++ (unsigned long) sh_addr,
++ (unsigned long) destshdr->sh_size);
+ }
+ else if ((sym->st_value - sh_addr
+ + sym->st_size) > destshdr->sh_size)
+ ERROR (gettext ("\
+-section [%2d] '%s': symbol %zu does not fit completely in referenced section [%2d] '%s'\n"),
+- idx, section_name (ebl, idx), cnt,
++section [%2d] '%s': symbol [%zu] '%s' does not fit completely in referenced section [%2d] '%s'\n"),
++ idx, section_name (ebl, idx), cnt, name,
+ (int) xndx, section_name (ebl, xndx));
+ }
+ }
diff --git a/elfutils.spec b/elfutils.spec
index 741bf72d..9fdd4066 100644
--- a/elfutils.spec
+++ b/elfutils.spec
@@ -15,7 +15,8 @@ Patch2: elfutils-0.155-rh-robustify.patch
Patch3: elfutils-0.155-rh-binutils-pr-ld-13621.patch
Patch4: elfutils-0.147-alt-findtextrel.patch
Patch5: elfutils-0.147-alt-osabi.patch
-Patch6: elfutils-0.147-alt-bss.patch
+Patch6: elfutils-0.155-alt-elflint-bss.patch
+Patch7: elfutils-0.155-alt-elflint-st_value.patch
Requires: libelf = %version-%release
@@ -92,6 +93,7 @@ object file format, so you can see the different sections of an ELF file.
%patch4 -p1
%patch5 -p1
%patch6 -p1
+%patch7 -p1
# Remove flex-generated files.
rm libcpu/i386_lex.c src/ldlex.c
@@ -119,7 +121,8 @@ cd %buildtarget
%find_lang %name
%check
-LD_LIBRARY_PATH=%buildroot%_libdir make -k check -C %buildtarget
+export PATH="%buildroot%_bindir:$PATH" LD_LIBRARY_PATH=%buildroot%_libdir
+%make_build -k check -C %buildtarget
%files
%_bindir/eu-addr2line
@@ -153,7 +156,7 @@ LD_LIBRARY_PATH=%buildroot%_libdir make -k check -C %buildtarget
%exclude %_libdir/libebl.a
%files -n libelf -f %name.lang
-%doc AUTHORS CONTRIBUTING EXCEPTION NEWS.bz2 NOTES README THANKS
+%doc AUTHORS CONTRIBUTING NEWS.bz2 NOTES README THANKS
%_libdir/libelf-*.so
%_libdir/libelf*.so.*
@@ -169,6 +172,9 @@ LD_LIBRARY_PATH=%buildroot%_libdir make -k check -C %buildtarget
%endif
%changelog
+* Thu Aug 30 2012 Dmitry V. Levin <ldv@altlinux.org> 0.155-alt1
+- Updated to 0.155.
+
* Sun Mar 25 2012 Dmitry V. Levin <ldv@altlinux.org> 0.153-alt1
- Updated to 0.153.