public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  jankratochvil/ipv6: .
@ 2013-04-15 20:10 jkratoch
  0 siblings, 0 replies; 4+ messages in thread
From: jkratoch @ 2013-04-15 20:10 UTC (permalink / raw)
  To: archer-commits

The branch, jankratochvil/ipv6 has been updated
       via  410dc9a3df7413cb21be3dd86d163938b7f23dfa (commit)
      from  a2ba627216df40efd23a515651c16368d588e38b (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 410dc9a3df7413cb21be3dd86d163938b7f23dfa
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 15 22:10:52 2013 +0200

    .

-----------------------------------------------------------------------

Summary of changes:
 gdb/gdbserver/gdbreplay.c    |  194 +++++++++++++++++-------------------------
 gdb/gdbserver/remote-utils.c |   85 ++++++++++++------
 gdb/gdbserver/server.h       |    4 +-
 gdb/ser-tcp.c                |  192 ++++++++++++++++++++++++-----------------
 4 files changed, 248 insertions(+), 227 deletions(-)

First 500 lines of diff:
diff --git a/gdb/gdbserver/gdbreplay.c b/gdb/gdbserver/gdbreplay.c
index ad4c0d0..9ed2fb5 100644
--- a/gdb/gdbserver/gdbreplay.c
+++ b/gdb/gdbserver/gdbreplay.c
@@ -76,7 +76,7 @@ typedef int socklen_t;
 extern const char version[];
 extern const char host_name[];
 
-static int remote_desc_in, remote_desc_out;
+static int remote_desc;
 
 #ifdef __MINGW32CE__
 
@@ -177,152 +177,114 @@ static void
 remote_close (void)
 {
 #ifdef USE_WIN32API
-  closesocket (remote_desc_in);
-  if (remote_desc_in != remote_desc_out)
-    closesocket (remote_desc_out);
+  closesocket (remote_desc);
 #else
-  close (remote_desc_in);
-  if (remote_desc_in != remote_desc_out)
-    close (remote_desc_out);
+  close (remote_desc);
 #endif
 }
 
-/* Parse the string "fdin=<#>,fdout=<#>" into `remote_desc_in' and
-   `remote_desc_out' file descripts.  Return non-zero for success.  */
-
-static int
-parse_fds (char *name)
-{
-  const char *fdin_string = "fdin=";
-  size_t fdin_string_len = strlen (fdin_string);
-  const char *comma_fdout_string = ",fdout=";
-  size_t comma_fdout_string_len = strlen (comma_fdout_string);
-  long l;
-
-  if (strncmp (name, fdin_string, fdin_string_len) != 0)
-    return 0;
-  name += fdin_string_len;
-
-  if (*name == 0 || *name == ',')
-    return 0;
-  errno = 0;
-  l = strtol (name, &name, 10);
-  remote_desc_in = l;
-  if (errno != 0 || name == NULL || l < 0 || remote_desc_in != l)
-    return 0;
-
-  if (strncmp (name, comma_fdout_string, comma_fdout_string_len) != 0)
-    return 0;
-  name += comma_fdout_string_len;
-
-  if (*name == 0 || *name == ',')
-    return 0;
-  errno = 0;
-  l = strtol (name, &name, 10);
-  remote_desc_out = l;
-  if (errno != 0 || name == NULL || l < 0 || remote_desc_out != l)
-    return 0;
-
-  if (*name != 0)
-    return 0;
-
-  return 1;
-}
-
 /* Open a connection to a remote debugger.
    NAME is the filename used for communication.  */
 
 static void
 remote_open (char *name)
 {
-  /* "fdin=<#>,fdout=<#>"  */
-  if (parse_fds (name))
-    {
-      fprintf (stderr, "Remote debugging using file descriptors"
-               " (input = %d, output = %d)\n", remote_desc_in, remote_desc_out);
-    }
-  else if (!strchr (name, ':'))
+  char *port_str = strrchr (name, ':');
+#ifdef USE_WIN32API
+  static int winsock_initialized;
+#endif
+  struct sockaddr_in sockaddr;
+  socklen_t socklen;
+  int tmp_desc, n, i;
+  struct addrinfo hints;
+  struct addrinfo *addrinfo_base, *addrinfo;
+
+  if (port_str == NULL)
     {
-      fprintf (stderr, "%s: Must specify tcp connection as host:addr"
-	       " or use fdin=<fd #>,fdout=<fd #>\n", name);
+      fprintf (stderr, "%s: Must specify tcp connection as host:addr\n", name);
       fflush (stderr);
       exit (1);
     }
-  else
-    {
-      int remote_desc;
+
 #ifdef USE_WIN32API
-      static int winsock_initialized;
+  if (!winsock_initialized)
+    {
+      WSADATA wsad;
+
+      WSAStartup (MAKEWORD (1, 0), &wsad);
+      winsock_initialized = 1;
+    }
 #endif
-      char *port_str;
-      int port;
-      struct sockaddr_in sockaddr;
-      socklen_t tmp;
-      int tmp_desc;
 
-      port_str = strchr (name, ':');
+  memset (&hints, 0, sizeof hints);
+  hints.ai_family = AF_UNSPEC;
+  hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG | AI_PASSIVE;
+  hints.ai_socktype = SOCK_STREAM;
 
-      port = atoi (port_str + 1);
+  *port_str = 0;
+  n = getaddrinfo (name, port_str, &hints, &addrinfo_base);
+  if (n != 0)
+    {
+      fprintf (stderr, "%s:%s: cannot resolve: %s\n",
+	       name, port_str, gai_strerror (n));
+      exit (1);
+    }
 
-#ifdef USE_WIN32API
-      if (!winsock_initialized)
+  for (addrinfo = addrinfo_base; addrinfo != NULL;
+       addrinfo = addrinfo->ai_next)
+    {
+      tmp_desc = socket (addrinfo->ai_family, addrinfo->ai_socktype,
+			 addrinfo->ai_protocol);
+      if (tmp_desc == -1)
 	{
-	  WSADATA wsad;
+	  if (addrinfo->ai_next != NULL)
+	    continue;
+	  perror_with_name ("Can't open socket");
+	}
+
+      /* Allow rapid reuse of this port. */
+      i = 1;
+      setsockopt (tmp_desc, SOL_SOCKET, SO_REUSEADDR, &i, sizeof (i));
 
-	  WSAStartup (MAKEWORD (1, 0), &wsad);
-	  winsock_initialized = 1;
+      if (bind (tmp_desc, addrinfo->ai_addr, addrinfo->ai_addrlen) != 0
+	  || listen (tmp_desc, 1) != 0)
+	{
+	  if (addrinfo->ai_next != NULL)
+	    {
+	      close (tmp_desc);
+	      continue;
+	    }
+	  perror_with_name ("Can't bind address");
 	}
-#endif
+      break;
+    }
 
-      tmp_desc = socket (PF_INET, SOCK_STREAM, 0);
-      if (tmp_desc == -1)
-	perror_with_name ("Can't open socket");
+  socklen = sizeof (sockaddr);
+  remote_desc = accept (tmp_desc, (struct sockaddr *) &sockaddr, &socklen);
+  if (remote_desc == -1)
+    perror_with_name ("Accept failed");
 
-      /* Allow rapid reuse of this port. */
-      tmp = 1;
-      setsockopt (tmp_desc, SOL_SOCKET, SO_REUSEADDR, (char *) &tmp,
-		  sizeof (tmp));
-
-      sockaddr.sin_family = PF_INET;
-      sockaddr.sin_port = htons (port);
-      sockaddr.sin_addr.s_addr = INADDR_ANY;
-
-      if (bind (tmp_desc, (struct sockaddr *) &sockaddr, sizeof (sockaddr))
-	  || listen (tmp_desc, 1))
-	perror_with_name ("Can't bind address");
-
-      tmp = sizeof (sockaddr);
-      remote_desc = accept (tmp_desc, (struct sockaddr *) &sockaddr, &tmp);
-      if (remote_desc == -1)
-	perror_with_name ("Accept failed");
-
-      /* Enable TCP keep alive process. */
-      tmp = 1;
-      setsockopt (tmp_desc, SOL_SOCKET, SO_KEEPALIVE,
-		  (char *) &tmp, sizeof (tmp));
-
-      /* Tell TCP not to delay small packets.  This greatly speeds up
-	 interactive response. */
-      tmp = 1;
-      setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY,
-		  (char *) &tmp, sizeof (tmp));
+  /* Enable TCP keep alive process. */
+  i = 1;
+  setsockopt (tmp_desc, SOL_SOCKET, SO_KEEPALIVE, &i, sizeof (i));
+
+  /* Tell TCP not to delay small packets.  This greatly speeds up
+     interactive response. */
+  i = 1;
+  setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY, &i, sizeof (i));
 
 #ifndef USE_WIN32API
-      close (tmp_desc);		/* No longer need this */
+  close (tmp_desc);		/* No longer need this */
 
-      signal (SIGPIPE, SIG_IGN);	/* If we don't do this, then
-					   gdbreplay simply exits when
-					   the remote side dies.  */
+  signal (SIGPIPE, SIG_IGN);	/* If we don't do this, then
+				   gdbreplay simply exits when
+				   the remote side dies.  */
 #else
-      closesocket (tmp_desc);	/* No longer need this */
+  closesocket (tmp_desc);	/* No longer need this */
 #endif
-      remote_desc_in = remote_desc_out = remote_desc;
-    }
 
 #if defined(F_SETFL) && defined (FASYNC)
-  fcntl (remote_desc_in, F_SETFL, FASYNC);
-  if (remote_desc_in != remote_desc_out)
-    fcntl (remote_desc_out, F_SETFL, FASYNC);
+  fcntl (remote_desc, F_SETFL, FASYNC);
 #endif
 
   fprintf (stderr, "Replay logfile using %s\n", name);
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index fe0e39a..9f896b0 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -60,7 +60,6 @@
 #if HAVE_ERRNO_H
 #include <errno.h>
 #endif
-#include <ctype.h>
 
 #if USE_WIN32API
 #include <winsock2.h>
@@ -221,16 +220,16 @@ handle_accept_event (int err, gdb_client_data client_data)
    NAME is the filename used for communication.  */
 
 void
-remote_prepare (char *name)
+remote_prepare (const char *name)
 {
-  char *port_str;
+  const char *port_str;
+  char *hostname;
+  int n;
+  struct addrinfo hints;
+  struct addrinfo *addrinfo_base, *addrinfo;
 #ifdef USE_WIN32API
   static int winsock_initialized;
 #endif
-  int port;
-  struct sockaddr_in sockaddr;
-  socklen_t tmp;
-  char *port_end;
 
   remote_is_stdio = 0;
   if (strcmp (name, STDIO_CONNECTION_NAME) == 0)
@@ -243,17 +242,13 @@ remote_prepare (char *name)
       return;
     }
 
-  port_str = strchr (name, ':');
+  port_str = strrchr (name, ':');
   if (port_str == NULL)
     {
       transport_is_reliable = 0;
       return;
     }
 
-  port = strtoul (port_str + 1, &port_end, 10);
-  if (port_str[1] == '\0' || *port_end != '\0')
-    fatal ("Bad port argument: %s", name);
-
 #ifdef USE_WIN32API
   if (!winsock_initialized)
     {
@@ -264,22 +259,56 @@ remote_prepare (char *name)
     }
 #endif
 
-  listen_desc = socket (PF_INET, SOCK_STREAM, IPPROTO_TCP);
-  if (listen_desc == -1)
-    perror_with_name ("Can't open socket");
+  memset (&hints, 0, sizeof hints);
+  hints.ai_family = AF_UNSPEC;
+  hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG | AI_PASSIVE;
+  hints.ai_socktype = SOCK_STREAM;
 
-  /* Allow rapid reuse of this port. */
-  tmp = 1;
-  setsockopt (listen_desc, SOL_SOCKET, SO_REUSEADDR, (char *) &tmp,
-	      sizeof (tmp));
+  hostname = xstrdup (name);
+  hostname[port_str - name] = 0;
+  port_str++;
+  if (*hostname == 0)
+    hostname = NULL;
 
-  sockaddr.sin_family = PF_INET;
-  sockaddr.sin_port = htons (port);
-  sockaddr.sin_addr.s_addr = INADDR_ANY;
+  n = getaddrinfo (hostname, port_str, &hints, &addrinfo_base);
+  if (n != 0)
+    {
+      fprintf (stderr, _("%s:%s: cannot resolve: %s\n"),
+	       hostname, port_str, gai_strerror (n));
+      transport_is_reliable = 0;
+      return;
+    }
+
+  for (addrinfo = addrinfo_base; addrinfo != NULL; addrinfo = addrinfo->ai_next)
+    {
+      int i;
 
-  if (bind (listen_desc, (struct sockaddr *) &sockaddr, sizeof (sockaddr))
-      || listen (listen_desc, 1))
-    perror_with_name ("Can't bind address");
+printf("ai_family=%d,ai_socktype=%d\n",addrinfo->ai_family,addrinfo->ai_socktype);
+      listen_desc = socket (addrinfo->ai_family, addrinfo->ai_socktype,
+			    addrinfo->ai_protocol);
+      if (listen_desc == -1)
+	{
+	  if (addrinfo->ai_next != NULL)
+	    continue;
+	  perror_with_name ("Can't open socket");
+	}
+
+      /* Allow rapid reuse of this port. */
+      i = 1;
+      setsockopt (listen_desc, SOL_SOCKET, SO_REUSEADDR, &i, sizeof (i));
+
+      if (bind (listen_desc, addrinfo->ai_addr, addrinfo->ai_addrlen) != 0
+	  || listen (listen_desc, 1) != 0)
+	{
+	  if (addrinfo->ai_next != NULL)
+	    {
+	      close (listen_desc);
+	      continue;
+	    }
+	  perror_with_name ("Can't bind address");
+	}
+      break;
+    }
 
   transport_is_reliable = 1;
 }
@@ -288,11 +317,11 @@ remote_prepare (char *name)
    NAME is the filename used for communication.  */
 
 void
-remote_open (char *name)
+remote_open (const char *name)
 {
-  char *port_str;
+  const char *port_str;
 
-  port_str = strchr (name, ':');
+  port_str = strrchr (name, ':');
 #ifdef USE_WIN32API
   if (port_str == NULL)
     error ("Only <host>:<port> is supported on this platform.");
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 139cd49..664b997 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -289,8 +289,8 @@ int putpkt (char *buf);
 int putpkt_binary (char *buf, int len);
 int putpkt_notif (char *buf);
 int getpkt (char *buf);
-void remote_prepare (char *name);
-void remote_open (char *name);
+void remote_prepare (const char *name);
+void remote_open (const char *name);
 void remote_close (void);
 void write_ok (char *buf);
 void write_enn (char *buf);
diff --git a/gdb/ser-tcp.c b/gdb/ser-tcp.c
index 03db465..58877d9 100644
--- a/gdb/ser-tcp.c
+++ b/gdb/ser-tcp.c
@@ -150,77 +150,39 @@ wait_for_connect (struct serial *scb, unsigned int *polls)
   return n;
 }
 
-/* Open a tcp socket.  */
+/* make_cleanup stub for net_close.  */
 
