summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/binutils/gdb
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/binutils/gdb')
-rw-r--r--gnu/usr.bin/binutils/gdb/configure.host1
-rw-r--r--gnu/usr.bin/binutils/gdb/configure.tgt1
-rw-r--r--gnu/usr.bin/binutils/gdb/exec.c5
-rw-r--r--gnu/usr.bin/binutils/gdb/solib.c2
-rw-r--r--gnu/usr.bin/binutils/gdb/symfile.c2
-rw-r--r--gnu/usr.bin/binutils/gdb/utils.c17
6 files changed, 24 insertions, 4 deletions
diff --git a/gnu/usr.bin/binutils/gdb/configure.host b/gnu/usr.bin/binutils/gdb/configure.host
index 8117694ccb6..1affab41d78 100644
--- a/gnu/usr.bin/binutils/gdb/configure.host
+++ b/gnu/usr.bin/binutils/gdb/configure.host
@@ -36,6 +36,7 @@ alpha-*-osf2*) gdb_host=alpha-osf2 ;;
alpha-*-osf[3456789]*) gdb_host=alpha-osf3 ;;
alpha-*-linux*) gdb_host=alpha-linux ;;
+arm-*-openbsd*) gdb_host=obsd ;;
arm-*-*) gdb_host=arm ;;
c[12]-*-*) gdb_host=convex ;;
diff --git a/gnu/usr.bin/binutils/gdb/configure.tgt b/gnu/usr.bin/binutils/gdb/configure.tgt
index 8852be12dbe..7278c735c9a 100644
--- a/gnu/usr.bin/binutils/gdb/configure.tgt
+++ b/gnu/usr.bin/binutils/gdb/configure.tgt
@@ -47,6 +47,7 @@ alpha-*-osf*) gdb_target=alpha-osf1 ;;
alpha-*-linux*) gdb_target=alpha-linux ;;
+arm-*-openbsd*) gdb_target=obsd ;;
arm-*-*) gdb_target=arm ;;
c1-*-*) gdb_target=convex ;;
diff --git a/gnu/usr.bin/binutils/gdb/exec.c b/gnu/usr.bin/binutils/gdb/exec.c
index 405ea5d2dcb..fece15b6e78 100644
--- a/gnu/usr.bin/binutils/gdb/exec.c
+++ b/gnu/usr.bin/binutils/gdb/exec.c
@@ -40,6 +40,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef O_BINARY
#define O_BINARY 0
#endif
+#include <stdbool.h>
#include "xcoffsolib.h"
@@ -440,10 +441,10 @@ xfer_memory (memaddr, myaddr, len, write, target)
int write;
struct target_ops *target;
{
- boolean res;
+ bool res;
struct section_table *p;
CORE_ADDR nextsectaddr, memend;
- boolean (*xfer_fn) PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
+ bool (*xfer_fn) PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
if (len <= 0)
abort();
diff --git a/gnu/usr.bin/binutils/gdb/solib.c b/gnu/usr.bin/binutils/gdb/solib.c
index 914567415f1..041cd2acd5a 100644
--- a/gnu/usr.bin/binutils/gdb/solib.c
+++ b/gnu/usr.bin/binutils/gdb/solib.c
@@ -302,7 +302,7 @@ solib_map_sections (so)
}
/* Leave bfd open, core_xfer_memory and "info files" need it. */
so -> abfd = abfd;
- abfd -> cacheable = true;
+ abfd -> cacheable = TRUE;
/* copy full path name into so_name, so that later symbol_file_add can find
it */
diff --git a/gnu/usr.bin/binutils/gdb/symfile.c b/gnu/usr.bin/binutils/gdb/symfile.c
index 45760cb190a..a769c772569 100644
--- a/gnu/usr.bin/binutils/gdb/symfile.c
+++ b/gnu/usr.bin/binutils/gdb/symfile.c
@@ -866,7 +866,7 @@ symfile_bfd_open (name)
error ("\"%s\": can't open to read symbols: %s.", name,
bfd_errmsg (bfd_get_error ()));
}
- sym_bfd->cacheable = true;
+ sym_bfd->cacheable = TRUE;
if (!bfd_check_format (sym_bfd, bfd_object))
{
diff --git a/gnu/usr.bin/binutils/gdb/utils.c b/gnu/usr.bin/binutils/gdb/utils.c
index 4948fbba4cd..9daed9f6b60 100644
--- a/gnu/usr.bin/binutils/gdb/utils.c
+++ b/gnu/usr.bin/binutils/gdb/utils.c
@@ -782,6 +782,7 @@ xmrealloc (md, ptr, size)
/* Like malloc but get error if no storage available, and protect against
the caller wanting to allocate zero bytes. */
+#ifndef NO_XMALLOC
PTR
xmalloc (size)
size_t size;
@@ -789,6 +790,21 @@ xmalloc (size)
return (xmmalloc ((PTR) NULL, size));
}
+PTR
+xcalloc (nelem, elsize)
+ size_t nelem, elsize;
+{
+ PTR newmem;
+
+ if (nelem == 0 || elsize == 0)
+ nelem = elsize = 1;
+
+ newmem = xmmalloc((PTR) NULL, nelem * elsize);
+ memset(newmem, 0, nelem * elsize);
+
+ return (newmem);
+}
+
/* Like mrealloc but get error if no storage available. */
PTR
@@ -798,6 +814,7 @@ xrealloc (ptr, size)
{
return (xmrealloc ((PTR) NULL, ptr, size));
}
+#endif
/* My replacement for the read system call.