diff --git a/include/ChangeLog b/include/ChangeLog
index d55775046539a7ba44885f6fc6a4523197fdfc62..063e082cb03a8fc5eb07633a5dd2fdb95803c506 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,8 @@
+2005-07-12  Ben Elliston  <bje@au.ibm.com>
+
+	* xregex2.h (regexec): Qualify this prototype with __extension__
+	when compiling with GNU C.
+
 2005-07-07  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
 
 	* dis-asm.h (fprintf_ftype): Add format attribute.
diff --git a/include/xregex2.h b/include/xregex2.h
index 358f31e437845023c1ce974e2c31b8fda50f8f05..d3d0da14a9878b40291ca954b8d524f0e6e8a343 100644
--- a/include/xregex2.h
+++ b/include/xregex2.h
@@ -1,6 +1,9 @@
 /* Definitions for data structures and routines for the regular
    expression library, version 0.12.
-   Copyright (C) 1985,1989-1993,1995-1998, 2000 Free Software Foundation, Inc.
+
+   Copyright (C) 1985, 1989, 1990, 1991, 1992, 1993, 1995, 1996, 1997,
+   1998, 2000, 2005 Free Software Foundation, Inc.
+
    This file is part of the GNU C Library.  Its master source is NOT part of
    the C library, however.  The master source lives in /gd/gnu/lib.
 
@@ -533,6 +536,9 @@ extern int regcomp (regex_t *__restrict __preg,
                     const char *__restrict __pattern,
                     int __cflags);
 
+#if (__GNUC__)
+__extension__
+#endif
 extern int regexec (const regex_t *__restrict __preg,
                     const char *__restrict __string, size_t __nmatch,
                     regmatch_t __pmatch[__restrict_arr],
diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog
index dc55ff2e546a0c8ef743c89eb055300f6fd1f90a..e2cbeb4741ee2bb2975bd52dbe3bc6b6f5ac8886 100644
--- a/libiberty/ChangeLog
+++ b/libiberty/ChangeLog
@@ -1,3 +1,13 @@
+2005-07-12  Ben Elliston  <bje@au.ibm.com>
+
+	* floatformat.c (floatformat_to_double): Add a comment about a
+	potential source of warnings when compiling this file.
+
+2005-07-12  Ben Elliston  <bje@au.ibm.com>
+
+	* pexecute.c (pexecute): Cast string litrals to char *.
+	* regex.c (re_comp): Cast a call to gettext() to char *.
+
 2005-07-07  Kelley Cook  <kcook@gcc.gnu.org>
 
 	* config.table: Delete file.  Move former contents into ...
diff --git a/libiberty/floatformat.c b/libiberty/floatformat.c
index 41000f459e4833330d6ddc74a9a76abf0298cf3c..e466f53a7abb99f44d956f2d0e7cfaff8a1dbfad 100644
--- a/libiberty/floatformat.c
+++ b/libiberty/floatformat.c
@@ -306,6 +306,13 @@ floatformat_to_double (const struct floatformat *fmt,
 	  mant_bits_left -= mant_bits;
 	}
 
+      /* On certain systems (such as GNU/Linux), the use of the
+	 INFINITY macro below may generate a warning that can not be
+	 silenced due to a bug in GCC (PR preprocessor/11931).  The
+	 preprocessor fails to recognise the __extension__ keyword in
+	 conjunction with the GNU/C99 extension for hexadecimal
+	 floating point constants and will issue a warning when
+	 compiling with -pedantic.  */
       if (nan)
 	dto = NAN;
       else
diff --git a/libiberty/pexecute.c b/libiberty/pexecute.c
index 60a280b8e472931106d9d8bf7f800bdf17851872..cce6e300c5d5bd14b8c8ca2ef3bc4b5a3139df92 100644
--- a/libiberty/pexecute.c
+++ b/libiberty/pexecute.c
@@ -47,7 +47,7 @@ pexecute (const char *program, char * const *argv, const char *pname,
     {
       if (pex != NULL)
 	{
-	  *errmsg_fmt = "pexecute already in progress";
+	  *errmsg_fmt = (char *) "pexecute already in progress";
 	  *errmsg_arg = NULL;
 	  return -1;
 	}
@@ -58,7 +58,7 @@ pexecute (const char *program, char * const *argv, const char *pname,
     {
       if (pex == NULL)
 	{
-	  *errmsg_fmt = "pexecute not in progress";
+	  *errmsg_fmt = (char *) "pexecute not in progress";
 	  *errmsg_arg = NULL;
 	  return -1;
 	}
diff --git a/libiberty/regex.c b/libiberty/regex.c
index 9d3e532a59885a2c5ab1f9db2fa4e1947bb51903..b7be99d25b2b9286fa06faefe7f425eb851b6091 100644
--- a/libiberty/regex.c
+++ b/libiberty/regex.c
@@ -7814,7 +7814,7 @@ re_comp (const char *s)
   if (!s)
     {
       if (!re_comp_buf.buffer)
-	return gettext ("No previous regular expression");
+	return (char *) gettext ("No previous regular expression");
       return 0;
     }