-int
-net_open (struct serial *scb, const char *name)
+static void
+net_close_cleanup (void *arg)
+{
+  struct serial *scb = arg;
+
+  net_close (scb);
+}
+
+/* Create socket and connect it to ADDRINFO.  On return SCB->FD is -1 on error
+   (and errno is set) or SCB->FD is a connected file descriptor.  */
+
+static void
+scb_connect (struct serial *scb, const struct addrinfo *addrinfo)
 {
-  char *port_str, hostname[100];
-  int n, port, tmp;
-  struct addrinfo hints;
-  struct addrinfo *addrinfo_base, *addrinfo = NULL;
 #ifdef USE_WIN32API
   u_long ioarg;
 #else
   int ioarg;
 #endif
-  unsigned int polls = 0, retval = -1;
-  struct cleanup *back_to;
-
-  memset (&hints, 0, sizeof hints);
-  hints.ai_family = AF_UNSPEC;
-  hints.ai_flags = AI_ADDRCONFIG;
-  hints.ai_socktype = SOCK_STREAM;
-  if (strncmp (name, "udp:", 4) == 0)
-    {
-      hints.ai_socktype = SOCK_DGRAM;
-      name = name + 4;
-    }
-  else if (strncmp (name, "tcp:", 4) == 0)
-    name = name + 4;
+  int n, tmp;
+  unsigned int polls = 0;
+  struct cleanup *scb_cleanup;
 
-  port_str = strchr (name, ':');
+  gdb_assert (scb->fd == -1);
 
-  if (!port_str)
-    error (_("net_open: No colon in host name!"));  /* Shouldn't ever
-						       happen.  */
-
-  tmp = min (port_str - name, (int) sizeof hostname - 1);
-  strncpy (hostname, name, tmp);	/* Don't want colon.  */
-  hostname[tmp] = '\000';	/* Tie off host name.  */
-  port = atoi (port_str + 1);
-
-  /* Default hostname is localhost.  */
-  if (!hostname[0])
-    strcpy (hostname, "localhost");
-
-  if (getaddrinfo (hostname, port_str, &hints, &addrinfo_base) != 0)
-    {
-      fprintf_unfiltered (gdb_stderr, _("%s:%s: cannot resolve: %s\n"),
-			  hostname, port_str, gai_strerror (n));
-      errno = ENOENT;
-      return -1;
-    }
-
-  assert (addrinfo_base != NULL);
-  back_to = make_cleanup_freeaddrinfo (addrinfo_base);
-
- retry:
+  scb->fd = socket (addrinfo->ai_family, addrinfo->ai_socktype,
+		    addrinfo->ai_protocol);
+  if (scb->fd == -1)
+    return;
 
-  for (addrinfo = addrinfo_base; addrinfo != NULL; addrinfo = addrinfo->ai_next)
-    {
-      scb->fd = socket (addrinfo->ai_family, addrinfo->ai_socktype,
-			addrinfo->ai_protocol);
-      if (scb->fd >= 0)
-	break;
-    }
-  if (addrinfo == NULL)
-    {
-      fprintf_unfiltered (gdb_stderr, "%s:%s: cannot create socket: %s\n",
-			  hostname, port_str, safe_strerror (errno));
-      do_cleanups (back_to);
-      return -1;
-    }
+  scb_cleanup = make_cleanup (net_close_cleanup, scb);
 


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [SCM]  jankratochvil/ipv6: .
@ 2013-04-22 19:36 jkratoch
  0 siblings, 0 replies; 4+ messages in thread
From: jkratoch @ 2013-04-22 19:36 UTC (permalink / raw)
  To: archer-commits

The branch, jankratochvil/ipv6 has been updated
       via  3e5395a8244d2fca7cec764d01dab3261b77223e (commit)
       via  f45c0f05330d4fde0ce0ade1929fa5ae290d9cd1 (commit)
       via  28b0591a66a42ceb3b8dc21774b3a9af9be04768 (commit)
       via  e7fe6477907cac25a1afbd640c9d83842d7c8333 (commit)
       via  d030ea133275b11252464ee1a2592eaf4178d97a (commit)
       via  5f50510cc6d43a4d2521073fcae4b34d562ad969 (commit)
       via  4152b8ba0865cf85b5916f805978b466d3749c33 (commit)
       via  1a86332f151a80165f14b92b0c0280b58e3b3592 (commit)
       via  e9ebe796b8a0e17d62261f946ef1a2d817a67d35 (commit)
       via  4562eaf8de8def872b0eea8afa47af81bc2bd080 (commit)
       via  fc3c0e8a38eb511632c6169e4c7ece91c1b30a98 (commit)
       via  4959fbcc4c088a229e0971bd0960778b22d866ab (commit)
       via  6af7472730e4de1a69601bfbae73a4633133094f (commit)
       via  a69c4d3aeffec18fa0999d2551896484f80bf267 (commit)
       via  16c2a8f6f6ad2e2a83b3a8f85a8caa7aac28a97b (commit)
       via  dab3e9d11e87ac947a4be93f105766d1fecec9c8 (commit)
       via  31c3cb8150c49f3b3f57b16177ea5ad6a731a99f (commit)
       via  61d804d6fb50532a7361445aa48404bdf48d92e6 (commit)
       via  0bade1700c08d7b7c9692c7a3b1312d551e99fc1 (commit)
       via  06d7810130905e0e220c2f4bc700791b4f13da99 (commit)
       via  07196f47e56407c0efc4e868d6f10d321b3bfeeb (commit)
       via  6501de4b56219a3414039fff3a206d4d54d15f27 (commit)
       via  ab92212352e6e61f0a3b33faa5d0021b2cb72600 (commit)
       via  84cd0f36998857e9fe18cedb8a3de5950e57df90 (commit)
       via  0da41145519d1bd3e13eb2f1fc5865edbf49e85e (commit)
       via  d32cecb14bd4c58c316e506dd2db70e39a75045e (commit)
       via  f072f003809dfe08f6f98719680e8e862fc3a021 (commit)
       via  a1ccd4e4395a1215661f4dc88646514c53aeb0b9 (commit)
       via  ceff6a55e34396c81009e9c93086e7fa84eb73ec (commit)
       via  c8672d57d6e470057494b26e1a3c58d6b9e45ebe (commit)
       via  dbd948e82e78b6c0cec97764b9efeafab21bdb3d (commit)
       via  f2469987720df2d5333e2e46e72c0caa00b40817 (commit)
       via  8b336e6bdffba2095f20c39140ca1b4db9d5a9d1 (commit)
       via  effff1b7fb47a783d5041d5bfa906e0598237f47 (commit)
       via  387dcc423f0b0837835ec7d1f1c5ed7728fa9574 (commit)
       via  051f357decdb4ebb99a374616ec2f231a231d188 (commit)
       via  40f0f68dc579c37f7b8acc50dbea5e4f6c013b1f (commit)
       via  9fbc529f6156b9f4b92bd339e2043eb5ef28cded (commit)
      from  e3005ec0a2efaf9c727f3bd6fe14f60e54dc5211 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 3e5395a8244d2fca7cec764d01dab3261b77223e
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:35:40 2013 +0200

    .

commit f45c0f05330d4fde0ce0ade1929fa5ae290d9cd1
Merge: 1a86332 28b0591
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:32:42 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv-reorg-include' into gnulibupdate-gnulibplus2-obv-reorg-include-ipv6
    
    Conflicts:
    	gdb/ser-tcp.c

commit 28b0591a66a42ceb3b8dc21774b3a9af9be04768
Merge: e9ebe79 e7fe647
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:30:55 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv-reorg' into gnulibupdate-gnulibplus2-obv-reorg-include
    
    Conflicts:
    	gdb/configure
    	gdb/configure.ac

commit e7fe6477907cac25a1afbd640c9d83842d7c8333
Merge: fc3c0e8 d030ea1
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:29:57 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv' into gnulibupdate-gnulibplus2-obv-reorg

commit d030ea133275b11252464ee1a2592eaf4178d97a
Merge: dab3e9d 5f50510
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:29:57 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2' into gnulibupdate-gnulibplus2-obv

commit 5f50510cc6d43a4d2521073fcae4b34d562ad969
Merge: 61d804d 4152b8b
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:29:56 2013 +0200

    Merge branch 'gnulibupdate' into gnulibupdate-gnulibplus2

commit 4152b8ba0865cf85b5916f805978b466d3749c33
Merge: b9e696b a1ccd4e
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:29:56 2013 +0200

    Merge remote-tracking branch 'gdb/master' into gnulibupdate

commit 1a86332f151a80165f14b92b0c0280b58e3b3592
Merge: 4562eaf e9ebe79
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:29:18 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv-reorg-include' into gnulibupdate-gnulibplus2-obv-reorg-include-ipv6

commit e9ebe796b8a0e17d62261f946ef1a2d817a67d35
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:28:18 2013 +0200

    .

commit 4562eaf8de8def872b0eea8afa47af81bc2bd080
Merge: 4959fbc fc3c0e8
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:24:38 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv-reorg' into gnulibupdate-gnulibplus2-obv-reorg-ipv6

commit fc3c0e8a38eb511632c6169e4c7ece91c1b30a98
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:21:40 2013 +0200

    .

commit 4959fbcc4c088a229e0971bd0960778b22d866ab
Merge: 16c2a8f 6af7472
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:21:51 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-ipv6' into gnulibupdate-gnulibplus2-obv-ipv6

commit 6af7472730e4de1a69601bfbae73a4633133094f
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:21:40 2013 +0200

    .

commit a69c4d3aeffec18fa0999d2551896484f80bf267
Merge: 0bade17 dab3e9d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:18:34 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv' into gnulibupdate-gnulibplus2-obv-reorg

commit 16c2a8f6f6ad2e2a83b3a8f85a8caa7aac28a97b
Merge: 06d7810 dab3e9d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:18:28 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv' into gnulibupdate-gnulibplus2-obv-ipv6

commit dab3e9d11e87ac947a4be93f105766d1fecec9c8
Merge: 07196f4 61d804d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:18:27 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2' into gnulibupdate-gnulibplus2-obv

commit 31c3cb8150c49f3b3f57b16177ea5ad6a731a99f
Merge: e3005ec 61d804d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:18:20 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2' into gnulibupdate-gnulibplus2-ipv6

commit 61d804d6fb50532a7361445aa48404bdf48d92e6
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:18:15 2013 +0200

    .

commit 0bade1700c08d7b7c9692c7a3b1312d551e99fc1
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:14:03 2013 +0200

    .

commit 06d7810130905e0e220c2f4bc700791b4f13da99
Merge: 6501de4 07196f4
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:06:50 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-obv' into gnulibupdate-gnulibplus2-obv-ipv6

commit 07196f47e56407c0efc4e868d6f10d321b3bfeeb
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 21:06:42 2013 +0200

    .

commit 6501de4b56219a3414039fff3a206d4d54d15f27
Merge: 84cd0f3 ab92212
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:50:21 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-setsockopt' into gnulibupdate-gnulibplus2-setsockopt-ipv6
    
    Conflicts:
    	gdb/gdbserver/gdbreplay.c

commit ab92212352e6e61f0a3b33faa5d0021b2cb72600
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:49:41 2013 +0200

    .

commit 84cd0f36998857e9fe18cedb8a3de5950e57df90
Merge: e3005ec 0da4114
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:49:11 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2-setsockopt' into gnulibupdate-gnulibplus2-setsockopt-ipv6
    
    Conflicts:
    	gdb/gdbserver/gdbreplay.c
    	gdb/gdbserver/remote-utils.c
    	gdb/ser-tcp.c

commit 0da41145519d1bd3e13eb2f1fc5865edbf49e85e
Merge: d32cecb 57683ce
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:43:20 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus2' into gnulibupdate-gnulibplus2-setsockopt

commit d32cecb14bd4c58c316e506dd2db70e39a75045e
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:41:33 2013 +0200

    .

commit f072f003809dfe08f6f98719680e8e862fc3a021
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Mon Apr 22 20:37:57 2013 +0200

    .

commit a1ccd4e4395a1215661f4dc88646514c53aeb0b9
Author: Jan-Benedict Glaw <jbglaw@lug-owl.de>
Date:   Mon Apr 22 17:11:22 2013 +0000

    2013-04-22  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
    
    	* Makefile.def: Sync with GCC.
    	* Makefile.in: Regenerate.

commit ceff6a55e34396c81009e9c93086e7fa84eb73ec
Author: Tom Tromey <tromey@redhat.com>
Date:   Mon Apr 22 16:46:14 2013 +0000

    	PR gdb/7912:
    	* Makefile.in (SFILES): Add filestuff.c
    	(COMMON_OBS): Add filestuff.o.
    	(filestuff.o): New target.
    	* auto-load.c (auto_load_objfile_script_1): Use
    	gdb_fopen_cloexec.
    	* auxv.c (procfs_xfer_auxv): Use gdb_open_cloexec.
    	* cli/cli-cmds.c (shell_escape): Call close_most_fds.
    	* cli/cli-dump.c (fopen_with_cleanup): Use gdb_fopen_cloexec.
    	* common/agent.c (gdb_connect_sync_socket): Use
    	gdb_socket_cloexec.
    	* common/filestuff.c: New file.
    	* common/filestuff.h: New file.
    	* common/linux-osdata.c (linux_common_core_of_thread)
    	(command_from_pid, commandline_from_pid, print_source_lines)
    	(linux_xfer_osdata_shm, linux_xfer_osdata_sem)
    	(linux_xfer_osdata_msg, linux_xfer_osdata_modules): Use
    	gdb_fopen_cloexec.
    	* common/linux-procfs.c (linux_proc_get_int)
    	(linux_proc_pid_has_state): Use gdb_fopen_cloexec.
    	* config.in, configure: Rebuild.
    	* configure.ac: Don't check for sys/socket.h.  Check for
    	fdwalk, pipe2.
    	* corelow.c (core_open): Use gdb_open_cloexec.
    	* dwarf2read.c (write_psymtabs_to_index): Use gdb_fopen_cloexec.
    	* fork-child.c (fork_inferior): Call close_most_fds.
    	* gdb_bfd.c (gdb_bfd_open): Use gdb_open_cloexec.
    	* inf-child.c (inf_child_fileio_readlink): Use gdb_open_cloexec.
    	* linux-nat.c (linux_nat_thread_name, linux_proc_pending_signals):
    	Use gdb_fopen_cloexec.
    	(linux_proc_xfer_partial, linux_proc_xfer_spu): Use
    	gdb_open_cloexec.
    	(linux_async_pipe): Use gdb_pipe_cloexec.
    	* remote-fileio.c (remote_fileio_func_open): Use
    	gdb_open_cloexec.
    	* remote.c (remote_file_put, remote_file_get): Use
    	gdb_fopen_cloexec.
    	* ser-pipe.c (pipe_open): Use gdb_socketpair_cloexec,
    	close_most_fds.
    	* ser-tcp.c (net_open): Use gdb_socket_cloexec.
    	* ser-unix.c (hardwire_open): Use gdb_open_cloexec.
    	* solib.c (solib_find): Use gdb_open_cloexec.
    	* source.c (openp, find_and_open_source): Use gdb_open_cloexec.
    	* tracepoint.c (tfile_start): Use gdb_fopen_cloexec.
    	(tfile_open): Use gdb_open_cloexec.
    	* tui/tui-io.c (tui_initialize_io): Use gdb_pipe_cloexec.
    	* ui-file.c (gdb_fopen): Use gdb_fopen_cloexec.
    	* xml-support.c (xml_fetch_content_from_file): Use
    	gdb_fopen_cloexec.
    	* main.c (captured_main): Call notice_open_fds.
    gdbserver
    	* Makefile.in (SFILES): Add filestuff.c.
    	(OBS): Add filestuff.o.
    	(filestuff.o): New target.
    	* config.in, configure: Rebuild.
    	* configure.ac: Check for fdwalk, pipe2.

commit c8672d57d6e470057494b26e1a3c58d6b9e45ebe
Author: emachado <emachado>
Date:   Mon Apr 22 15:50:57 2013 +0000

    2013-04-22  Edjunior Machado  <emachado@linux.vnet.ibm.com>
    
    * remote-sim.c (dump_mem): Change the type of 'buf' parameter from
    'char *' to 'gdb_byte *'.
    (gdbsim_store_register): Change the type of 'tmp' from 'char' to
    'gdb_byte'.

commit dbd948e82e78b6c0cec97764b9efeafab21bdb3d
Author: Jan-Benedict Glaw <jbglaw@lug-owl.de>
Date:   Mon Apr 22 15:25:08 2013 +0000

    2013-04-22  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
    
    	* configure.ac: Sync with GCC.
    	* configure: Regenerated.

commit f2469987720df2d5333e2e46e72c0caa00b40817
Author: Alan Modra <amodra@bigpond.net.au>
Date:   Mon Apr 22 15:03:01 2013 +0000

    	PR ld/15382
    	* elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Don't multiply
    	sh_size or reloc_count adjustment by count.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                     |   10 +
 Makefile.def                                  |    2 +-
 Makefile.in                                   |   18 +-
 bfd/ChangeLog                                 |   15 +
 bfd/elf-bfd.h                                 |    8 +-
 bfd/elf64-ppc.c                               |  172 ++++++------
 bfd/elf64-ppc.h                               |    2 +-
 bfd/version.h                                 |    2 +-
 configure                                     |    2 +
 configure.ac                                  |    2 +
 gdb/ChangeLog                                 |   69 +++++
 gdb/Makefile.in                               |    7 +-
 gdb/arm-tdep.c                                |    2 +-
 gdb/auto-load.c                               |    5 +-
 gdb/auxv.c                                    |    3 +-
 gdb/cli/cli-cmds.c                            |    3 +
 gdb/cli/cli-dump.c                            |    3 +-
 gdb/common/agent.c                            |    3 +-
 gdb/common/filestuff.c                        |  354 +++++++++++++++++++++++++
 gdb/common/filestuff.h                        |   59 ++++
 gdb/common/linux-osdata.c                     |   17 +-
 gdb/common/linux-procfs.c                     |    5 +-
 gdb/config.in                                 |    9 +-
 gdb/configure                                 |    5 +-
 gdb/configure.ac                              |    5 +-
 gdb/corelow.c                                 |    3 +-
 gdb/dsrec.c                                   |    1 +
 gdb/dwarf2read.c                              |    3 +-
 gdb/fork-child.c                              |    3 +
 gdb/gdb_bfd.c                                 |    3 +-
 gdb/gdbserver/ChangeLog                       |    8 +
 gdb/gdbserver/Makefile.in                     |    8 +-
 gdb/gdbserver/config.in                       |    6 +
 gdb/gdbserver/configure                       |    2 +-
 gdb/gdbserver/configure.ac                    |    2 +-
 gdb/gdbserver/gdbreplay.c                     |    2 +-
 gdb/inf-child.c                               |    3 +-
 gdb/infrun.c                                  |    2 +-
 gdb/linux-nat.c                               |   11 +-
 gdb/m32r-rom.c                                |    1 +
 gdb/main.c                                    |    2 +
 gdb/remote-fileio.c                           |    3 +-
 gdb/remote-m32r-sdi.c                         |    2 +-
 gdb/remote-sim.c                              |    6 +-
 gdb/remote.c                                  |    5 +-
 gdb/ser-pipe.c                                |   17 +-
 gdb/ser-tcp.c                                 |   13 +-
 gdb/ser-unix.c                                |    3 +-
 gdb/solib.c                                   |    7 +-
 gdb/source.c                                  |    7 +-
 gdb/testsuite/ChangeLog                       |   10 +
 gdb/testsuite/gdb.arch/arm-bl-branch-dest.c   |   29 ++
 gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp |   37 +++
 gdb/tracepoint.c                              |    7 +-
 gdb/tui/tui-io.c                              |    3 +-
 gdb/ui-file.c                                 |    3 +-
 gdb/version.in                                |    2 +-
 gdb/xml-support.c                             |    5 +-
 58 files changed, 814 insertions(+), 187 deletions(-)
 create mode 100644 gdb/common/filestuff.c
 create mode 100644 gdb/common/filestuff.h
 create mode 100644 gdb/testsuite/gdb.arch/arm-bl-branch-dest.c
 create mode 100644 gdb/testsuite/gdb.arch/arm-bl-branch-dest.exp

First 500 lines of diff:
diff --git a/ChangeLog b/ChangeLog
index 07594a4..8f8e1fb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2013-04-22  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
+
+	* Makefile.def: Sync with GCC.
+	* Makefile.in: Regenerate.
+
+2013-04-22  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
+
+	* configure.ac: Sync with GCC.
+	* configure: Regenerate.
+
 2013-03-22  Mike Frysinger  <vapier@gentoo.org>
 
 	* src-release (VER): Change bfd/configure.in sed to use the new
diff --git a/Makefile.def b/Makefile.def
index 1af7460..90d9653 100644
--- a/Makefile.def
+++ b/Makefile.def
@@ -138,7 +138,7 @@ target_modules = { module= libtermcap; no_check=true;
                    missing=maintainer-clean; };
 target_modules = { module= winsup; };
 target_modules = { module= libgloss; no_check=true; };
-target_modules = { module= libffi; };
+target_modules = { module= libffi; no_install=true; };
 target_modules = { module= libjava; raw_cxx=true;
                    extra_configure_flags="$(EXTRA_CONFIGARGS_LIBJAVA)"; };
 target_modules = { module= zlib; };
diff --git a/Makefile.in b/Makefile.in
index 08049de..bfbaf03 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -38710,13 +38710,8 @@ maybe-install-target-libffi:
 @if target-libffi
 maybe-install-target-libffi: install-target-libffi
 
-install-target-libffi: installdirs
-	@: $(MAKE); $(unstage)
-	@r=`${PWD_COMMAND}`; export r; \
-	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(NORMAL_TARGET_EXPORTS) \
-	(cd $(TARGET_SUBDIR)/libffi && \
-	  $(MAKE) $(TARGET_FLAGS_TO_PASS)  install)
+# Dummy target for uninstallable.
+install-target-libffi:
 
 @endif target-libffi
 
@@ -38725,13 +38720,8 @@ maybe-install-strip-target-libffi:
 @if target-libffi
 maybe-install-strip-target-libffi: install-strip-target-libffi
 
-install-strip-target-libffi: installdirs
-	@: $(MAKE); $(unstage)
-	@r=`${PWD_COMMAND}`; export r; \
-	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(NORMAL_TARGET_EXPORTS) \
-	(cd $(TARGET_SUBDIR)/libffi && \
-	  $(MAKE) $(TARGET_FLAGS_TO_PASS)  install-strip)
+# Dummy target for uninstallable.
+install-strip-target-libffi:
 
 @endif target-libffi
 
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 22cf440..0c62889 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,18 @@
+2013-04-22  Alan Modra  <amodra@gmail.com>
+
+	PR ld/15382
+	* elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Don't multiply
+	sh_size or reloc_count adjustment by count.
+
+2013-04-22  Alan Modra  <amodra@gmail.com>
+
+	* elf64-ppc.c (ppc64_elf_check_relocs): Don't call
+	create_linkage_sections here..
+	(ppc64_elf_init_stub_bfd): ..do so here.  Return status.
+	(create_linkage_sections): Move earlier in file.
+	(ppc64_elf_setup_section_lists): Remove now useless htab->brlt test.
+	* elf64-ppc.h (ppc64_elf_init_stub_bfd): Update proto.
+
 2013-04-19  Nick Clifton  <nickc@redhat.com>
 
 	PR binutils/15356
diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
index 3b4bd6f..b643dbc 100644
--- a/bfd/elf-bfd.h
+++ b/bfd/elf-bfd.h
@@ -2497,16 +2497,16 @@ extern asection _bfd_elf_large_com_section;
 	rel_hdr = _bfd_elf_single_rel_hdr (input_section->output_section); \
 									\
 	/* Avoid empty output section.  */				\
-	if (rel_hdr->sh_size > count * rel_hdr->sh_entsize)		\
+	if (rel_hdr->sh_size > rel_hdr->sh_entsize)			\
 	  {								\
-	    rel_hdr->sh_size -= count * rel_hdr->sh_entsize;		\
+	    rel_hdr->sh_size -= rel_hdr->sh_entsize;			\
 	    rel_hdr = _bfd_elf_single_rel_hdr (input_section);		\
-	    rel_hdr->sh_size -= count * rel_hdr->sh_entsize;		\
+	    rel_hdr->sh_size -= rel_hdr->sh_entsize;			\
 									\
 	    memmove (rel, rel + count,					\
 		     (relend - rel - count) * sizeof (*rel));		\
 									\
-	    input_section->reloc_count -= count;			\
+	    input_section->reloc_count--;				\
 	    relend -= count;						\
 	    rel--;							\
 	    continue;							\
diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
index e14bfb0..cb33821 100644
--- a/bfd/elf64-ppc.c
+++ b/bfd/elf64-ppc.c
@@ -4061,9 +4061,86 @@ ppc64_elf_link_hash_table_free (struct bfd_link_hash_table *hash)
   _bfd_elf_link_hash_table_free (hash);
 }
 
+/* Create sections for linker generated code.  */
+
+static bfd_boolean
+create_linkage_sections (bfd *dynobj, struct bfd_link_info *info)
+{
+  struct ppc_link_hash_table *htab;
+  flagword flags;
+
+  htab = ppc_hash_table (info);
+
+  /* Create .sfpr for code to save and restore fp regs.  */
+  flags = (SEC_ALLOC | SEC_LOAD | SEC_CODE | SEC_READONLY
+	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+  htab->sfpr = bfd_make_section_anyway_with_flags (dynobj, ".sfpr",
+						   flags);
+  if (htab->sfpr == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->sfpr, 2))
+    return FALSE;
+
+  /* Create .glink for lazy dynamic linking support.  */
+  htab->glink = bfd_make_section_anyway_with_flags (dynobj, ".glink",
+						    flags);
+  if (htab->glink == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->glink, 3))
+    return FALSE;
+
+  if (!info->no_ld_generated_unwind_info)
+    {
+      flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_HAS_CONTENTS
+	       | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+      htab->glink_eh_frame = bfd_make_section_anyway_with_flags (dynobj,
+								 ".eh_frame",
+								 flags);
+      if (htab->glink_eh_frame == NULL
+	  || !bfd_set_section_alignment (dynobj, htab->glink_eh_frame, 2))
+	return FALSE;
+    }
+
+  flags = SEC_ALLOC | SEC_LINKER_CREATED;
+  htab->iplt = bfd_make_section_anyway_with_flags (dynobj, ".iplt", flags);
+  if (htab->iplt == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->iplt, 3))
+    return FALSE;
+
+  flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
+	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+  htab->reliplt = bfd_make_section_anyway_with_flags (dynobj,
+						      ".rela.iplt",
+						      flags);
+  if (htab->reliplt == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->reliplt, 3))
+    return FALSE;
+
+  /* Create branch lookup table for plt_branch stubs.  */
+  flags = (SEC_ALLOC | SEC_LOAD
+	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+  htab->brlt = bfd_make_section_anyway_with_flags (dynobj, ".branch_lt",
+						   flags);
+  if (htab->brlt == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->brlt, 3))
+    return FALSE;
+
+  if (!info->shared)
+    return TRUE;
+
+  flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
+	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+  htab->relbrlt = bfd_make_section_anyway_with_flags (dynobj,
+						      ".rela.branch_lt",
+						      flags);
+  if (htab->relbrlt == NULL
+      || ! bfd_set_section_alignment (dynobj, htab->relbrlt, 3))
+    return FALSE;
+
+  return TRUE;
+}
+
 /* Satisfy the ELF linker by filling in some fields in our fake bfd.  */
 
