Blame SOURCES/gdb-jit-reader-multilib.patch

0b3064
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
0b3064
From: Fedora GDB patches <invalid@email.com>
0b3064
Date: Fri, 27 Oct 2017 21:07:50 +0200
0b3064
Subject: gdb-jit-reader-multilib.patch
0b3064
0b3064
;; Fix jit-reader.h for multi-lib.
0b3064
;;=push+jan
0b3064
0b3064
diff --git a/gdb/configure b/gdb/configure
0b3064
--- a/gdb/configure
0b3064
+++ b/gdb/configure
0b3064
@@ -9694,10 +9694,12 @@ _ACEOF
0b3064
 
0b3064
 
0b3064
 
0b3064
-if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
0b3064
-  TARGET_PTR="unsigned long"
0b3064
-elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
0b3064
+# Try to keep TARGET_PTR the same across archs so that jit-reader.h file
0b3064
+# content is the same for multilib distributions.
0b3064
+if test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
0b3064
   TARGET_PTR="unsigned long long"
0b3064
+elif test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
0b3064
+  TARGET_PTR="unsigned long"
0b3064
 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
0b3064
   TARGET_PTR="unsigned __int128"
0b3064
 else
0b3064
diff --git a/gdb/configure.ac b/gdb/configure.ac
0b3064
--- a/gdb/configure.ac
0b3064
+++ b/gdb/configure.ac
0b3064
@@ -808,10 +808,12 @@ AC_CHECK_SIZEOF(unsigned long long)
0b3064
 AC_CHECK_SIZEOF(unsigned long)
0b3064
 AC_CHECK_SIZEOF(unsigned __int128)
0b3064
 
0b3064
-if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
0b3064
-  TARGET_PTR="unsigned long"
0b3064
-elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
0b3064
+# Try to keep TARGET_PTR the same across archs so that jit-reader.h file
0b3064
+# content is the same for multilib distributions.
0b3064
+if test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
0b3064
   TARGET_PTR="unsigned long long"
0b3064
+elif test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
0b3064
+  TARGET_PTR="unsigned long"
0b3064
 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
0b3064
   TARGET_PTR="unsigned __int128"
0b3064
 else