diff --git a/gdb-gcc9-fix-build-with-latest-GCC-9.0-tree.patch b/gdb-gcc9-fix-build-with-latest-GCC-9.0-tree.patch deleted file mode 100644 index 15d63f8..0000000 --- a/gdb-gcc9-fix-build-with-latest-GCC-9.0-tree.patch +++ /dev/null @@ -1,50 +0,0 @@ -From 7406a50077773e78282a495cb32ef5b8179f6a33 Mon Sep 17 00:00:00 2001 -From: Dimitar Dimitrov -Date: Mon, 17 Dec 2018 21:30:52 +0200 -Subject: [PATCH] Fix build with latest GCC 9.0 tree - -A recent patch [1] to fix a GCC PR [2] actually broke the GDB build. -To fix, remove the stack pointer clobber. GCC will ignore the clobber -marker, and will not save or restore the stack pointer. - -I ran "make check-gdb" on x86_64 to ensure there are no regressions. - -gdb/ChangeLog: - -2018-12-17 Dimitar Dimitrov - - * nat/linux-ptrace.c (linux_ptrace_test_ret_to_nx): Remove sp clobbers. - -[1] https://gcc.gnu.org/ml/gcc-patches/2018-12/msg00532.html -[2] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=52813 - -Signed-off-by: Dimitar Dimitrov ---- - gdb/ChangeLog | 5 +++++ - gdb/nat/linux-ptrace.c | 4 ++-- - 2 files changed, 7 insertions(+), 2 deletions(-) - -diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c -index d4c1b8f9fd..187cfeb9bc 100644 ---- a/gdb/nat/linux-ptrace.c -+++ b/gdb/nat/linux-ptrace.c -@@ -161,14 +161,14 @@ linux_ptrace_test_ret_to_nx (void) - ".globl linux_ptrace_test_ret_to_nx_instr;" - "linux_ptrace_test_ret_to_nx_instr:" - "ret" -- : : "r" (return_address) : "%esp", "memory"); -+ : : "r" (return_address) : "memory"); - #elif defined __x86_64__ - asm volatile ("pushq %0;" - ".globl linux_ptrace_test_ret_to_nx_instr;" - "linux_ptrace_test_ret_to_nx_instr:" - "ret" - : : "r" ((uint64_t) (uintptr_t) return_address) -- : "%rsp", "memory"); -+ : "memory"); - #else - # error "!__i386__ && !__x86_64__" - #endif --- -2.21.0 - diff --git a/gdb-gcc9-warning-on-elf32-arm.c-elf32_arm_final_link.patch b/gdb-gcc9-warning-on-elf32-arm.c-elf32_arm_final_link.patch deleted file mode 100644 index b596982..0000000 --- a/gdb-gcc9-warning-on-elf32-arm.c-elf32_arm_final_link.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 453f8e1e4918171bc12e4d03aab7ee8360dfcfef Mon Sep 17 00:00:00 2001 -From: Sergio Durigan Junior -Date: Mon, 21 Jan 2019 15:36:41 -0500 -Subject: [PATCH] Fix GCC9 warning on elf32-arm.c:elf32_arm_final_link_relocate - -Fedora Rawhide has just switched to GCC9, and now GDB doesn't compile -because of a BFD warning: - - BUILDSTDERR: ../../bfd/elf32-arm.c: In function 'elf32_arm_final_link_relocate': - BUILDSTDERR: ../../bfd/elf32-arm.c:10907:10: error: absolute value function 'labs' given an argument of type 'bfd_signed_vma' {aka 'long long int'} but has parameter of type 'long int' which may cause truncation of value [-Werror=absolute-value] - BUILDSTDERR: 10907 | value = labs (relocation); - BUILDSTDERR: | ^~~~ - -You can take a look at the full build log here: - - https://kojipkgs.fedoraproject.org//work/tasks/4828/32174828/build.log - -The fix is (apparently) simple: instead of using 'labs', we should use -'llabs', since we're passing a 'bfd_signed_vma' to it, which is at -least a 'long long int', as far as I have checked. This is what this -patch does. - -bfd/ChangeLog: -2019-01-25 Sergio Durigan Junior - - * elf32-arm.c (elf32_arm_final_link_relocate): Use 'llabs' instead - of 'labs' (and fix GCC warning). ---- - bfd/ChangeLog | 5 +++++ - bfd/elf32-arm.c | 2 +- - 2 files changed, 6 insertions(+), 1 deletion(-) - -diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c -index 53baea269b..28ee9d55a8 100644 ---- a/bfd/elf32-arm.c -+++ b/bfd/elf32-arm.c -@@ -10904,7 +10904,7 @@ elf32_arm_final_link_relocate (reloc_howto_type * howto, - - /* PR 21523: Use an absolute value. The user of this reloc will - have already selected an ADD or SUB insn appropriately. */ -- value = labs (relocation); -+ value = llabs (relocation); - - if (value >= 0x1000) - return bfd_reloc_overflow; --- -2.21.0 - diff --git a/gdb.spec b/gdb.spec index 388ed46..2aef684 100644 --- a/gdb.spec +++ b/gdb.spec @@ -219,8 +219,6 @@ Patch1002: gdb-6.6-buildid-locate-rpm-suse.patch Patch1004: gdb-fix-buf-overflow.diff Patch1005: gdb-7.10-swo18929.patch Patch1007: gdb-fix-s390-build.diff -Patch1008: gdb-gcc9-fix-build-with-latest-GCC-9.0-tree.patch -Patch1009: gdb-gcc9-warning-on-elf32-arm.c-elf32_arm_final_link.patch # Backports from master @@ -540,8 +538,6 @@ find -name "*.info*"|xargs rm -f %patch1004 -p1 %patch1005 -p1 %patch1007 -p1 -%patch1008 -p1 -%patch1009 -p1 %patch2000 -p1 %patch2001 -p1