-void
+bfd_boolean
 ppc64_elf_init_stub_bfd (bfd *abfd, struct bfd_link_info *info)
 {
   struct ppc_link_hash_table *htab;
@@ -4075,9 +4152,14 @@ ppc64_elf_init_stub_bfd (bfd *abfd, struct bfd_link_info *info)
    the start of the output TOC section.  */
   htab = ppc_hash_table (info);
   if (htab == NULL)
-    return;
+    return FALSE;
   htab->stub_bfd = abfd;
   htab->elf.dynobj = abfd;
+
+  if (info->relocatable)
+    return TRUE;
+
+  return create_linkage_sections (htab->elf.dynobj, info);
 }
 
 /* Build a name for an entry in the stub hash table.  */
@@ -4227,85 +4309,6 @@ ppc_add_stub (const char *stub_name,
   return stub_entry;
 }
 
-/* Create sections for linker generated code.  */
-
-static bfd_boolean
-create_linkage_sections (bfd *dynobj, struct bfd_link_info *info)
-{
-  struct ppc_link_hash_table *htab;
-  flagword flags;
-
-  htab = ppc_hash_table (info);
-  if (htab == NULL)
-    return FALSE;
-
-  /* Create .sfpr for code to save and restore fp regs.  */
-  flags = (SEC_ALLOC | SEC_LOAD | SEC_CODE | SEC_READONLY
-	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-  htab->sfpr = bfd_make_section_anyway_with_flags (dynobj, ".sfpr",
-						   flags);
-  if (htab->sfpr == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->sfpr, 2))
-    return FALSE;
-
-  /* Create .glink for lazy dynamic linking support.  */
-  htab->glink = bfd_make_section_anyway_with_flags (dynobj, ".glink",
-						    flags);
-  if (htab->glink == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->glink, 3))
-    return FALSE;
-
-  if (!info->no_ld_generated_unwind_info)
-    {
-      flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_HAS_CONTENTS
-	       | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-      htab->glink_eh_frame = bfd_make_section_anyway_with_flags (dynobj,
-								 ".eh_frame",
-								 flags);
-      if (htab->glink_eh_frame == NULL
-	  || !bfd_set_section_alignment (dynobj, htab->glink_eh_frame, 2))
-	return FALSE;
-    }
-
-  flags = SEC_ALLOC | SEC_LINKER_CREATED;
-  htab->iplt = bfd_make_section_anyway_with_flags (dynobj, ".iplt", flags);
-  if (htab->iplt == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->iplt, 3))
-    return FALSE;
-
-  flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
-	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-  htab->reliplt = bfd_make_section_anyway_with_flags (dynobj,
-						      ".rela.iplt",
-						      flags);
-  if (htab->reliplt == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->reliplt, 3))
-    return FALSE;
-
-  /* Create branch lookup table for plt_branch stubs.  */
-  flags = (SEC_ALLOC | SEC_LOAD
-	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-  htab->brlt = bfd_make_section_anyway_with_flags (dynobj, ".branch_lt",
-						   flags);
-  if (htab->brlt == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->brlt, 3))
-    return FALSE;
-
-  if (!info->shared)
-    return TRUE;
-
-  flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
-	   | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-  htab->relbrlt = bfd_make_section_anyway_with_flags (dynobj,
-						      ".rela.branch_lt",
-						      flags);
-  if (htab->relbrlt == NULL
-      || ! bfd_set_section_alignment (dynobj, htab->relbrlt, 3))
-    return FALSE;
-
-  return TRUE;
-}
-
 /* Create .got and .rela.got sections in ABFD, and .got in dynobj if
    not already done.  */
 
