[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commits] r14350 - in /fsf/trunk/libc: ./ elf/ inet/ nscd/ sysdeps/unix/sysv/linux/



Author: eglibc
Date: Tue Jun 28 00:03:11 2011
New Revision: 14350

Log:
Import glibc-mainline for 2011-06-28

Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/configure
    fsf/trunk/libc/configure.in
    fsf/trunk/libc/elf/soinit.c
    fsf/trunk/libc/inet/getnetgrent_r.c
    fsf/trunk/libc/nscd/aicache.c
    fsf/trunk/libc/sysdeps/unix/sysv/linux/Makefile

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Tue Jun 28 00:03:11 2011
@@ -1,3 +1,22 @@
+2011-06-27  Roland McGrath  <roland@xxxxxxxxxxxxx>
+
+	* configure.in (NO_CTORS_DTORS_SECTIONS): Give this check its own
+	AC_CACHE_CHECK invocation.
+	* configure: Regenerated.
+
+	* elf/soinit.c (__CTOR_LIST__, __DTOR_LIST__): Add used attribute.
+
+2011-06-27  Ulrich Drepper  <drepper@xxxxxxxxx>
+
+	[BZ #12350]
+	* nscd/aicache.c (addhstaiX):  Restore only RES_USE_INET6
+	bit from old_res_options.
+
+	* sysdeps/unix/sysv/linux/Makefile (CFLAGS-servicescache.c): Define.
+
+	* inet/getnetgrent_r.c (innetgr): Minimal cleanup, use correct return
+	value type for setfct.
+
 2011-06-23  H.J. Lu  <hongjiu.lu@xxxxxxxxx>
 
 	* sysdeps/unix/sysv/linux/getsysstats.c (__get_nprocs): Use

Modified: fsf/trunk/libc/configure
==============================================================================
--- fsf/trunk/libc/configure (original)
+++ fsf/trunk/libc/configure Tue Jun 28 00:03:11 2011
@@ -6111,12 +6111,28 @@
 $as_echo "$libc_cv_initfini_array" >&6; }
   if test $libc_cv_initfini_array != yes; then
     as_fn_error $? "Need linker with .init_array/.fini_array support." "$LINENO" 5
-  elif { ac_try='${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&5'
+  fi
+
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use .ctors/.dtors header and trailer" >&5
+$as_echo_n "checking whether to use .ctors/.dtors header and trailer... " >&6; }
+if ${libc_cv_ctors_header+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+    if { ac_try='${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&5'
   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
   (eval $ac_try) 2>&5
   ac_status=$?
   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
   test $ac_status = 0; }; }; then
+    libc_cv_ctors_header=no
+  else
+    libc_cv_ctors_header=yes
+  fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_ctors_header" >&5
+$as_echo "$libc_cv_ctors_header" >&6; }
+
+  if test $libc_cv_ctors_header = no; then
     $as_echo "#define NO_CTORS_DTORS_SECTIONS 1" >>confdefs.h
 
   fi

Modified: fsf/trunk/libc/configure.in
==============================================================================
--- fsf/trunk/libc/configure.in (original)
+++ fsf/trunk/libc/configure.in Tue Jun 28 00:03:11 2011
@@ -1479,7 +1479,17 @@
   rm -f conftest*])
   if test $libc_cv_initfini_array != yes; then
     AC_MSG_ERROR([Need linker with .init_array/.fini_array support.])
-  elif AC_TRY_COMMAND([${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&AS_MESSAGE_LOG_FD]); then
+  fi
+
+  AC_CACHE_CHECK(whether to use .ctors/.dtors header and trailer,
+		 libc_cv_ctors_header, [dnl
+  if AC_TRY_COMMAND([${CC-cc} -Wl,--verbose 2>&1|grep SORT_BY_INIT_PRIORITY 1>&AS_MESSAGE_LOG_FD]); then
+    libc_cv_ctors_header=no
+  else
+    libc_cv_ctors_header=yes
+  fi])
+
+  if test $libc_cv_ctors_header = no; then
     AC_DEFINE(NO_CTORS_DTORS_SECTIONS)
   fi
 

Modified: fsf/trunk/libc/elf/soinit.c
==============================================================================
--- fsf/trunk/libc/elf/soinit.c (original)
+++ fsf/trunk/libc/elf/soinit.c Tue Jun 28 00:03:11 2011
@@ -8,11 +8,11 @@
 # include <stdlib.h>
 
 static void (*const __CTOR_LIST__[1]) (void)
-     __attribute__ ((section (".ctors")))
-     = { (void (*) (void)) -1 };
+  __attribute__ ((used, section (".ctors")))
+  = { (void (*) (void)) -1 };
 static void (*const __DTOR_LIST__[1]) (void)
-     __attribute__ ((section (".dtors")))
-     = { (void (*) (void)) -1 };
+  __attribute__ ((used, section (".dtors")))
+  = { (void (*) (void)) -1 };
 
 static inline void
 run_hooks (void (*const list[]) (void))

Modified: fsf/trunk/libc/inet/getnetgrent_r.c
==============================================================================
--- fsf/trunk/libc/inet/getnetgrent_r.c (original)
+++ fsf/trunk/libc/inet/getnetgrent_r.c Tue Jun 28 00:03:11 2011
@@ -339,7 +339,7 @@
 {
   union
   {
-    int (*f) (const char *, struct __netgrent *);
+    enum nss_status (*f) (const char *, struct __netgrent *);
     void *ptr;
   } setfct;
   void (*endfct) (struct __netgrent *);

Modified: fsf/trunk/libc/nscd/aicache.c
==============================================================================
--- fsf/trunk/libc/nscd/aicache.c (original)
+++ fsf/trunk/libc/nscd/aicache.c Tue Jun 28 00:03:11 2011
@@ -534,7 +534,7 @@
    }
 
  out:
-  _res.options = old_res_options;
+  _res.options |= old_res_options & RES_USE_INET6;
 
   if (dataset != NULL && !alloca_used)
     {

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/Makefile
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/Makefile (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/Makefile Tue Jun 28 00:03:11 2011
@@ -167,5 +167,6 @@
 CFLAGS-hstcache.c += -DHAVE_SENDFILE
 CFLAGS-aicache.c += -DHAVE_SENDFILE
 CFLAGS-initgrcache.c += -DHAVE_SENDFILE
+CFLAGS-servicescache.c += -DHAVE_SENDFILE
 CFLAGS-gai.c += -DNEED_NETLINK
 endif