From 3a98358b5a73f8a0b5415f73efc5773b26be10cb Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Mar 15 2016 10:45:16 +0000 Subject: Fix strict aliasing errors compiling with broken F24 gcc. See thread starting here: https://sourceware.org/ml/binutils/2016-03/msg00119.html Related: #1312507 --- diff --git a/binutils-2.26-bad-aliasing.patch b/binutils-2.26-bad-aliasing.patch index 2261ad4..c8f2447 100644 --- a/binutils-2.26-bad-aliasing.patch +++ b/binutils-2.26-bad-aliasing.patch @@ -40,3 +40,16 @@ diff -rup binutils-2.26.orig/bfd/libcoff-in.h binutils-2.26/bfd/libcoff-in.h /* Tdata for sections in XCOFF files. This is used by the linker. */ +--- binutils-2.26.orig/gas/config/obj-elf.h 2016-03-15 09:50:29.143059664 +0000 ++++ binutils-2.26/gas/config/obj-elf.h 2016-03-15 10:36:26.342646864 +0000 +@@ -93,8 +93,8 @@ extern void elf_begin (void); + #define LOCAL_LABEL_PREFIX '.' + #endif + +-/* should be conditional on address size! */ +-#define elf_symbol(asymbol) ((elf_symbol_type *) (&(asymbol)->the_bfd)) ++/* Should be conditional on address size! */ ++#define elf_symbol(asymbol) ((elf_symbol_type *) (asymbol)) + + #ifndef S_GET_SIZE + #define S_GET_SIZE(S) \ diff --git a/binutils.spec b/binutils.spec index 190135f..dd0ff83 100644 --- a/binutils.spec +++ b/binutils.spec @@ -20,7 +20,7 @@ Summary: A GNU collection of binary utilities Name: %{?cross}binutils%{?_with_debug:-debug} Version: 2.26 -Release: 16%{?dist} +Release: 17%{?dist} License: GPLv3+ Group: Development/Tools URL: http://sources.redhat.com/binutils @@ -522,7 +522,7 @@ exit 0 %endif # %{isnative} %changelog -* Tue Mar 15 2016 Nick Clifton 2.26-16 +* Tue Mar 15 2016 Nick Clifton 2.26-17 - Fix strict aliasing errors compiling with broken F24 gcc. See thread starting here: https://sourceware.org/ml/binutils/2016-03/msg00119.html (#1312507)