@@ -4983,10 +4986,6 @@ ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
       ppc64_elf_section_data (sec)->sec_type = sec_opd;
     }
 
-  if (htab->sfpr == NULL
-      && !create_linkage_sections (htab->elf.dynobj, info))
-    return FALSE;
-
   rel_end = relocs + sec->reloc_count;
   for (rel = relocs; rel < rel_end; rel++)
     {
@@ -10547,9 +10546,6 @@ ppc64_elf_setup_section_lists
   htab->add_stub_section = add_stub_section;
   htab->layout_sections_again = layout_sections_again;
 
-  if (htab->brlt == NULL)
-    return 0;
-
   /* Find the top input section id.  */
   for (input_bfd = info->input_bfds, top_id = 3;
        input_bfd != NULL;
diff --git a/bfd/elf64-ppc.h b/bfd/elf64-ppc.h
index 2728b27..89495bc 100644
--- a/bfd/elf64-ppc.h
+++ b/bfd/elf64-ppc.h
@@ -19,7 +19,7 @@
    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
-void ppc64_elf_init_stub_bfd
+bfd_boolean ppc64_elf_init_stub_bfd
   (bfd *, struct bfd_link_info *);
 bfd_boolean ppc64_elf_edit_opd
   (struct bfd_link_info *, bfd_boolean);
diff --git a/bfd/version.h b/bfd/version.h
index 33424d9..8d7d489 100644
--- a/bfd/version.h
+++ b/bfd/version.h
@@ -1,4 +1,4 @@
-#define BFD_VERSION_DATE 20130421
+#define BFD_VERSION_DATE 20130422
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING  @bfd_version_package@ @bfd_version_string@
 #define REPORT_BUGS_TO @report_bugs_to@
diff --git a/configure b/configure
index d809535..e161cad 100755
--- a/configure
+++ b/configure
@@ -3272,6 +3272,8 @@ esac
 
 # Disable Java if libffi is not supported.
 case "${target}" in
+  aarch64-*-*)
+    ;;
   alpha*-*-*)
     ;;
   arm*-*-*)
diff --git a/configure.ac b/configure.ac
index 48ec1aa..bec489f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -611,6 +611,8 @@ esac
 
 # Disable Java if libffi is not supported.
 case "${target}" in
+  aarch64-*-*)
+    ;;
   alpha*-*-*)
     ;;
   arm*-*-*)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index e553b41..17cdc7b 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,72 @@
+2013-04-22  Tom Tromey  <tromey@redhat.com>
+
+	PR gdb/7912:
+	* Makefile.in (SFILES): Add filestuff.c
+	(COMMON_OBS): Add filestuff.o.
+	(filestuff.o): New target.
+	* auto-load.c (auto_load_objfile_script_1): Use
+	gdb_fopen_cloexec.
+	* auxv.c (procfs_xfer_auxv): Use gdb_open_cloexec.
+	* cli/cli-cmds.c (shell_escape): Call close_most_fds.
+	* cli/cli-dump.c (fopen_with_cleanup): Use gdb_fopen_cloexec.
+	* common/agent.c (gdb_connect_sync_socket): Use
+	gdb_socket_cloexec.
+	* common/filestuff.c: New file.
+	* common/filestuff.h: New file.
+	* common/linux-osdata.c (linux_common_core_of_thread)
+	(command_from_pid, commandline_from_pid, print_source_lines)
+	(linux_xfer_osdata_shm, linux_xfer_osdata_sem)
+	(linux_xfer_osdata_msg, linux_xfer_osdata_modules): Use
+	gdb_fopen_cloexec.
+	* common/linux-procfs.c (linux_proc_get_int)
+	(linux_proc_pid_has_state): Use gdb_fopen_cloexec.
+	* config.in, configure: Rebuild.
+	* configure.ac: Don't check for sys/socket.h.  Check for
+	fdwalk, pipe2.
+	* corelow.c (core_open): Use gdb_open_cloexec.
+	* dwarf2read.c (write_psymtabs_to_index): Use gdb_fopen_cloexec.
+	* fork-child.c (fork_inferior): Call close_most_fds.
+	* gdb_bfd.c (gdb_bfd_open): Use gdb_open_cloexec.
+	* inf-child.c (inf_child_fileio_readlink): Use gdb_open_cloexec.
+	* linux-nat.c (linux_nat_thread_name, linux_proc_pending_signals):
+	Use gdb_fopen_cloexec.
+	(linux_proc_xfer_partial, linux_proc_xfer_spu): Use
+	gdb_open_cloexec.
+	(linux_async_pipe): Use gdb_pipe_cloexec.
+	* remote-fileio.c (remote_fileio_func_open): Use
+	gdb_open_cloexec.
+	* remote.c (remote_file_put, remote_file_get): Use
+	gdb_fopen_cloexec.
+	* ser-pipe.c (pipe_open): Use gdb_socketpair_cloexec,
+	close_most_fds.
+	* ser-tcp.c (net_open): Use gdb_socket_cloexec.
+	* ser-unix.c (hardwire_open): Use gdb_open_cloexec.
+	* solib.c (solib_find): Use gdb_open_cloexec.
+	* source.c (openp, find_and_open_source): Use gdb_open_cloexec.
+	* tracepoint.c (tfile_start): Use gdb_fopen_cloexec.
+	(tfile_open): Use gdb_open_cloexec.
+	* tui/tui-io.c (tui_initialize_io): Use gdb_pipe_cloexec.
+	* ui-file.c (gdb_fopen): Use gdb_fopen_cloexec.
+	* xml-support.c (xml_fetch_content_from_file): Use
+	gdb_fopen_cloexec.
+	* main.c (captured_main): Call notice_open_fds.
+
+2013-04-22  Edjunior Machado  <emachado@linux.vnet.ibm.com>
+
+	* remote-sim.c (dump_mem): Change the type of 'buf' parameter from
+	'char *' to 'gdb_byte *'.
+	(gdbsim_store_register): Change the type of 'tmp' from 'char' to
+	'gdb_byte'.
+
+2013-04-22  Yao Qi  <yao@codesourcery.com>
+
+	* infrun.c: Fix typo in comment.
+
+2013-04-22  Andrew Haley  <aph@redhat.com>
+
+	* arm-tdep.c (BranchDest): Cast result as "unsigned long",
+	instead of "long".
+
 2013-04-20  Yao Qi  <yao@codesourcery.com>
 
 	* ctf.c (ctf_fetch_registers): Change the type of 'regs' from
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 064eb21..f49580e 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -767,7 +767,7 @@ SFILES = ada-exp.y ada-lang.c ada-typeprint.c ada-valprint.c ada-tasks.c \
 	regset.c sol-thread.c windows-termcap.c \
 	common/gdb_vecs.c common/common-utils.c common/xml-utils.c \
 	common/ptid.c common/buffer.c gdb-dlfcn.c common/agent.c \
-	common/format.c btrace.c record-btrace.c ctf.c
+	common/format.c common/filestuff.c btrace.c record-btrace.c ctf.c
 
 LINTFILES = $(SFILES) $(YYFILES) $(CONFIG_SRCS) init.c
 
@@ -890,6 +890,7 @@ COMMON_OBS = $(DEPFILES) $(CONFIG_OBS) $(YYOBJ) \
 	expprint.o environ.o stack.o thread.o \
 	exceptions.o \
 	filesystem.o \
+	filestuff.o \
 	inf-child.o \
 	interps.o \
 	minidebug.o \
@@ -1969,6 +1970,10 @@ buffer.o: ${srcdir}/common/buffer.c
 	$(COMPILE) $(srcdir)/common/buffer.c
 	$(POSTCOMPILE)
 
+filestuff.o: $(srcdir)/common/filestuff.c
+	$(COMPILE) $(srcdir)/common/filestuff.c
+	$(POSTCOMPILE)
+
 format.o: ${srcdir}/common/format.c
 	$(COMPILE) $(srcdir)/common/format.c
 	$(POSTCOMPILE)
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index e353717..b169e35 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -521,7 +521,7 @@ skip_prologue_function (struct gdbarch *gdbarch, CORE_ADDR pc, int is_thumb)
 #define sbits(obj,st,fn) \
   ((long) (bits(obj,st,fn) | ((long) bit(obj,fn) * ~ submask (fn - st))))
 #define BranchDest(addr,instr) \
