Index: BOOK/patches.ent
===================================================================
--- BOOK/patches.ent	(revision 314c1831f0157fda49695c3e2f65c7641836e3cb)
+++ BOOK/patches.ent	(revision 6c613c435589b13eb5779e331b45f42c0958a6d4)
@@ -139,7 +139,7 @@
 <!-- Start of ppc/ppc64 patches -->
 
-<!ENTITY eglibc-qecvt-patch "eglibc-&eglibc-version;-qecvt-1.patch">
-<!ENTITY eglibc-qecvt-patch-md5 "06e5e2529e96ad144ca232887a2055b5">
-<!ENTITY eglibc-qecvt-patch-size ".859 KB">
+<!ENTITY eglibc-qecvt-patch "eglibc-&eglibc-version;-qecvt-2.patch">
+<!ENTITY eglibc-qecvt-patch-md5 "002efdbed2db76b6fabfd93e19d9f54f">
+<!ENTITY eglibc-qecvt-patch-size "1.835 KB">
 
 <!ENTITY gcc-nof-patch "gcc-&gcc-version;-powerpc64_multilib-1.patch">
Index: tches/eglibc-2.17-qecvt-1.patch
===================================================================
--- patches/eglibc-2.17-qecvt-1.patch	(revision 314c1831f0157fda49695c3e2f65c7641836e3cb)
+++ 	(revision )
@@ -1,22 +1,0 @@
-Submitted By: William Harrington kb0iic at cross-lfs dot org.
-Date: 2013-01-13
-Initial Package Version: 2.15
-Upstream Status: Unknown
-Origin: http://sourceware.org/bugzilla/show_bug.cgi?id=15007
-Description: Fixes a mismatch of guards around qcvt and friends.
-
-Redone for eglibc-2.17 on 2013-06-05
-
-diff -Naur eglibc-2.17.orig/stdlib/bits/stdlib-ldbl.h eglibc-2.17/stdlib/bits/stdlib-ldbl.h
---- eglibc-2.17.orig/stdlib/bits/stdlib-ldbl.h	2013-06-05 16:56:48.000000000 +0000
-+++ eglibc-2.17/stdlib/bits/stdlib-ldbl.h	2013-06-05 18:46:39.012840463 +0000
-@@ -30,7 +30,8 @@
- __LDBL_REDIR1_DECL (strtold_l, strtod_l)
- #endif
- 
--#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED
-+#if (defined __USE_XOPEN_EXTENDED && !defined __USE_XOPEN2K8) \
-+    || defined __USE_SVID 
- # ifdef __USE_MISC
- __LDBL_REDIR1_DECL (qecvt, ecvt)
- __LDBL_REDIR1_DECL (qfcvt, fcvt)
Index: patches/eglibc-2.17-qecvt-2.patch
===================================================================
--- patches/eglibc-2.17-qecvt-2.patch	(revision 6c613c435589b13eb5779e331b45f42c0958a6d4)
+++ patches/eglibc-2.17-qecvt-2.patch	(revision 6c613c435589b13eb5779e331b45f42c0958a6d4)
@@ -0,0 +1,51 @@
+Submitted By: William Harrington kb0iic at cross-lfs dot org.
+Date: 2013-08-12
+Initial Package Version: 2.17
+Upstream Status: Applied to 2.18 
+Origin: http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=4220c3ef773c0e7fff7c95ecd7cff69886fe4c0e
+Description: Fixes a mismatch of guards around qcvt and friends.
+
+Redone for eglibc-2.17 on 2013-08-12
+
+diff -Naur eglibc-2.17.orig/stdlib/bits/stdlib-ldbl.h eglibc-2.17/stdlib/bits/stdlib-ldbl.h
+--- eglibc-2.17.orig/stdlib/bits/stdlib-ldbl.h	2012-02-18 02:24:59.000000000 +0000
++++ eglibc-2.17/stdlib/bits/stdlib-ldbl.h	2013-08-11 22:09:07.000000000 +0000
+@@ -30,12 +30,10 @@
+ __LDBL_REDIR1_DECL (strtold_l, strtod_l)
+ #endif
+ 
+-#if defined __USE_SVID || defined __USE_XOPEN_EXTENDED
+-# ifdef __USE_MISC
++#ifdef __USE_MISC
+ __LDBL_REDIR1_DECL (qecvt, ecvt)
+ __LDBL_REDIR1_DECL (qfcvt, fcvt)
+ __LDBL_REDIR1_DECL (qgcvt, gcvt)
+ __LDBL_REDIR1_DECL (qecvt_r, ecvt_r)
+ __LDBL_REDIR1_DECL (qfcvt_r, fcvt_r)
+-# endif
+ #endif
+diff -Naur eglibc-2.17.orig/stdlib/stdlib.h eglibc-2.17/stdlib/stdlib.h
+--- eglibc-2.17.orig/stdlib/stdlib.h	2012-11-09 22:50:35.000000000 +0000
++++ eglibc-2.17/stdlib/stdlib.h	2013-08-11 22:06:29.000000000 +0000
+@@ -819,8 +819,9 @@
+ extern char *gcvt (double __value, int __ndigit, char *__buf)
+      __THROW __nonnull ((3)) __wur;
+ 
++#endif
+ 
+-# ifdef __USE_MISC
++#ifdef __USE_MISC
+ /* Long double versions of above functions.  */
+ extern char *qecvt (long double __value, int __ndigit,
+ 		    int *__restrict __decpt, int *__restrict __sign)
+@@ -849,9 +850,7 @@
+ 		    int *__restrict __decpt, int *__restrict __sign,
+ 		    char *__restrict __buf, size_t __len)
+      __THROW __nonnull ((3, 4, 5));
+-# endif	/* misc */
+-#endif	/* use MISC || use X/Open Unix */
+-
++#endif /* misc */
+ 
+ __BEGIN_NAMESPACE_STD
+ /* Return the length of the multibyte character
