From b2bdc113d8d42e9d69ec2af6bc0360508a109a39 Mon Sep 17 00:00:00 2001 From: Johnny Hughes Date: Nov 01 2021 15:19:04 +0000 Subject: Build on armhfp --- diff --git a/SOURCES/binutils-armhfp-fix.patch b/SOURCES/binutils-armhfp-fix.patch new file mode 100644 index 0000000..3a55d8c --- /dev/null +++ b/SOURCES/binutils-armhfp-fix.patch @@ -0,0 +1,31 @@ +diff -Naurp a/bfd/elf.c b/bfd/elf.c +--- a/bfd/elf.c 2020-03-18 00:45:06.450236795 +0000 ++++ b/bfd/elf.c 2020-03-18 01:10:58.319409778 +0000 +@@ -11110,12 +11110,7 @@ _bfd_elf_slurp_secondary_reloc_section ( + bfd_vma (*r_sym) (bfd_vma); + + +-#ifdef BFD64 +- if (bfd_arch_bits_per_address (abfd) != 32) +- r_sym = elf64_r_sym; +- else +-#endif +- r_sym = elf32_r_sym; ++ r_sym = elf32_r_sym; + + /* Discover if there are any secondary reloc sections + associated with SEC. */ +@@ -11297,12 +11292,7 @@ _bfd_elf_write_secondary_reloc_section ( + asection * relsec; + bfd_vma (*r_info) (bfd_vma, bfd_vma); + +-#ifdef BFD64 +- if (bfd_arch_bits_per_address (abfd) != 32) +- r_info = elf64_r_info; +- else +-#endif +- r_info = elf32_r_info; ++ r_info = elf32_r_info; + + if (sec == NULL) + return FALSE; diff --git a/SPECS/binutils.spec b/SPECS/binutils.spec index 3f7ae0f..d65a9ca 100644 --- a/SPECS/binutils.spec +++ b/SPECS/binutils.spec @@ -401,6 +401,8 @@ Patch998: binutils-2.27-suppress-R_X86_64_GOTPCRELX.patch # Lifetime: Delete in NEXT release. Patch999: binutils-SUPPRESS-PPC-TLBIE-CHECK.patch +#CentOS armhfp +Patch9999: binutils-armhfp-fix.patch #--------------------------------------------------------------------------------- Provides: bundled(libiberty) @@ -590,6 +592,9 @@ using libelf instead of BFD. %patch998 -p1 %patch999 -p1 +%ifarch %{arm} +%patch9999 -p1 +%endif # We cannot run autotools as there is an exact requirement of autoconf-2.59. # On ppc64 and aarch64, we might use 64KiB pages