-  ((CORE_ADDR) (((long) (addr)) + 8 + (sbits (instr, 0, 23) << 2)))
+  ((CORE_ADDR) (((unsigned long) (addr)) + 8 + (sbits (instr, 0, 23) << 2)))
 
 /* Extract the immediate from instruction movw/movt of encoding T.  INSN1 is


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [SCM]  jankratochvil/ipv6: .
@ 2013-04-19 18:43 jkratoch
  0 siblings, 0 replies; 4+ messages in thread
From: jkratoch @ 2013-04-19 18:43 UTC (permalink / raw)
  To: archer-commits

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 27502 bytes --]

The branch, jankratochvil/ipv6 has been updated
       via  f4ed32f7fd2b27bddf234e6d3aaf3ea750ff83e9 (commit)
       via  7e497cf332ab0441cc5e125f6486ac3b0b316e0c (commit)
       via  92f48e3bed5e514b521220c617e39dc60f39d9bd (commit)
       via  11b8741a63aabf4084886bc1fe3cd84bddb69178 (commit)
       via  06ca7cbd307a24826d15fff62976f8bdb8042a3d (commit)
       via  40c0a732cad62e610fba683ddaed5336e791071b (commit)
       via  3ae95b7562c6284affc4be6db4f35e43ef4f5a61 (commit)
       via  36f5c10b9306d35ad1c930929d39173571fe6694 (commit)
       via  23eb3c9e3e8e6cbe022256ea9191bc8a41a68f00 (commit)
       via  ee53c7e070d50b8336c887caccf4b40a46d3f2a8 (commit)
       via  bd146418ef532becb8eccdc569ac0d97551a3c7d (commit)
       via  7e03aaaae0f02f7f30df84e8c4ab6337d16d6da0 (commit)
       via  407e00fbe7220947ac5adce32571b42bf0c8a771 (commit)
       via  4c08504c445d01a32ffcaddc77caedf1bdfe24af (commit)
       via  5c18d6292bce5dfe11dfff38779213e66ede5735 (commit)
       via  165c7559e9a42194dd2527d8e9e5733e31d5c57c (commit)
       via  e8e5c1d74d0ba4fb17ff9bd580d4714f3a0edeb2 (commit)
       via  74d7e164d1e9d6ff1fd7c1acf675e3589098fa81 (commit)
       via  7a9088e93d91fb5f872465cb6238fe346f68911a (commit)
       via  8971f489b0f0e28e401c18844d6c679ffb9b6f6e (commit)
       via  daebb5ec91791a8a577a02c5f5857d5810de684d (commit)
      from  7acca69ed542d68fbb22875da31678441894c6c9 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit f4ed32f7fd2b27bddf234e6d3aaf3ea750ff83e9
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:27:03 2013 +0200

    .

commit 7e497cf332ab0441cc5e125f6486ac3b0b316e0c
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:26:23 2013 +0200

    .

commit 92f48e3bed5e514b521220c617e39dc60f39d9bd
Merge: 06ca7cb 11b8741
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:19:35 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus' into gnulibupdate-gnulibplus-ipv6

commit 11b8741a63aabf4084886bc1fe3cd84bddb69178
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:19:30 2013 +0200

    .

commit 06ca7cbd307a24826d15fff62976f8bdb8042a3d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:14:36 2013 +0200

    .

commit 40c0a732cad62e610fba683ddaed5336e791071b
Merge: 36f5c10 3ae95b7
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:14:30 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus' into gnulibupdate-gnulibplus-ipv6

commit 3ae95b7562c6284affc4be6db4f35e43ef4f5a61
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 20:14:23 2013 +0200

    .

commit 36f5c10b9306d35ad1c930929d39173571fe6694
Merge: ee53c7e 23eb3c9
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 18:03:14 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus' into gnulibupdate-gnulibplus-ipv6

commit 23eb3c9e3e8e6cbe022256ea9191bc8a41a68f00
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 18:03:04 2013 +0200

    .

commit ee53c7e070d50b8336c887caccf4b40a46d3f2a8
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 18:00:33 2013 +0200

    Revert "."
    
    This reverts commit bd146418ef532becb8eccdc569ac0d97551a3c7d.

commit bd146418ef532becb8eccdc569ac0d97551a3c7d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:57:56 2013 +0200

    .

commit 7e03aaaae0f02f7f30df84e8c4ab6337d16d6da0
Merge: 4c08504 407e00f
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:54:28 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus' into gnulibupdate-gnulibplus-ipv6

commit 407e00fbe7220947ac5adce32571b42bf0c8a771
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:54:22 2013 +0200

    .

commit 4c08504c445d01a32ffcaddc77caedf1bdfe24af
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:47:26 2013 +0200

    .

commit 5c18d6292bce5dfe11dfff38779213e66ede5735
Merge: 7acca69 165c755
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:08:05 2013 +0200

    Merge branch 'gnulibupdate-gnulibplus' into gnulibupdate-gnulibplus-ipv6

commit 165c7559e9a42194dd2527d8e9e5733e31d5c57c
Merge: 48ad00a e8e5c1d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:08:01 2013 +0200

    Merge branch 'gnulibupdate' into gnulibupdate-gnulibplus

commit e8e5c1d74d0ba4fb17ff9bd580d4714f3a0edeb2
Merge: d353efe 74d7e16
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Apr 19 17:07:58 2013 +0200

    Merge remote-tracking branch 'gdb/master' into gnulibupdate

commit 74d7e164d1e9d6ff1fd7c1acf675e3589098fa81
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Apr 19 14:13:29 2013 +0000

    Fix the x87 FP register printout when issuing the “info float” command.
    
    Consider the following simple program:
    
    .globl  _start
    .text
    _start:
          fldt    val
    .data
          val: .byte 0x00,0x00,0x45,0x07,0x11,0x19,0x22,0xe9,0xfe,0xbf
    
    With current GDB on x86-64 GNU/Linux hosts, after the moment the fldt
    command has been executed the register st(0) looks like this,
    according to the “info regs” output (TOP=7):
    
      R7: Valid   0xffffffbffffffffeffffffe922191107450000 -0.910676542908976927
    
    which is clearly wrong (just count its length).  The problem is due to
    the printf statement (see patch) printing a promoted integer value of
    a char argument "raw[i]", and, since char is signed on x86-64
    GNU/Linux, the erroneous “ffffff” are printed for the first three
    bytes which turn out to be "negative".  The fix is to use gdb_byte
    instead which is unsigned (and is the type of value_contents(), the
    type to be used for raw target bytes anyway).  After the fix the value
    will be printed correctly:
    
      R7: Valid   0xbffee922191107450000 -0.910676542908976927
    
    gdb/
    2013-04-19  Vladimir Kargov <kargov@gmail.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* i387-tdep.c (i387_print_float_info): Use gdb_byte for pointer to
    	value contents.
    
    gdb/testsuite/
    2013-04-19  Vladimir Kargov  <kargov@gmail.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.arch/i386-float.S: New file.
    	* gdb.arch/i386-float.exp: New file.

-----------------------------------------------------------------------

Summary of changes:
 bfd/ChangeLog                         |    6 +
 bfd/version.h                         |    2 +-
 gdb/ChangeLog                         |    6 +
 gdb/config.in                         |    3 +
 gdb/configure                         |    2 +-
 gdb/configure.ac                      |    2 +-
 gdb/gdbserver/Makefile.in             |    2 +-
 gdb/gdbserver/config.in               |    3 +
 gdb/gdbserver/configure               |    2 +-
 gdb/gdbserver/configure.ac            |    4 +-
 gdb/gdbserver/gdbreplay.c             |   11 +-
 gdb/gdbserver/remote-utils.c          |   14 +-
 gdb/gnulib/Makefile.in                |    6 +
 gdb/gnulib/aclocal.m4                 |    6 +
 gdb/gnulib/config.in                  |   87 +
 gdb/gnulib/configure                  | 3585 +++++++++++++++++++++++++--------
 gdb/gnulib/import/Makefile.am         |  211 ++-
 gdb/gnulib/import/Makefile.in         |  190 ++-
 gdb/gnulib/import/accept.c            |   52 +
 gdb/gnulib/import/bind.c              |   49 +
 gdb/gnulib/import/close.c             |   69 +
 gdb/gnulib/import/dup2.c              |  160 ++
 gdb/gnulib/import/getsockname.c       |   49 +
 gdb/gnulib/import/listen.c            |   49 +
 gdb/gnulib/import/m4/close.m4         |   33 +
 gdb/gnulib/import/m4/dup2.m4          |   84 +
 gdb/gnulib/import/m4/gnulib-cache.m4  |   13 +-
 gdb/gnulib/import/m4/gnulib-comp.m4   |  104 +
 gdb/gnulib/import/m4/select.m4        |  113 ++
 gdb/gnulib/import/m4/signal_h.m4      |   83 +
 gdb/gnulib/import/m4/sys_select_h.m4  |   95 +
 gdb/gnulib/import/m4/sys_time_h.m4    |  110 +
 gdb/gnulib/import/recv.c              |   49 +
 gdb/gnulib/import/select.c            |  547 +++++
 gdb/gnulib/import/send.c              |   49 +
 gdb/gnulib/import/setsockopt.c        |   65 +
 gdb/gnulib/import/signal.in.h         |  447 ++++
 gdb/gnulib/import/socket.c            |   49 +
 gdb/gnulib/import/sys_select.in.h     |  313 +++
 gdb/gnulib/import/sys_time.in.h       |  212 ++
 gdb/gnulib/update-gnulib.sh           |    5 +-
 gdb/i387-tdep.c                       |    2 +-
 gdb/ser-tcp.c                         |    6 +-
 gdb/testsuite/ChangeLog               |    6 +
 gdb/testsuite/gdb.arch/i386-float.S   |   34 +
 gdb/testsuite/gdb.arch/i386-float.exp |   43 +
 gdb/utils.c                           |    3 +
 gdb/version.in                        |    2 +-
 48 files changed, 6135 insertions(+), 902 deletions(-)
 create mode 100644 gdb/gnulib/import/accept.c
 create mode 100644 gdb/gnulib/import/bind.c
 create mode 100644 gdb/gnulib/import/close.c
 create mode 100644 gdb/gnulib/import/dup2.c
 create mode 100644 gdb/gnulib/import/getsockname.c
 create mode 100644 gdb/gnulib/import/listen.c
 create mode 100644 gdb/gnulib/import/m4/close.m4
 create mode 100644 gdb/gnulib/import/m4/dup2.m4
 create mode 100644 gdb/gnulib/import/m4/select.m4
 create mode 100644 gdb/gnulib/import/m4/signal_h.m4
 create mode 100644 gdb/gnulib/import/m4/sys_select_h.m4
 create mode 100644 gdb/gnulib/import/m4/sys_time_h.m4
 create mode 100644 gdb/gnulib/import/recv.c
 create mode 100644 gdb/gnulib/import/select.c
 create mode 100644 gdb/gnulib/import/send.c
 create mode 100644 gdb/gnulib/import/setsockopt.c
 create mode 100644 gdb/gnulib/import/signal.in.h
 create mode 100644 gdb/gnulib/import/socket.c
 create mode 100644 gdb/gnulib/import/sys_select.in.h
 create mode 100644 gdb/gnulib/import/sys_time.in.h
 create mode 100644 gdb/testsuite/gdb.arch/i386-float.S
 create mode 100644 gdb/testsuite/gdb.arch/i386-float.exp

First 500 lines of diff:
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index be6dd52..22cf440 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2013-04-19  Nick Clifton  <nickc@redhat.com>
+
+	PR binutils/15356
+	* compress.c (decompress_contents): Always call inflateEnd, even
+	when another inflation operation fails.
+
 2013-04-17  H.J. Lu  <hongjiu.lu@intel.com>
 
 	* elf-ifunc.c: Update copyright year.
diff --git a/bfd/version.h b/bfd/version.h
index a1afd19..e5462d7 100644
--- a/bfd/version.h
+++ b/bfd/version.h
@@ -1,4 +1,4 @@
-#define BFD_VERSION_DATE 20130418
+#define BFD_VERSION_DATE 20130419
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING  @bfd_version_package@ @bfd_version_string@
 #define REPORT_BUGS_TO @report_bugs_to@
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 85c3245..80fb6de 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,9 @@
+2013-04-19  Vladimir Kargov <kargov@gmail.com>
+	    Pedro Alves  <palves@redhat.com>
+
+	* i387-tdep.c (i387_print_float_info): Use gdb_byte for pointer to
+	value contents.
+
 2013-04-17  Doug Evans  <dje@google.com>
 
 	* dwarf2read.c (struct signatured_type): New member type.
diff --git a/gdb/config.in b/gdb/config.in
index fa2220e..18c7b92 100644
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -572,6 +572,9 @@
 /* Define to 1 if you have the `wresize' function. */
 #undef HAVE_WRESIZE
 
+/* Define to 1 if you have the <ws2tcpip.h> header file. */
+#undef HAVE_WS2TCPIP_H
+
 /* Define to 1 if you have the `XML_StopParser' function. */
 #undef HAVE_XML_STOPPARSER
 
diff --git a/gdb/configure b/gdb/configure
index f9d9a17..c0a1812 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -8912,7 +8912,7 @@ for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
 		  sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
 		  sys/types.h sys/wait.h wait.h termios.h termio.h \
 		  sgtty.h unistd.h elf_hp.h locale.h \
-		  dlfcn.h sys/socket.h sys/un.h linux/perf_event.h
+		  dlfcn.h sys/socket.h ws2tcpip.h sys/un.h linux/perf_event.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/configure.ac b/gdb/configure.ac
index ce6fa7a..97f1420 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -1090,7 +1090,7 @@ AC_CHECK_HEADERS([nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
 		  sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
 		  sys/types.h sys/wait.h wait.h termios.h termio.h \
 		  sgtty.h unistd.h elf_hp.h locale.h \
-		  dlfcn.h sys/socket.h sys/un.h linux/perf_event.h])
+		  dlfcn.h sys/socket.h ws2tcpip.h sys/un.h linux/perf_event.h])
 AC_CHECK_HEADERS(link.h, [], [],
 [#if HAVE_SYS_TYPES_H
 # include <sys/types.h>
diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in
index faa0098..b10397e 100644
--- a/gdb/gdbserver/Makefile.in
+++ b/gdb/gdbserver/Makefile.in
@@ -283,7 +283,7 @@ all-lib: $(GNULIB_BUILDDIR)/Makefile
 gdbreplay$(EXEEXT): $(GDBREPLAY_OBS)
 	rm -f gdbreplay$(EXEEXT)
 	${CC-LD} $(INTERNAL_CFLAGS) $(INTERNAL_LDFLAGS) -o gdbreplay$(EXEEXT) $(GDBREPLAY_OBS) \
-	  $(XM_CLIBS)
+	  $(LIBGNU) $(XM_CLIBS)
 
 IPA_OBJS=ax-ipa.o tracepoint-ipa.o format-ipa.o utils-ipa.o regcache-ipa.o remote-utils-ipa.o common-utils-ipa.o ${IPA_DEPFILES}
 
diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in
index 35a836d..77e75e2 100644
--- a/gdb/gdbserver/config.in
+++ b/gdb/gdbserver/config.in
@@ -226,6 +226,9 @@
 /* Define to 1 if you have the <wait.h> header file. */
 #undef HAVE_WAIT_H
 
+/* Define to 1 if you have the <ws2tcpip.h> header file. */
+#undef HAVE_WS2TCPIP_H
+
 /* Checking if errno must be defined */
 #undef MUST_DEFINE_ERRNO
 
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
index 5a56183..6fea6ae 100755
--- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure
@@ -4781,7 +4781,7 @@ $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cach
   cd "$ac_popdir"
 
 
-for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h thread_db.h linux/elf.h 		 stdlib.h unistd.h 		 errno.h fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h 		 netinet/tcp.h arpa/inet.h sys/wait.h wait.h sys/un.h 		 linux/perf_event.h
+for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h thread_db.h linux/elf.h 		 stdlib.h unistd.h 		 errno.h fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h ws2tcpip.h netdb.h 		 netinet/tcp.h arpa/inet.h sys/wait.h wait.h sys/un.h 		 linux/perf_event.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
index fdd8918..0a5fccd 100644
--- a/gdb/gdbserver/configure.ac
+++ b/gdb/gdbserver/configure.ac
@@ -67,8 +67,8 @@ AC_CHECK_HEADERS(sgtty.h termio.h termios.h sys/reg.h string.h dnl
 		 proc_service.h sys/procfs.h thread_db.h linux/elf.h dnl
 		 stdlib.h unistd.h dnl
 		 errno.h fcntl.h signal.h sys/file.h malloc.h dnl
-		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h dnl
-		 netinet/tcp.h arpa/inet.h sys/wait.h wait.h sys/un.h dnl
+		 sys/ioctl.h netinet/in.h sys/socket.h ws2tcpip.h netdb.h dnl
+		 netinet/tcp.h sys/wait.h wait.h sys/un.h dnl
 		 linux/perf_event.h)
 AC_CHECK_FUNCS(pread pwrite pread64 readlink)
 AC_REPLACE_FUNCS(vasprintf vsnprintf)
diff --git a/gdb/gdbserver/gdbreplay.c b/gdb/gdbserver/gdbreplay.c
index 1cd0ebe..18dd360 100644
--- a/gdb/gdbserver/gdbreplay.c
+++ b/gdb/gdbserver/gdbreplay.c
@@ -64,6 +64,9 @@
 #if USE_WIN32API
 #include <winsock2.h>
 #endif
+#ifdef HAVE_WS2TCPIP_H
+#include <ws2tcpip.h>
+#endif
 
 #ifndef HAVE_SOCKLEN_T
 typedef int socklen_t;
@@ -205,7 +208,7 @@ bind_socket (struct addrinfo *addrinfo_base, int family)
 
       /* Allow rapid reuse of this port. */
       i = 1;
-      setsockopt (fd, SOL_SOCKET, SO_REUSEADDR, &i, sizeof (i));
+      setsockopt (fd, SOL_SOCKET, SO_REUSEADDR, (const void *) &i, sizeof (i));
 
       if (bind (fd, addrinfo->ai_addr, addrinfo->ai_addrlen) == 0
 	  && listen (fd, 1) == 0)
@@ -290,12 +293,14 @@ remote_open (char *name)
 
   /* Enable TCP keep alive process. */
   i = 1;
-  setsockopt (tmp_desc, SOL_SOCKET, SO_KEEPALIVE, &i, sizeof (i));
+  setsockopt (tmp_desc, SOL_SOCKET, SO_KEEPALIVE, (const void *) &i,
+	      sizeof (i));
 
   /* Tell TCP not to delay small packets.  This greatly speeds up
      interactive response. */
   i = 1;
-  setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY, &i, sizeof (i));
+  setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY, (const void *) &i,
+              sizeof (i));
 
 #ifndef USE_WIN32API
   close (tmp_desc);		/* No longer need this */
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index e018f91..7ff5725 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -53,9 +53,8 @@
 #if HAVE_UNISTD_H
 #include <unistd.h>
 #endif
-#if HAVE_ARPA_INET_H
 #include <arpa/inet.h>
-#endif
+#include <sys/select.h>
 #include "gdb_stat.h"
 #if HAVE_ERRNO_H
 #include <errno.h>
@@ -64,6 +63,9 @@
 #if USE_WIN32API
 #include <winsock2.h>
 #endif
+#ifdef HAVE_WS2TCPIP_H
+#include <ws2tcpip.h>
+#endif
 
 #if __QNX__
 #include <sys/iomgr.h>
@@ -172,12 +174,14 @@ handle_accept_event (int err, gdb_client_data client_data)
 
   /* Enable TCP keep alive process. */
   i = 1;
-  setsockopt (remote_desc, SOL_SOCKET, SO_KEEPALIVE, &i, sizeof (i));
+  setsockopt (remote_desc, SOL_SOCKET, SO_KEEPALIVE, (const void *) &i,
+	      sizeof (i));
 
   /* Tell TCP not to delay small packets.  This greatly speeds up
      interactive response. */
   i = 1;
-  setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY, &i, sizeof (i));
+  setsockopt (remote_desc, IPPROTO_TCP, TCP_NODELAY, (const void *) &i,
+	      sizeof (i));
 
 #ifndef USE_WIN32API
   signal (SIGPIPE, SIG_IGN);	/* If we don't do this, then gdbserver simply
@@ -257,7 +261,7 @@ bind_socket (struct addrinfo *addrinfo_base, int family)
 
       /* Allow rapid reuse of this port. */
       i = 1;
-      setsockopt (fd, SOL_SOCKET, SO_REUSEADDR, &i, sizeof (i));
+      setsockopt (fd, SOL_SOCKET, SO_REUSEADDR, (const void *) &i, sizeof (i));
 
       if (bind (fd, addrinfo->ai_addr, addrinfo->ai_addrlen) == 0
 	  && listen (fd, 1) == 0)
