Revision: 6753
          http://ipcop.svn.sourceforge.net/ipcop/?rev=6753&view=rev
Author:   gespinasse
Date:     2012-08-13 16:02:51 +0000 (Mon, 13 Aug 2012)
Log Message:
-----------
Add a glibc-2.14.1 patch indicated 12 month ago by matthew on LFS that fix 
getopt detection for recent package.
This fix 'checking for working GNU getopt function... no' for bison-2.5.1, 
coreutils-8.17, diffutils-3.2, grep-2.13, gzip-1.5, wget-1.13.4

Modified Paths:
--------------
    ipcop/trunk/lfs/glibc

Added Paths:
-----------
    ipcop/trunk/src/patches/glibc-2.14.1_getopt.patch

Modified: ipcop/trunk/lfs/glibc
===================================================================
--- ipcop/trunk/lfs/glibc       2012-08-13 15:57:20 UTC (rev 6752)
+++ ipcop/trunk/lfs/glibc       2012-08-13 16:02:51 UTC (rev 6753)
@@ -119,6 +119,9 @@
        #cd $(DIR_APP) && patch -p1 -i $(DIR_PATCHES)/glibc-CVE-2012-0864.patch
        cd $(DIR_APP) && patch -p1 -i 
$(DIR_PATCHES)/glibc-2.11.1_notimestamp.patch
        cd $(DIR_APP) && patch -p1 -i 
$(DIR_PATCHES)/glibc-2.11_sparc-localedef-mmap.patch
+       # this fix 'checking for working GNU getopt function... no' for 
packages that include recent gnulib getopt test
+       # like bison-2.5.1, coreutils-8.17, diffutils-3.2, grep-2.13, gzip-1.5, 
wget-1.13.4
+       cd $(DIR_APP) && patch -p1 -i $(DIR_PATCHES)/glibc-2.14.1_getopt.patch
 
        @mkdir $(DIR_SRC)/glibc-build
 

Added: ipcop/trunk/src/patches/glibc-2.14.1_getopt.patch
===================================================================
--- ipcop/trunk/src/patches/glibc-2.14.1_getopt.patch                           
(rev 0)
+++ ipcop/trunk/src/patches/glibc-2.14.1_getopt.patch   2012-08-13 16:02:51 UTC 
(rev 6753)
@@ -0,0 +1,68 @@
+From 01636b2140cd1281202b89f7103249ed598065c4 Mon Sep 17 00:00:00 2001
+From: Ulrich Drepper <drep...@gmail.com>
+Date: Wed, 6 Jul 2011 21:27:14 -0400
+Subject: [PATCH] Handle W; without long options in getopt
+
+---
+ ChangeLog      |    6 ++++++
+ NEWS           |    2 +-
+ posix/getopt.c |    9 +++++++--
+ 3 files changed, 14 insertions(+), 3 deletions(-)
+
+#diff --git a/ChangeLog b/ChangeLog
+#index 547cd4e..6ac3ae0 100644
+#--- a/ChangeLog
+#+++ b/ChangeLog
+#@@ -1,3 +1,9 @@
++2011-07-06  Ulrich Drepper  <drep...@gmail.com>
++
++      [BZ #12922]
++      * posix/getopt.c (_getopt_internal_r): When "W;" is in short options
++      but no long options are defined, just return 'W'.
++
+ 2011-06-22  Marek Polacek  <mpola...@redhat.com>
+ 
+       [BZ #9696]
+#diff --git a/NEWS b/NEWS
+#index 1e1e220..dd5565f 100644
+#--- a/NEWS
+#+++ b/NEWS
+#@@ -9,7 +9,7 @@ Version 2.15
+ 
+ * The following bugs are resolved with this release:
+ 
+-  9696, 12874, 12885, 12907, 12935
++  9696, 12874, 12885, 12907, 12922, 12935
+ 
+ * New program pldd to list loaded object of a process
+   Implemented by Ulrich Drepper.
+diff --git a/posix/getopt.c b/posix/getopt.c
+index db89abf..3fa5a4d 100644
+--- a/posix/getopt.c
++++ b/posix/getopt.c
+@@ -871,6 +871,9 @@ _getopt_internal_r (int argc, char *const *argv, const 
char *optstring,
+     /* Convenience. Treat POSIX -W foo same as long option --foo */
+     if (temp[0] == 'W' && temp[1] == ';')
+       {
++      if (longopts == NULL)
++        goto no_longs;
++
+       char *nameend;
+       const struct option *p;
+       const struct option *pfound = NULL;
+@@ -1086,8 +1089,10 @@ _getopt_internal_r (int argc, char *const *argv, const 
char *optstring,
+             }
+           return pfound->val;
+         }
+-        d->__nextchar = NULL;
+-        return 'W';   /* Let the application handle it.   */
++
++      no_longs:
++      d->__nextchar = NULL;
++      return 'W';     /* Let the application handle it.   */
+       }
+     if (temp[1] == ':')
+       {
+-- 
+1.7.3.4
+

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Ipcop-svn mailing list
Ipcop-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ipcop-svn

Reply via email to