gdb/gdb-7.2.50-sparc-add-workaround-to-broken-debug-files.patch
Jan Kratochvil 11eae30806 Rebase to FSF GDB 7.4.50.20120703.
- [archer-tromey-dwz-multifile-rebase] Merge new branch (Tom Tromey).
- [arm] <--with testsuite>: Disable fpc BuildRequires as it is not yet built.
- Revert function returning pointer fix (PR 9514) regressing Fedora errno patch.
2012-07-03 20:54:05 +02:00

52 lines
1.2 KiB
Diff

Index: gdb-7.4.50.20120703/gdb/gdb_bfd.c
===================================================================
--- gdb-7.4.50.20120703.orig/gdb/gdb_bfd.c 2012-07-03 17:30:07.356754655 +0200
+++ gdb-7.4.50.20120703/gdb/gdb_bfd.c 2012-07-03 17:43:52.565762454 +0200
@@ -26,12 +26,14 @@
#ifdef HAVE_ZLIB_H
#include <zlib.h>
#endif
+#ifndef __sparc__
#ifdef HAVE_MMAP
#include <sys/mman.h>
#ifndef MAP_FAILED
#define MAP_FAILED ((void *) -1)
#endif
#endif
+#endif
/* An object of this type is stored in the section's user data when
mapping a section. */
@@ -181,6 +183,7 @@ free_one_bfd_section (bfd *abfd, asectio
if (sect != NULL && sect->data != NULL)
{
+#ifndef __sparc__
#ifdef HAVE_MMAP
if (sect->map_addr != NULL)
{
@@ -191,6 +194,7 @@ free_one_bfd_section (bfd *abfd, asectio
}
else
#endif
+#endif
xfree (sect->data);
}
}
@@ -425,6 +429,7 @@ gdb_bfd_map_section (asection *sectp, bf
}
}
+#ifndef __sparc__
#ifdef HAVE_MMAP
{
/* The page size, used when mmapping. */
@@ -458,6 +463,7 @@ gdb_bfd_map_section (asection *sectp, bf
}
}
#endif /* HAVE_MMAP */
+#endif
/* If we get here, we are a normal, not-compressed section. */