diff --git a/gdb/gnulib/Makefile.in b/gdb/gnulib/Makefile.in
index 804727b..97004c1 100644
--- a/gdb/gnulib/Makefile.in
+++ b/gdb/gnulib/Makefile.in
@@ -210,8 +210,10 @@ aclocal_m4_deps = \
 	import/m4/00gnulib.m4 \
 	import/m4/alloca.m4 \
 	import/m4/arpa_inet_h.m4 \
+	import/m4/close.m4 \
 	import/m4/codeset.m4 \
 	import/m4/configmake.m4 \
+	import/m4/dup2.m4 \
 	import/m4/errno_h.m4 \
 	import/m4/exponentd.m4 \
 	import/m4/extensions.m4 \
@@ -254,7 +256,9 @@ aclocal_m4_deps = \
 	import/m4/off_t.m4 \
 	import/m4/onceonly.m4 \
 	import/m4/printf.m4 \
+	import/m4/select.m4 \
 	import/m4/servent.m4 \
+	import/m4/signal_h.m4 \
 	import/m4/size_max.m4 \
 	import/m4/snprintf.m4 \
 	import/m4/socketlib.m4 \
@@ -269,7 +273,9 @@ aclocal_m4_deps = \
 	import/m4/stdint_h.m4 \
 	import/m4/stdio_h.m4 \
 	import/m4/string_h.m4 \
+	import/m4/sys_select_h.m4 \
 	import/m4/sys_socket_h.m4 \
+	import/m4/sys_time_h.m4 \
 	import/m4/sys_types_h.m4 \
 	import/m4/sys_uio_h.m4 \
 	import/m4/unistd_h.m4 \
diff --git a/gdb/gnulib/aclocal.m4 b/gdb/gnulib/aclocal.m4
index 5a2fdf1..dc183e7 100644
--- a/gdb/gnulib/aclocal.m4
+++ b/gdb/gnulib/aclocal.m4
@@ -1015,8 +1015,10 @@ AC_SUBST([am__untar])
 m4_include([import/m4/00gnulib.m4])
 m4_include([import/m4/alloca.m4])
 m4_include([import/m4/arpa_inet_h.m4])
+m4_include([import/m4/close.m4])
 m4_include([import/m4/codeset.m4])
 m4_include([import/m4/configmake.m4])
+m4_include([import/m4/dup2.m4])
 m4_include([import/m4/errno_h.m4])
 m4_include([import/m4/exponentd.m4])
 m4_include([import/m4/extensions.m4])
@@ -1056,7 +1058,9 @@ m4_include([import/m4/netinet_in_h.m4])
 m4_include([import/m4/off_t.m4])
 m4_include([import/m4/onceonly.m4])
 m4_include([import/m4/printf.m4])
+m4_include([import/m4/select.m4])
 m4_include([import/m4/servent.m4])
+m4_include([import/m4/signal_h.m4])
 m4_include([import/m4/size_max.m4])
 m4_include([import/m4/snprintf.m4])
 m4_include([import/m4/socketlib.m4])
@@ -1071,7 +1075,9 @@ m4_include([import/m4/stdint.m4])
 m4_include([import/m4/stdint_h.m4])
 m4_include([import/m4/stdio_h.m4])
 m4_include([import/m4/string_h.m4])
+m4_include([import/m4/sys_select_h.m4])
 m4_include([import/m4/sys_socket_h.m4])
+m4_include([import/m4/sys_time_h.m4])
 m4_include([import/m4/sys_types_h.m4])
 m4_include([import/m4/sys_uio_h.m4])
 m4_include([import/m4/unistd_h.m4])
diff --git a/gdb/gnulib/config.in b/gdb/gnulib/config.in
index 73d4fe7..6d61c3c 100644
--- a/gdb/gnulib/config.in
+++ b/gdb/gnulib/config.in
@@ -45,9 +45,27 @@
    whether the gnulib module snprintf shall be considered present. */
 #undef GNULIB_SNPRINTF
 
+/* Define to 1 when the gnulib module accept should be tested. */
+#undef GNULIB_TEST_ACCEPT
+
+/* Define to 1 when the gnulib module bind should be tested. */
+#undef GNULIB_TEST_BIND
+
+/* Define to 1 when the gnulib module close should be tested. */
+#undef GNULIB_TEST_CLOSE
+
+/* Define to 1 when the gnulib module dup2 should be tested. */
+#undef GNULIB_TEST_DUP2
+
 /* Define to 1 when the gnulib module getaddrinfo should be tested. */
 #undef GNULIB_TEST_GETADDRINFO
 
+/* Define to 1 when the gnulib module getsockname should be tested. */
+#undef GNULIB_TEST_GETSOCKNAME
+
+/* Define to 1 when the gnulib module listen should be tested. */
+#undef GNULIB_TEST_LISTEN
+
 /* Define to 1 when the gnulib module mbrtowc should be tested. */
 #undef GNULIB_TEST_MBRTOWC
 
@@ -63,9 +81,24 @@
 /* Define to 1 when the gnulib module memmem should be tested. */
 #undef GNULIB_TEST_MEMMEM
 
+/* Define to 1 when the gnulib module recv should be tested. */
+#undef GNULIB_TEST_RECV
+
+/* Define to 1 when the gnulib module select should be tested. */
+#undef GNULIB_TEST_SELECT
+
+/* Define to 1 when the gnulib module send should be tested. */
+#undef GNULIB_TEST_SEND
+
+/* Define to 1 when the gnulib module setsockopt should be tested. */
+#undef GNULIB_TEST_SETSOCKOPT
+
 /* Define to 1 when the gnulib module snprintf should be tested. */
 #undef GNULIB_TEST_SNPRINTF
 
+/* Define to 1 when the gnulib module socket should be tested. */
+#undef GNULIB_TEST_SOCKET
+
 /* Define to 1 if you have 'alloca' after including <alloca.h>, a header that
    may be supplied by this distribution. */
 #undef HAVE_ALLOCA
@@ -147,6 +180,9 @@
    don't. */
 #undef HAVE_DECL__SNPRINTF
 
+/* Define to 1 if you have the 'dup2' function. */
+#undef HAVE_DUP2
+
 /* Define to 1 if you have the <features.h> header file. */
 #undef HAVE_FEATURES_H
 
@@ -360,6 +396,9 @@
 /* Define to 1 if getsockopt is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_GETSOCKOPT
 
+/* Define to 1 if gettimeofday is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_GETTIMEOFDAY
+
 /* Define to 1 if getusershell is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_GETUSERSHELL
 
@@ -438,6 +477,12 @@
 /* Define to 1 if pread is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_PREAD
 
+/* Define to 1 if pselect is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_PSELECT
+
+/* Define to 1 if pthread_sigmask is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_PTHREAD_SIGMASK
+
 /* Define to 1 if pwrite is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_PWRITE
 
@@ -462,6 +507,9 @@
 /* Define to 1 if rmdir is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_RMDIR
 
+/* Define to 1 if select is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SELECT
+
 /* Define to 1 if send is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_SEND
 
@@ -480,6 +528,30 @@
 /* Define to 1 if shutdown is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_SHUTDOWN
 
+/* Define to 1 if sigaction is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGACTION
+
+/* Define to 1 if sigaddset is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGADDSET
+
+/* Define to 1 if sigdelset is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGDELSET
+
+/* Define to 1 if sigemptyset is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGEMPTYSET
+
+/* Define to 1 if sigfillset is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGFILLSET
+
+/* Define to 1 if sigismember is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGISMEMBER
+
+/* Define to 1 if sigpending is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGPENDING
+
+/* Define to 1 if sigprocmask is declared even after undefining macros. */
+#undef HAVE_RAW_DECL_SIGPROCMASK
+
 /* Define to 1 if sleep is declared even after undefining macros. */
 #undef HAVE_RAW_DECL_SLEEP
 
@@ -687,6 +759,9 @@
 /* Define to 1 if 'wint_t' is a signed integer type. */
 #undef HAVE_SIGNED_WINT_T
 
+/* Define to 1 if the system has the type `sigset_t'. */
+#undef HAVE_SIGSET_T
+
 /* Define to 1 if you have the `snprintf' function. */
 #undef HAVE_SNPRINTF
 
@@ -738,12 +813,18 @@
 /* Define to 1 if you have the <sys/mman.h> header file. */
 #undef HAVE_SYS_MMAN_H
 
+/* Define to 1 if you have the <sys/select.h> header file. */
+#undef HAVE_SYS_SELECT_H
+
 /* Define to 1 if you have the <sys/socket.h> header file. */
 #undef HAVE_SYS_SOCKET_H
 
 /* Define to 1 if you have the <sys/stat.h> header file. */
 #undef HAVE_SYS_STAT_H
 
+/* Define to 1 if you have the <sys/time.h> header file. */
+#undef HAVE_SYS_TIME_H
+
 /* Define to 1 if you have the <sys/types.h> header file. */
 #undef HAVE_SYS_TYPES_H
 
@@ -1022,6 +1103,9 @@
 /* Define to a replacement function name for fnmatch(). */
 #undef fnmatch
 
+/* Define to `int' if <sys/types.h> doesn't define. */
+#undef gid_t
+
 /* Define to `__inline__' or `__inline' if that's what the C compiler
    calls it, or to nothing if 'inline' is not supported under any name.  */
 #ifndef __cplusplus
@@ -1077,6 +1161,9 @@
 /* Define as a signed type of the same size as size_t. */
 #undef ssize_t
 
+/* Define to `int' if <sys/types.h> doesn't define. */
+#undef uid_t
+
 /* Define as a marker that can be attached to declarations that might not
     be used.  This helps to reduce warnings, such as from
     GCC -Wunused-parameter.  */
diff --git a/gdb/gnulib/configure b/gdb/gnulib/configure
index 95e09c7..795f462 100644
--- a/gdb/gnulib/configure
+++ b/gdb/gnulib/configure
@@ -589,8 +589,8 @@ ac_includes_default="\
 #endif"
 
 gl_header_list=
-gl_fnmatch_required=POSIX
 gl_func_list=
+gl_fnmatch_required=POSIX
 ac_subst_vars='am__EXEEXT_FALSE
 am__EXEEXT_TRUE
 gltests_LTLIBOBJS
@@ -661,6 +661,14 @@ NEXT_SYS_UIO_H
 WINDOWS_64_BIT_OFF_T
 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
 NEXT_SYS_TYPES_H
+NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
+NEXT_SYS_TIME_H
+REPLACE_STRUCT_TIMEVAL
+REPLACE_GETTIMEOFDAY
+HAVE_SYS_TIME_H
+HAVE_STRUCT_TIMEVAL
+HAVE_GETTIMEOFDAY
+GNULIB_GETTIMEOFDAY


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [SCM]  jankratochvil/ipv6: .
@ 2013-04-18 20:00 jkratoch
  0 siblings, 0 replies; 4+ messages in thread
From: jkratoch @ 2013-04-18 20:00 UTC (permalink / raw)
  To: archer-commits

The branch, jankratochvil/ipv6 has been updated
       via  56a9b31dedd94c85fa4fcec4b98bb2a5250af1a7 (commit)
       via  d5655b8b239b8db415e5be0bb23732883533d40d (commit)
       via  c03b79b207f6896b2ac6fc7ef0d3a63548949cf3 (commit)
       via  254638dfadb925d3d1fd55f019841d5c6556e752 (commit)
       via  45140821a713d7b1ef8cb38c737591abfaaff596 (commit)
       via  a04b16a96f161d6b82bdc72ceddcead8539e3977 (commit)
       via  cbf2f0c9dd67247944d06588fd76c9002d61ae5a (commit)
       via  f112776d5ad2210f7b71b2acfd4ca385377c4755 (commit)
       via  3e258681182fe2fad8a479355494073134748396 (commit)
       via  c09b84a2353bfde550932fa90c3487c6aa962a18 (commit)
       via  c1357f25675c247a7ed40f6948f40d7d013f0bdd (commit)
       via  62629fa8221ab05d6d7ad14de41a3f4c9319f0bb (commit)
       via  7e2fcf5bb7283956d5b15b4c13a1051327f3b4b1 (commit)
       via  3c0732377364a48042cff54c10a4c23ba320da9e (commit)
       via  98512ac7e1b764f5e6a97ae0b4abe4e664400f1e (commit)
       via  dfc5309ae76d92023545e15af7905f5fd169d74c (commit)
       via  436dc645102f7132ab80f5c75a359d4f2603c25d (commit)
       via  85af929389a14039121edef603bb94dd462db727 (commit)
       via  fa47f0a2380e4cbb7c11f42b093729a368d8a5f4 (commit)
       via  ac31ed2ebb0456bddfce93b1fff1215a68183832 (commit)
       via  e8e160773247fa157b818494256ceeb9a806b351 (commit)
       via  d050582adfca8265d614fbd006962d7d68ef5db7 (commit)
       via  fca593717bca4c547b95d7def0cea736dcbc57c1 (commit)
       via  06c8b68dd50e339199bba570fb37381ad0cb9c87 (commit)
       via  62eecd59ebae3ae9d4210fccc91b93ad9b3978be (commit)
       via  a68efa3edbe0cd4f51cd1655e13caccbb4e41976 (commit)
       via  c80fa5a7c1b1277a6112f2984e2723c27cefd1df (commit)
       via  4751d00ef7a160c640f599303a85a0cbeee31409 (commit)
       via  92687545f1f26e54b40d90812b34791d97ecd867 (commit)
       via  20cf09b42ad2bcb0225cdc36cb228e515bd510a7 (commit)
       via  766ce5943c7dd9484310bd71a91a8b19d5b7b5c2 (commit)
       via  972f1ca0327da78f0eb9cd7fe9a760696642dc75 (commit)
       via  cb22b288a796779e3238ff812226a9897854c5aa (commit)
       via  049dc1118adce445d49828154b415f963c41a4d5 (commit)
       via  cc38e69962e8902416b513fe22d23d58f2e2c9d0 (commit)
       via  37d0d838c6e9e7b9a6464afdecce2cdbfdae4413 (commit)
       via  28af0d6627b6dd8059011ea5ba8ca81ce6530673 (commit)
       via  57e585c7379ae9b187ff75dca72e4bc4448cbac3 (commit)
       via  2d99d7b9cf07a4c6fd70f04e63f159e64abace77 (commit)
       via  59ef4e03755a084e872818ab85000f4123c92067 (commit)
       via  57b013f271b1191757b1d252774de9431fb2a546 (commit)
       via  21b86ca972aef67d7a1bf2e5373af7d8bcb22e0d (commit)
       via  f6b85d6aa9a9e6bce6a1b8e03393fa971deed4f7 (commit)
       via  6445a269bcdcf3052901aa60eaeb0c2a565b2f51 (commit)
       via  859638f53f33d406658e388b736fe89ef65de778 (commit)
      from  410dc9a3df7413cb21be3dd86d163938b7f23dfa (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 56a9b31dedd94c85fa4fcec4b98bb2a5250af1a7
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Apr 18 22:00:36 2013 +0200

    .

commit d5655b8b239b8db415e5be0bb23732883533d40d
Merge: c03b79b 254638d
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Apr 18 19:52:46 2013 +0200

    Merge remote-tracking branch 'gdb/master' into jankratochvil/ipv6

commit c03b79b207f6896b2ac6fc7ef0d3a63548949cf3
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Apr 18 19:52:14 2013 +0200

    .

commit 254638dfadb925d3d1fd55f019841d5c6556e752
Author: Luis Machado <luisgpm@br.ibm.com>
Date:   Thu Apr 18 10:08:08 2013 +0000

    	* gdb.mi/mi-var-create-rtti.exp: Create a variable of
    	type void *.

commit 45140821a713d7b1ef8cb38c737591abfaaff596
Author: gdbadmin <gdbadmin@sourceware.org>
Date:   Thu Apr 18 00:00:32 2013 +0000

    *** empty log message ***

commit a04b16a96f161d6b82bdc72ceddcead8539e3977
Author: Alan Modra <amodra@bigpond.net.au>
Date:   Thu Apr 18 00:00:04 2013 +0000

    daily update

commit cbf2f0c9dd67247944d06588fd76c9002d61ae5a
Author: Doug Evans <dje@google.com>
Date:   Wed Apr 17 21:07:08 2013 +0000

    	* lib/dwarf.exp (Dwarf): New proc "tu".
    	* gdb.dwarf2/missing-sig-type.exp: New file.

commit f112776d5ad2210f7b71b2acfd4ca385377c4755
Author: Doug Evans <dje@google.com>
Date:   Wed Apr 17 17:09:30 2013 +0000

    	* dwarf2read.c (struct signatured_type): New member type.
    	(struct attribute): Replace member signatured_type with signature.
    	(DW_SIGNATURE): Replaces DW_SIGNATURE_TYPE.
    	(read_call_site_scope): Call follow_die_ref instead of
    	follow_die_ref_or_sig.
    	(read_structure_type): Rewrite handling of signatured types.
    	(read_enumeration_type): Ditto.
    	(read_attribute_value): Update.
    	(build_error_marker_type): New function.
    	(lookup_die_type): Add assert.  Rewrite handling of signatured types.
    	Don't call error for bad types, just build an error marker type.
    	(dump_die_shallow): Update.
    	(follow_die_sig_1): Renamed from follow_die_sig.
    	Don't call error for bad types, instead return NULL.
    	(follow_die_sig): New function.
    	(get_signatured_type, get_DW_AT_signature_type): New functions.

commit 3e258681182fe2fad8a479355494073134748396
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Apr 17 16:22:13 2013 +0000

    Update copyright year on elf-ifunc.c
    
    	* elf-ifunc.c: Update copyright year.

commit c09b84a2353bfde550932fa90c3487c6aa962a18
Author: Joel Brobecker <brobecker@gnat.com>
Date:   Wed Apr 17 14:57:43 2013 +0000

    Fix line length problem in last entry.

commit c1357f25675c247a7ed40f6948f40d7d013f0bdd
Author: yufeng <yufeng>
Date:   Wed Apr 17 14:52:45 2013 +0000

    gdb/
    
    	* aarch64-tdep.c (aarch64_write_pc): Removed.
    	(aarch64_gdbarch_init): Remove set_gdbarch_write_pc of the above function.

commit 62629fa8221ab05d6d7ad14de41a3f4c9319f0bb
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Apr 17 14:16:00 2013 +0000

    	* coffcode.h: Added a cast to void when a bfd_set_section_*()
    	macro's return value is ignored.
    	* elf32-hppa.c: Likewise.
    	* elf32-tic6x.c: Likewise.
    	* mach-o.c: Likewise.
    	* mmo.c: Likewise.
    	* opncls.c: Likewise.
    	* peicode.h: Likewise.
    	* elf32-m32r.c: Check return value of bfd_set_section_*().
    	* elfnn-ia64.c: Likewise.
    	* elfxx-mips.c: Likewise.
    	* vms-alpha.c: Likewise.

commit 7e2fcf5bb7283956d5b15b4c13a1051327f3b4b1
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Apr 17 14:09:49 2013 +0000

    	PR binutils/15369
    	* cgen-dis.c (hash_insn_array): Use CGEN_CPU_INSN_ENDIAN instead
    	of CGEN_CPU_ENDIAN.
    	(hash_insns_list): Likewise.

commit 62eecd59ebae3ae9d4210fccc91b93ad9b3978be
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Apr 16 19:38:26 2013 +0200

    .

commit a68efa3edbe0cd4f51cd1655e13caccbb4e41976
Merge: 410dc9a c80fa5a
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Apr 16 19:24:10 2013 +0200

    Merge remote-tracking branch 'gdb/master' into jankratochvil/ipv6

-----------------------------------------------------------------------

Summary of changes:
 bfd/ChangeLog                                      |   26 +
 bfd/coffcode.h                                     |    6 +-
 bfd/compress.c                                     |    7 +-
 bfd/elf-ifunc.c                                    |   27 +-
 bfd/elf32-hppa.c                                   |    6 +-
 bfd/elf32-m32r.c                                   |    6 +-
 bfd/elf32-tic6x.c                                  |    5 +-
 bfd/elfnn-ia64.c                                   |   13 +-
 bfd/elfxx-mips.c                                   |   24 +-
 bfd/mach-o.c                                       |    6 +-
 bfd/mmo.c                                          |   18 +-
 bfd/opncls.c                                       |    7 +-
 bfd/peicode.h                                      |    6 +-
 bfd/version.h                                      |    2 +-
 bfd/vms-alpha.c                                    |    6 +-
 gdb/ChangeLog                                      |  207 +++++++
 gdb/Makefile.in                                    |    6 +-
 gdb/NEWS                                           |   17 +
 gdb/aarch64-tdep.c                                 |   10 -
 gdb/break-catch-throw.c                            |  597 ++++++++++++++++++++
 gdb/breakpoint.c                                   |  204 +-------
 gdb/breakpoint.h                                   |    2 +
 gdb/c-exp.y                                        |   13 +-
 gdb/c-lang.c                                       |    2 +-
 gdb/c-typeprint.c                                  |    4 +-
 gdb/common/gdb_thread_db.h                         |  445 +---------------
 gdb/common/{gdb_thread_db.h => glibc_thread_db.h}  |   89 ++--
 gdb/copyright.py                                   |    1 +
 gdb/cp-abi.c                                       |   41 ++
 gdb/cp-abi.h                                       |   27 +
 gdb/cp-support.c                                   |   10 +-
 gdb/cp-support.h                                   |    4 +
 gdb/doc/ChangeLog                                  |   27 +-
 gdb/doc/gdb.texinfo                                |  117 ++--
 gdb/dwarf2read.c                                   |  468 ++++++++++------
 gdb/elfread.c                                      |   15 +
 gdb/eval.c                                         |   17 +
 gdb/expprint.c                                     |    5 +
 gdb/gdb_regex.h                                    |    2 +
 gdb/gdbserver/ChangeLog                            |   22 +
 gdb/gdbserver/Makefile.in                          |    5 -
 gdb/gdbserver/config.in                            |    3 +
 gdb/gdbserver/configure                            |    7 +-
 gdb/gdbserver/configure.ac                         |    4 +-
 gdb/gdbserver/gdbreplay.c                          |   90 ++--
 gdb/gdbserver/linux-low.h                          |    6 +-
 gdb/gdbserver/remote-utils.c                       |  158 ++++--
 gdb/gdbtypes.c                                     |    5 +-
 gdb/gnu-v3-abi.c                                   |  241 ++++++++-
 gdb/jv-lang.c                                      |    3 +-
 gdb/jv-typeprint.c                                 |    5 +-
 gdb/language.c                                     |    3 +-
 gdb/parse.c                                        |    1 +
 gdb/probe.c                                        |   24 -
 gdb/ser-tcp.c                                      |   19 +-
 gdb/std-operator.def                               |    3 +
 gdb/symtab.c                                       |   12 +-
 gdb/testsuite/ChangeLog                            |   39 ++
 gdb/testsuite/gdb.base/default.exp                 |    1 +
 gdb/testsuite/gdb.cp/exception.exp                 |   33 +-
 .../gdb.cp/exceptprint.cc}                         |   63 ++-
 gdb/testsuite/gdb.cp/exceptprint.exp               |   94 +++
 gdb/testsuite/gdb.cp/typeid.cc                     |   60 ++
 gdb/testsuite/gdb.cp/typeid.exp                    |   67 +++
 gdb/testsuite/gdb.dwarf2/missing-sig-type.exp      |   68 +++
 gdb/testsuite/gdb.mi/mi-var-create-rtti.exp        |    6 +-
 gdb/testsuite/lib/dwarf.exp                        |   73 +++
 gdb/testsuite/lib/gdb.exp                          |   38 ++-
 gdb/top.c                                          |    9 +
 gdb/utils.c                                        |   24 +
 gdb/version.in                                     |    2 +-
 opcodes/ChangeLog                                  |    7 +
 opcodes/cgen-dis.c                                 |    7 +-
 73 files changed, 2496 insertions(+), 1201 deletions(-)
 create mode 100644 gdb/break-catch-throw.c
 copy gdb/common/{gdb_thread_db.h => glibc_thread_db.h} (87%)
 copy gdb/{gdb_regex.h => testsuite/gdb.cp/exceptprint.cc} (53%)
 create mode 100644 gdb/testsuite/gdb.cp/exceptprint.exp
 create mode 100644 gdb/testsuite/gdb.cp/typeid.cc
 create mode 100644 gdb/testsuite/gdb.cp/typeid.exp
 create mode 100644 gdb/testsuite/gdb.dwarf2/missing-sig-type.exp

First 500 lines of diff:
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index e717f12..be6dd52 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,29 @@
+2013-04-17  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* elf-ifunc.c: Update copyright year.
+
+2013-04-17 Luca Pizzamiglio  <luca.pizzamiglio@gmail.com>
+
+	* coffcode.h: Added a cast to void when a bfd_set_section_*()
+	macro's return value is ignored.
+	* elf32-hppa.c: Likewise.
+	* elf32-tic6x.c: Likewise.
+	* mach-o.c: Likewise.
+	* mmo.c: Likewise.
+	* opncls.c: Likewise.
+	* peicode.h: Likewise.
+	* elf32-m32r.c: Check return value of bfd_set_section_*().
+	* elfnn-ia64.c: Likewise.
+	* elfxx-mips.c: Likewise.
+	* vms-alpha.c: Likewise.
+
+2013-04-15  H.J. Lu  <hongjiu.lu@intel.com>
+
+	PR ld/15371
+	* elf-ifunc.c (_bfd_elf_allocate_ifunc_dyn_relocs): Check
+	regular reference without non-GOT reference when building
+	shared library.
+
 2013-04-15  Alan Modra  <amodra@gmail.com>
 
 	* archive.c (_bfd_archive_close_and_cleanup): Clear parent
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index 49c13c3..9d9c992 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -1,7 +1,5 @@
 /* Support for the generic parts of most COFF variants, for BFD.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
-   Free Software Foundation, Inc.
+   Copyright 1990-2013 Free Software Foundation, Inc.
    Written by Cygnus Support.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -3447,7 +3445,7 @@ coff_compute_section_file_positions (bfd * abfd)
 	 incremented in coff_set_section_contents.  This is right for
 	 SVR3.2.  */
       if (strcmp (current->name, _LIB) == 0)
-	bfd_set_section_vma (abfd, current, 0);
+	(void) bfd_set_section_vma (abfd, current, 0);
 #endif
 
 #ifdef ALIGN_SECTIONS_IN_FILE
diff --git a/bfd/compress.c b/bfd/compress.c
index eb3bc53..46c2bcb 100644
--- a/bfd/compress.c
+++ b/bfd/compress.c
@@ -45,19 +45,20 @@ decompress_contents (bfd_byte *compressed_buffer,
   strm.next_in = (Bytef*) compressed_buffer + 12;
   strm.avail_out = uncompressed_size;
 
+  BFD_ASSERT (Z_OK == 0);
   rc = inflateInit (&strm);
   while (strm.avail_in > 0 && strm.avail_out > 0)
     {
       if (rc != Z_OK)
-	return FALSE;
+	break;
       strm.next_out = ((Bytef*) uncompressed_buffer
                        + (uncompressed_size - strm.avail_out));
       rc = inflate (&strm, Z_FINISH);
       if (rc != Z_STREAM_END)
-	return FALSE;
+	break;
       rc = inflateReset (&strm);
     }
-  rc = inflateEnd (&strm);
+  rc |= inflateEnd (&strm);
   return rc == Z_OK && strm.avail_out == 0;
 }
 #endif
diff --git a/bfd/elf-ifunc.c b/bfd/elf-ifunc.c
index e56427d..c2fa163 100644
--- a/bfd/elf-ifunc.c
+++ b/bfd/elf-ifunc.c
@@ -1,5 +1,5 @@
 /* ELF STT_GNU_IFUNC support.
-   Copyright 2009
+   Copyright 2009-2013
    Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -187,23 +187,20 @@ _bfd_elf_allocate_ifunc_dyn_relocs (struct bfd_link_info *info,
 
   htab = elf_hash_table (info);
 
+  /* When building shared library, we need to handle the case where it is
+     marked with regular reference, but not non-GOT reference since the
+     non-GOT reference bit may not be set here.  */
+  if (info->shared && !h->non_got_ref && h->ref_regular)
+    for (p = *head; p != NULL; p = p->next)
+      if (p->count)
+	{
+	  h->non_got_ref = 1;
+	  goto keep;
+	}
+
   /* Support garbage collection against STT_GNU_IFUNC symbols.  */
   if (h->plt.refcount <= 0 && h->got.refcount <= 0)
     {
-      /* When building shared library, we need to handle the case
-         where it is marked with regular reference, but not non-GOT
-	 reference.  It may happen if we didn't see STT_GNU_IFUNC
-	 symbol at the time when checking relocations.  */
-      if (info->shared
-	  && !h->non_got_ref
-	  && h->ref_regular)
-	for (p = *head; p != NULL; p = p->next)
-	  if (p->count)
-	    {
-	      h->non_got_ref = 1;
-	      goto keep;
-	    }
-
       h->got = htab->init_got_offset;
       h->plt = htab->init_plt_offset;
       *head = NULL;
diff --git a/bfd/elf32-hppa.c b/bfd/elf32-hppa.c
index 4ffa3d2..dfffbcb 100644
--- a/bfd/elf32-hppa.c
+++ b/bfd/elf32-hppa.c
@@ -1,7 +1,5 @@
 /* BFD back-end for HP PA-RISC ELF files.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000, 2001,
-   2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
-   Free Software Foundation, Inc.
+   Copyright 1990-2013 Free Software Foundation, Inc.
 
    Original code by
 	Center for Software Science
@@ -2370,7 +2368,7 @@ elf32_hppa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
 	      bfd_size_type mask;
 
 	      if (gotalign > pltalign)
-		bfd_set_section_alignment (dynobj, sec, gotalign);
+		(void) bfd_set_section_alignment (dynobj, sec, gotalign);
 	      mask = ((bfd_size_type) 1 << gotalign) - 1;
 	      sec->size = (sec->size + sizeof (plt_stub) + mask) & ~mask;
 	    }
diff --git a/bfd/elf32-m32r.c b/bfd/elf32-m32r.c
index 789a456..71e8fc7 100644
--- a/bfd/elf32-m32r.c
+++ b/bfd/elf32-m32r.c
@@ -1,6 +1,5 @@
 /* M32R-specific support for 32-bit ELF.
-   Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-   2006, 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+   Copyright 1996-2013 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -1390,7 +1389,8 @@ m32r_elf_add_symbol_hook (bfd *abfd,
 						  flags);
 	  if (s == NULL)
 	    return FALSE;
-	  bfd_set_section_alignment (abfd, s, 2);
+	  if (! bfd_set_section_alignment (abfd, s, 2))
+	    return FALSE;
 	}
 
       bh = bfd_link_hash_lookup (info->hash, "_SDA_BASE_",
diff --git a/bfd/elf32-tic6x.c b/bfd/elf32-tic6x.c
index 04ef708..77c6ad1 100644
--- a/bfd/elf32-tic6x.c
+++ b/bfd/elf32-tic6x.c
@@ -1,6 +1,5 @@
 /* 32-bit ELF support for TI C6X
-   Copyright 2010, 2011, 2012
-   Free Software Foundation, Inc.
+   Copyright 2010-2013 Free Software Foundation, Inc.
    Contributed by Joseph Myers <joseph@codesourcery.com>
    		  Bernd Schmidt  <bernds@codesourcery.com>
 
@@ -3038,7 +3037,7 @@ elf32_tic6x_add_symbol_hook (bfd *abfd,
       *secp = bfd_make_section_old_way (abfd, ".scommon");
       (*secp)->flags |= SEC_IS_COMMON;
       *valp = sym->st_size;
-      bfd_set_section_alignment (abfd, *secp, bfd_log2 (sym->st_value));
+      (void) bfd_set_section_alignment (abfd, *secp, bfd_log2 (sym->st_value));
       break;
     }
 
diff --git a/bfd/elfnn-ia64.c b/bfd/elfnn-ia64.c
index 05c2f1b..117b4c8 100644
--- a/bfd/elfnn-ia64.c
+++ b/bfd/elfnn-ia64.c
@@ -1,6 +1,5 @@
 /* IA-64 support for 64-bit ELF
-   Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
-   2008, 2009, 2010, 2011, 2012  Free Software Foundation, Inc.
+   Copyright 1998-2013 Free Software Foundation, Inc.
    Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -1546,7 +1545,8 @@ elfNN_ia64_create_dynamic_sections (bfd *abfd,
     bfd_set_section_flags (abfd, ia64_info->root.sgot,
 			   SEC_SMALL_DATA | flags);
     /* The .got section is always aligned at 8 bytes.  */
-    bfd_set_section_alignment (abfd, ia64_info->root.sgot, 3);
+    if (! bfd_set_section_alignment (abfd, ia64_info->root.sgot, 3))
+      return FALSE;
   }
 
   if (!get_pltoff (abfd, info, ia64_info))
@@ -1952,16 +1952,17 @@ get_got (bfd *abfd, struct bfd_link_info *info,
       if (!dynobj)
 	ia64_info->root.dynobj = dynobj = abfd;
       if (!_bfd_elf_create_got_section (dynobj, info))
-	return 0;
+	return NULL;
 
       got = ia64_info->root.sgot;
 
       /* The .got section is always aligned at 8 bytes.  */
       if (!bfd_set_section_alignment (abfd, got, 3))
-	return 0;
+	return NULL;
 
       flags = bfd_get_section_flags (abfd, got);
-      bfd_set_section_flags (abfd, got, SEC_SMALL_DATA | flags);
+      if (! bfd_set_section_flags (abfd, got, SEC_SMALL_DATA | flags))
+	return NULL;
     }
 
   return got;
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
index 317e7b2..fa80771 100644
--- a/bfd/elfxx-mips.c
+++ b/bfd/elfxx-mips.c
@@ -1,7 +1,5 @@
 /* MIPS-specific support for ELF
-   Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-   2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013
-   Free Software Foundation, Inc.
+   Copyright 1993-2013 Free Software Foundation, Inc.
 
    Most of the information added by Ian Lance Taylor, Cygnus Support,
    <ian@cygnus.com>.
@@ -7265,20 +7263,24 @@ _bfd_mips_elf_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
       /* Change alignments of some sections.  */
       s = bfd_get_linker_section (abfd, ".hash");
       if (s != NULL)
-	bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+	(void) bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+
       s = bfd_get_linker_section (abfd, ".dynsym");
       if (s != NULL)
-	bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+	(void) bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+
       s = bfd_get_linker_section (abfd, ".dynstr");
       if (s != NULL)
-	bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+	(void) bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+
       /* ??? */
       s = bfd_get_section_by_name (abfd, ".reginfo");
       if (s != NULL)
-	bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+	(void) bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+
       s = bfd_get_linker_section (abfd, ".dynamic");
       if (s != NULL)
-	bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
+	(void) bfd_set_section_alignment (abfd, s, MIPS_ELF_LOG_FILE_ALIGN (abfd));
     }
 
   if (!info->shared)
@@ -13533,7 +13535,8 @@ _bfd_mips_elf_final_link (bfd *abfd, struct bfd_link_info *info)
 \f
 /* Structure for saying that BFD machine EXTENSION extends BASE.  */
 
-struct mips_mach_extension {
+struct mips_mach_extension
+{
   unsigned long extension, base;
 };
 
@@ -13541,7 +13544,8 @@ struct mips_mach_extension {
 /* An array describing how BFD machines relate to one another.  The entries
    are ordered topologically with MIPS I extensions listed last.  */
 
-static const struct mips_mach_extension mips_mach_extensions[] = {
+static const struct mips_mach_extension mips_mach_extensions[] =
+{
   /* MIPS64r2 extensions.  */
   { bfd_mach_mips_octeon2, bfd_mach_mips_octeonp },
   { bfd_mach_mips_octeonp, bfd_mach_mips_octeon },
diff --git a/bfd/mach-o.c b/bfd/mach-o.c
index c92b530..e1bbd29 100644
--- a/bfd/mach-o.c
+++ b/bfd/mach-o.c
@@ -1,7 +1,5 @@
 /* Mach-O support for BFD.
-   Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
-   2009, 2010, 2011, 2012
-   Free Software Foundation, Inc.
+   Copyright 1999-2013 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -2693,7 +2691,7 @@ bfd_mach_o_new_section_hook (bfd *abfd, asection *sec)
 	  s->flags = xlat->macho_sectype | xlat->macho_secattr;
 	  s->align = xlat->sectalign > bfdalign ? xlat->sectalign
 						: bfdalign;
-	  bfd_set_section_alignment (abfd, sec, s->align);
+	  (void) bfd_set_section_alignment (abfd, sec, s->align);
 	  bfd_flags = bfd_get_section_flags (abfd, sec);
 	  if (bfd_flags == SEC_NO_FLAGS)
 	    bfd_set_section_flags (abfd, sec, xlat->bfd_flags);
diff --git a/bfd/mmo.c b/bfd/mmo.c
index e336723..cd7b0fc 100644
--- a/bfd/mmo.c
+++ b/bfd/mmo.c
@@ -1,6 +1,5 @@
 /* BFD back-end for mmo objects (MMIX-specific object-format).
-   Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009, 2010, 2011
-   Free Software Foundation, Inc.
+   Copyright 2001-2013 Free Software Foundation, Inc.
    Written by Hans-Peter Nilsson (hp@bitrange.com).
    Infrastructure and other bits originally copied from srec.c and
    binary.c.
@@ -662,8 +661,9 @@ mmo_decide_section (bfd *abfd, bfd_vma vma)
       if (sec == NULL)
 	return NULL;
 
-      if (! sec->user_set_vma)
-	bfd_set_section_vma (abfd, sec, vma);
+      if (! sec->user_set_vma && ! bfd_set_section_vma (abfd, sec, vma))
+	return NULL;
+
       if (! bfd_set_section_flags (abfd, sec,
 				   bfd_get_section_flags (abfd, sec)
 				   | SEC_CODE | SEC_LOAD | SEC_ALLOC))
@@ -676,8 +676,9 @@ mmo_decide_section (bfd *abfd, bfd_vma vma)
       if (sec == NULL)
 	return NULL;
 
-      if (! sec->user_set_vma)
-	bfd_set_section_vma (abfd, sec, vma);
+      if (! sec->user_set_vma && ! bfd_set_section_vma (abfd, sec, vma))
+	return NULL;
+
       if (! bfd_set_section_flags (abfd, sec,
 				   bfd_get_section_flags (abfd, sec)
 				   | SEC_LOAD | SEC_ALLOC))
@@ -692,8 +693,9 @@ mmo_decide_section (bfd *abfd, bfd_vma vma)
   /* If there's still no suitable section, make a new one.  */
   sprintf (sec_name, ".MMIX.sec.%d", abfd->tdata.mmo_data->sec_no++);
   sec = mmo_make_section (abfd, sec_name);
-  if (! sec->user_set_vma)
-    bfd_set_section_vma (abfd, sec, vma);
+
+  if (! sec->user_set_vma && ! bfd_set_section_vma (abfd, sec, vma))
+    return NULL;
 
   if (! bfd_set_section_flags (abfd, sec,
 			       bfd_get_section_flags (abfd, sec)
diff --git a/bfd/opncls.c b/bfd/opncls.c
index 1217cea..3879a65 100644
--- a/bfd/opncls.c
+++ b/bfd/opncls.c
@@ -1,7 +1,5 @@
 /* opncls.c -- open and close a BFD.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000,
-   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013
-   Free Software Foundation, Inc.
+   Copyright 1990-2013 Free Software Foundation, Inc.
 
    Written by Cygnus Support.
 
@@ -255,12 +253,13 @@ bfd_fopen (const char *filename, const char *target, const char *mode, int fd)
       return NULL;
     }
   nbfd->opened_once = TRUE;
+
   /* If we opened the file by name, mark it cacheable; we can close it
      and reopen it later.  However, if a file descriptor was provided,
      then it may have been opened with special flags that make it
      unsafe to close and reopen the file.  */
   if (fd == -1)
-    bfd_set_cacheable (nbfd, TRUE);
+    (void) bfd_set_cacheable (nbfd, TRUE);
 
   return nbfd;
 }
diff --git a/bfd/peicode.h b/bfd/peicode.h
index 66c8198..64ca092 100644
--- a/bfd/peicode.h
+++ b/bfd/peicode.h
@@ -1,7 +1,5 @@
 /* Support for the generic parts of PE/PEI, for BFD.
-   Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
-   Free Software Foundation, Inc.
+   Copyright 1995-2013 Free Software Foundation, Inc.
    Written by Cygnus Solutions.
 
    This file is part of BFD, the Binary File Descriptor library.
@@ -610,7 +608,7 @@ pe_ILF_make_a_section (pe_ILF_vars * vars,
 
   bfd_set_section_flags (vars->abfd, sec, flags | extra_flags);
 
-  bfd_set_section_alignment (vars->abfd, sec, 2);
+  (void) bfd_set_section_alignment (vars->abfd, sec, 2);
 
   /* Check that we will not run out of space.  */
   BFD_ASSERT (vars->data + size < vars->bim->buffer + vars->bim->size);
diff --git a/bfd/version.h b/bfd/version.h
index a62bb74..a1afd19 100644
--- a/bfd/version.h
+++ b/bfd/version.h
@@ -1,4 +1,4 @@
-#define BFD_VERSION_DATE 20130415
+#define BFD_VERSION_DATE 20130418
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING  @bfd_version_package@ @bfd_version_string@
 #define REPORT_BUGS_TO @report_bugs_to@
diff --git a/bfd/vms-alpha.c b/bfd/vms-alpha.c
index 3383b0f..4edc226 100644
--- a/bfd/vms-alpha.c
+++ b/bfd/vms-alpha.c
@@ -1,6 +1,5 @@
 /* vms.c -- BFD back-end for EVAX (openVMS/Alpha) files.
-   Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-   2006, 2007, 2008, 2009, 2010, 2011  Free Software Foundation, Inc.
+   Copyright 1996-2013 Free Software Foundation, Inc.
 
    Initial version written by Klaus Kaempf (kkaempf@rmi.de)
    Major rewrite by Adacore.
@@ -9118,7 +9117,8 @@ vms_new_section_hook (bfd * abfd, asection *section)
   vms_debug2 ((1, "vms_new_section_hook (%p, [%d]%s)\n",
                abfd, section->index, section->name));
 
-  bfd_set_section_alignment (abfd, section, 0);
+  if (! bfd_set_section_alignment (abfd, section, 0))
+    return FALSE;
 
   vms_debug2 ((7, "%d: %s\n", section->index, section->name));
 
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d3c4edc..85c3245 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,210 @@
+2013-04-17  Doug Evans  <dje@google.com>
+
+	* dwarf2read.c (struct signatured_type): New member type.
+	(struct attribute): Replace member signatured_type with signature.
+	(DW_SIGNATURE): Replaces DW_SIGNATURE_TYPE.
+	(read_call_site_scope): Call follow_die_ref instead of
+	follow_die_ref_or_sig.
+	(read_structure_type): Rewrite handling of signatured types.
+	(read_enumeration_type): Ditto.
+	(read_attribute_value): Update.
+	(build_error_marker_type): New function.
+	(lookup_die_type): Add assert.  Rewrite handling of signatured types.
+	Don't call error for bad types, just build an error marker type.
+	(dump_die_shallow): Update.
+	(follow_die_sig_1): Renamed from follow_die_sig.
+	Don't call error for bad types, instead return NULL.
+	(follow_die_sig): New function.
+	(get_signatured_type, get_DW_AT_signature_type): New functions.
+
+2013-04-17  Yufeng Zhang  <yufeng.zhang@arm.com>
+
+	* aarch64-tdep.c (aarch64_write_pc): Removed.
+	(aarch64_gdbarch_init): Remove set_gdbarch_write_pc of the above
+	function.
+
+2013-04-17  Yao Qi  <yao@codesourcery.com>
+
+	* top.c (print_gdb_configuration): Print configure-time
+	parameter on using libbabeltrace or not.
+
+2013-04-16  Pedro Alves  <palves@redhat.com>
+
+	* copyright.py (EXCLUDE_LIST): Add gdb/common/glibc_thread_db.h.
+
+2013-04-16  Pedro Alves  <palves@redhat.com>
+
+	* common/glibc_thread_db.h: Update from upstream glibc
+	(git 568035b7874a099087b77f7bba3e36a1173787b0).
+
+2013-04-16  Pedro Alves  <palves@redhat.com>
+
+	* common/gdb_thread_db.h [!HAVE_THREAD_DB_H]: Factor out to ...


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-04-22 19:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-04-15 20:10 [SCM] jankratochvil/ipv6: jkratoch
2013-04-18 20:00 jkratoch
2013-04-19 18:43 jkratoch
2013-04-22 19:36 jkratoch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).