about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog31
-rw-r--r--config.h.in4
-rwxr-xr-xconfigure177
-rw-r--r--configure.in22
-rw-r--r--include/libc-symbols.h30
-rw-r--r--manual/errno.texi10
-rw-r--r--sysdeps/mach/hurd/bits/errno.h2
7 files changed, 203 insertions, 73 deletions
diff --git a/ChangeLog b/ChangeLog
index 8be8973e08..614985f457 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,34 @@
+2002-08-26  Roland McGrath  <roland@redhat.com>
+
+	* manual/errno.texi (Error Codes): Added ECANCELED (118 for Hurd).
+	* sysdeps/mach/hurd/bits/errno.h: Regenerated.
+
+	* sysdeps/gnu/Versions: New file.
+	* sysdeps/unix/sysv/linux/Versions (libc: GLIBC_2.1): Remove
+	_sys_errlist; sys_errlist; _sys_nerr; sys_nerr; from here.
+	* sysdeps/gnu/Makefile ($(..)sysdeps/gnu/errlist-compat.c): New target.
+	($(objpfx)errlist.d): Depend on $(..)sysdeps/gnu/errlist-compat.c.
+	* sysdeps/gnu/errlist.awk: Make output define _sys_errlist_internal
+	and _sys_nerr_internal instead of anything else.  Make it include
+	"errlist-compat.c" if [!NOT_IN_libc && !ERRLIST_NO_COMPAT].
+	Make it emit some asm magic if [EMIT_ERR_MAX].
+	* sysdeps/gnu/errlist.c: Regenerated.
+	* sysdeps/gnu/errlist-compat.awk: New file.
+	* sysdeps/gnu/errlist-compat.c: New file (generated).
+	* sysdeps/mach/hurd/errlist.c (ERRLIST_NO_COMPAT): New macro.
+	(_sys_errlist_internal): Define this as	a macro for _hurd_errlist.
+	(_sys_nerr_internal): Define this is a macro for _hurd_nerr.
+	(SYS_ERRLIST, SYS_NERR): Macros removed.
+	(sys_nerr, _sys_nerr): Remove these weak aliases.
+	* sysdeps/unix/sysv/linux/errlist.c: File removed.
+	* sysdeps/unix/sysv/linux/errlist.h: File removed.
+	* sysdeps/unix/sysv/linux/arm/errlist.c: File removed.
+
+	* include/libc-symbols.h (declare_symbol): New macro.
+	* config.h.in (ASM_TYPE_DIRECTIVE_PREFIX): New #undef.
+	* configure.in: New check to define it.
+	* configure: Regenerated.
+
 2002-08-27  Ulrich Drepper  <drepper@redhat.com>
 
 	* nss/getXXbyYY_r.c (REENTRANT_NAME): If no service is available
diff --git a/config.h.in b/config.h.in
index 014d841187..84e1e04a73 100644
--- a/config.h.in
+++ b/config.h.in
@@ -51,6 +51,10 @@
    declaring a symbol global (default `.globl').  */
 #undef	ASM_GLOBAL_DIRECTIVE
 
+/* Define to the prefix before `object' or `function' in the
+   assembler's `.type' directive, if it has one.  */
+#undef	ASM_TYPE_DIRECTIVE_PREFIX
+
 /* Define a symbol_name as a global .symbol_name for ld.  */
 #undef	HAVE_ASM_GLOBAL_DOT_NAME
 
diff --git a/configure b/configure
index ea8e061adb..14b2fa9968 100755
--- a/configure
+++ b/configure
@@ -2658,6 +2658,37 @@ EOF
 
 fi
 
+echo $ac_n "checking for assembler .type directive prefix""... $ac_c" 1>&6
+echo "configure:2663: checking for assembler .type directive prefix" >&5
+if eval "test \"`echo '$''{'libc_cv_asm_type_prefix'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  libc_cv_asm_type_prefix=no
+for ac_try_prefix in '@' '%' '#'; do
+  cat > conftest.s <<EOF
+	${libc_cv_dot_text}
+	${libc_cv_asm_global_directive} foo
+	.type foo, ${ac_try_prefix}object
+	.size foo, 1
+foo:
+	.byte 1
+EOF
+  if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
+    libc_cv_asm_type_prefix=${ac_try_prefix}
+  fi
+  rm -f conftest*
+  test "x$libc_cv_asm_type_prefix" != xno && break
+done
+fi
+
+echo "$ac_t""$libc_cv_asm_type_prefix" 1>&6
+if test "x$libc_cv_asm_type_prefix" != xno; then
+  cat >> confdefs.h <<EOF
+#define ASM_TYPE_DIRECTIVE_PREFIX ${libc_cv_asm_type_prefix}
+EOF
+
+fi
+
 # The Aix ld uses global .symbol_names instead of symbol_names.
 case "$os" in
 aix4.3*)
@@ -2668,7 +2699,7 @@ EOF
 esac
 
 echo $ac_n "checking for .symver assembler directive""... $ac_c" 1>&6
-echo "configure:2672: checking for .symver assembler directive" >&5
+echo "configure:2703: checking for .symver assembler directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_symver_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2687,7 +2718,7 @@ fi
 
 echo "$ac_t""$libc_cv_asm_symver_directive" 1>&6
 echo $ac_n "checking for ld --version-script""... $ac_c" 1>&6
-echo "configure:2691: checking for ld --version-script" >&5
+echo "configure:2722: checking for ld --version-script" >&5
 if eval "test \"`echo '$''{'libc_cv_ld_version_script_option'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2710,7 +2741,7 @@ EOF
     if { ac_try='${CC-cc} $CFLAGS -shared -o conftest.so conftest.o
 					-nostartfiles -nostdlib
 					-Wl,--version-script,conftest.map
-		       1>&5'; { (eval echo configure:2714: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
+		       1>&5'; { (eval echo configure:2745: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
     then
       libc_cv_ld_version_script_option=yes
     else
@@ -2749,7 +2780,7 @@ if test $elf = yes && test $shared != no && test $VERSIONING = no; then
 fi
 if test $elf = yes; then
   echo $ac_n "checking for .previous assembler directive""... $ac_c" 1>&6
-echo "configure:2753: checking for .previous assembler directive" >&5
+echo "configure:2784: checking for .previous assembler directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_previous_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2757,7 +2788,7 @@ else
 .section foo_section
 .previous
 EOF
-  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2761: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2792: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
     libc_cv_asm_previous_directive=yes
   else
     libc_cv_asm_previous_directive=no
@@ -2773,7 +2804,7 @@ EOF
 
   else
     echo $ac_n "checking for .popsection assembler directive""... $ac_c" 1>&6
-echo "configure:2777: checking for .popsection assembler directive" >&5
+echo "configure:2808: checking for .popsection assembler directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_popsection_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2781,7 +2812,7 @@ else
 .pushsection foo_section
 .popsection
 EOF
-    if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+    if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
       libc_cv_asm_popsection_directive=yes
     else
       libc_cv_asm_popsection_directive=no
@@ -2798,7 +2829,7 @@ EOF
     fi
   fi
   echo $ac_n "checking for .protected and .hidden assembler directive""... $ac_c" 1>&6
-echo "configure:2802: checking for .protected and .hidden assembler directive" >&5
+echo "configure:2833: checking for .protected and .hidden assembler directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_protected_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2808,7 +2839,7 @@ foo:
 .hidden bar
 bar:
 EOF
-  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2812: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:2843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
     libc_cv_asm_protected_directive=yes
   else
     libc_cv_asm_protected_directive=no
@@ -2829,7 +2860,7 @@ EOF
 
   if test $libc_cv_asm_protected_directive = yes; then
     echo $ac_n "checking whether __attribute__((visibility())) is supported""... $ac_c" 1>&6
-echo "configure:2833: checking whether __attribute__((visibility())) is supported" >&5
+echo "configure:2864: checking whether __attribute__((visibility())) is supported" >&5
 if eval "test \"`echo '$''{'libc_cv_visibility_attribute'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2860,7 +2891,7 @@ EOF
 
   if test $libc_cv_visibility_attribute = yes; then
     echo $ac_n "checking for broken __attribute__((visibility()))""... $ac_c" 1>&6
-echo "configure:2864: checking for broken __attribute__((visibility()))" >&5
+echo "configure:2895: checking for broken __attribute__((visibility()))" >&5
 if eval "test \"`echo '$''{'libc_cv_broken_visibility_attribute'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2889,7 +2920,7 @@ EOF
   fi
 
   echo $ac_n "checking for broken __attribute__((alias()))""... $ac_c" 1>&6
-echo "configure:2893: checking for broken __attribute__((alias()))" >&5
+echo "configure:2924: checking for broken __attribute__((alias()))" >&5
 if eval "test \"`echo '$''{'libc_cv_broken_alias_attribute'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2922,7 +2953,7 @@ EOF
 
   if test $libc_cv_visibility_attribute = yes -a $gnu_ld = yes; then
     echo $ac_n "checking whether to put _rtld_local into .sdata section""... $ac_c" 1>&6
-echo "configure:2926: checking whether to put _rtld_local into .sdata section" >&5
+echo "configure:2957: checking whether to put _rtld_local into .sdata section" >&5
 if eval "test \"`echo '$''{'libc_cv_have_sdata_section'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2946,7 +2977,7 @@ EOF
   fi
 
   echo $ac_n "checking for .preinit_array/.init_array/.fini_array support""... $ac_c" 1>&6
-echo "configure:2950: checking for .preinit_array/.init_array/.fini_array support" >&5
+echo "configure:2981: checking for .preinit_array/.init_array/.fini_array support" >&5
 if eval "test \"`echo '$''{'libc_cv_initfinit_array'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2957,7 +2988,7 @@ int foo (void) { return 1; }
 int (*fp) (void) __attribute__ ((section (".init_array"))) = foo;
 EOF
   if { ac_try='${CC-cc} -o conftest conftest.c
-		     -static -nostartfiles -nostdlib 1>&5'; { (eval echo configure:2961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+		     -static -nostartfiles -nostdlib 1>&5'; { (eval echo configure:2992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     if readelf -S conftest | fgrep INIT_ARRAY > /dev/null; then
       libc_cv_initfinit_array=yes
@@ -2980,7 +3011,7 @@ EOF
   fi
 
   echo $ac_n "checking for -z nodelete option""... $ac_c" 1>&6
-echo "configure:2984: checking for -z nodelete option" >&5
+echo "configure:3015: checking for -z nodelete option" >&5
 if eval "test \"`echo '$''{'libc_cv_z_nodelete'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2989,7 +3020,7 @@ int _start (void) { return 42; }
 EOF
   if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
 		     -nostartfiles -nostdlib
-		     -Wl,--enable-new-dtags,-z,nodelete 1>&5'; { (eval echo configure:2993: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+		     -Wl,--enable-new-dtags,-z,nodelete 1>&5'; { (eval echo configure:3024: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     libc_cv_z_nodelete=yes
   else
@@ -3002,7 +3033,7 @@ echo "$ac_t""$libc_cv_z_nodelete" 1>&6
   
 
   echo $ac_n "checking for -z nodlopen option""... $ac_c" 1>&6
-echo "configure:3006: checking for -z nodlopen option" >&5
+echo "configure:3037: checking for -z nodlopen option" >&5
 if eval "test \"`echo '$''{'libc_cv_z_nodlopen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3011,7 +3042,7 @@ int _start (void) { return 42; }
 EOF
   if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
 			-nostartfiles -nostdlib
-			-Wl,--enable-new-dtags,-z,nodlopen 1>&5'; { (eval echo configure:3015: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+			-Wl,--enable-new-dtags,-z,nodlopen 1>&5'; { (eval echo configure:3046: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     libc_cv_z_nodlopen=yes
   else
@@ -3024,7 +3055,7 @@ echo "$ac_t""$libc_cv_z_nodlopen" 1>&6
   
 
   echo $ac_n "checking for -z initfirst option""... $ac_c" 1>&6
-echo "configure:3028: checking for -z initfirst option" >&5
+echo "configure:3059: checking for -z initfirst option" >&5
 if eval "test \"`echo '$''{'libc_cv_z_initfirst'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3033,7 +3064,7 @@ int _start (void) { return 42; }
 EOF
   if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
 			-nostartfiles -nostdlib
-			-Wl,--enable-new-dtags,-z,initfirst 1>&5'; { (eval echo configure:3037: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+			-Wl,--enable-new-dtags,-z,initfirst 1>&5'; { (eval echo configure:3068: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     libc_cv_z_initfirst=yes
   else
@@ -3046,14 +3077,14 @@ echo "$ac_t""$libc_cv_z_initfirst" 1>&6
   
 
   echo $ac_n "checking for -Bgroup option""... $ac_c" 1>&6
-echo "configure:3050: checking for -Bgroup option" >&5
+echo "configure:3081: checking for -Bgroup option" >&5
 if eval "test \"`echo '$''{'libc_cv_Bgroup'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
     cat > conftest.c <<EOF
 int _start (void) { return 42; }
 EOF
-  if { ac_try='${CC-cc} -shared -o conftest.so conftest.c -Wl,-Bgroup -nostdlib 1>&5'; { (eval echo configure:3057: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+  if { ac_try='${CC-cc} -shared -o conftest.so conftest.c -Wl,-Bgroup -nostdlib 1>&5'; { (eval echo configure:3088: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     libc_cv_Bgroup=yes
   else
@@ -3066,7 +3097,7 @@ echo "$ac_t""$libc_cv_Bgroup" 1>&6
   
 
   echo $ac_n "checking for -z combreloc""... $ac_c" 1>&6
-echo "configure:3070: checking for -z combreloc" >&5
+echo "configure:3101: checking for -z combreloc" >&5
 if eval "test \"`echo '$''{'libc_cv_z_combreloc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3077,7 +3108,7 @@ int foo (void) { return bar (mumble); }
 EOF
   if { ac_try='${CC-cc} -shared -o conftest.so conftest.c
 			-nostdlib -nostartfiles
-			-Wl,-z,combreloc 1>&5'; { (eval echo configure:3081: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
+			-Wl,-z,combreloc 1>&5'; { (eval echo configure:3112: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }
   then
     if readelf -S conftest.so | grep '\.rel\(a\|\)\.dyn' > /dev/null; then
       libc_cv_z_combreloc=yes
@@ -3102,12 +3133,12 @@ fi
 
 if test $elf != yes; then
   echo $ac_n "checking for .init and .fini sections""... $ac_c" 1>&6
-echo "configure:3106: checking for .init and .fini sections" >&5
+echo "configure:3137: checking for .init and .fini sections" >&5
 if eval "test \"`echo '$''{'libc_cv_have_initfini'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3111 "configure"
+#line 3142 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -3116,7 +3147,7 @@ asm (".section .init");
 				    asm ("${libc_cv_dot_text}");
 ; return 0; }
 EOF
-if { (eval echo configure:3120: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3151: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   libc_cv_have_initfini=yes
 else
@@ -3139,7 +3170,7 @@ fi
 
 if test $elf = yes -a $gnu_ld = yes; then
   echo $ac_n "checking whether cc puts quotes around section names""... $ac_c" 1>&6
-echo "configure:3143: checking whether cc puts quotes around section names" >&5
+echo "configure:3174: checking whether cc puts quotes around section names" >&5
 if eval "test \"`echo '$''{'libc_cv_have_section_quotes'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3176,19 +3207,19 @@ if test $elf = yes; then
 else
   if test $ac_cv_prog_cc_works = yes; then
     echo $ac_n "checking for _ prefix on C symbol names""... $ac_c" 1>&6
-echo "configure:3180: checking for _ prefix on C symbol names" >&5
+echo "configure:3211: checking for _ prefix on C symbol names" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_underscores'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3185 "configure"
+#line 3216 "configure"
 #include "confdefs.h"
 asm ("_glibc_foobar:");
 int main() {
 glibc_foobar ();
 ; return 0; }
 EOF
-if { (eval echo configure:3192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   libc_cv_asm_underscores=yes
 else
@@ -3203,17 +3234,17 @@ fi
 echo "$ac_t""$libc_cv_asm_underscores" 1>&6
   else
     echo $ac_n "checking for _ prefix on C symbol names""... $ac_c" 1>&6
-echo "configure:3207: checking for _ prefix on C symbol names" >&5
+echo "configure:3238: checking for _ prefix on C symbol names" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_underscores'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3212 "configure"
+#line 3243 "configure"
 #include "confdefs.h"
 void underscore_test(void) {
 return; }
 EOF
-if { (eval echo configure:3217: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3248: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   if grep _underscore_test conftest* >/dev/null; then
     rm -f conftest*
     libc_cv_asm_underscores=yes
@@ -3245,7 +3276,7 @@ if test $elf = yes; then
 fi
 
 echo $ac_n "checking for assembler .weak directive""... $ac_c" 1>&6
-echo "configure:3249: checking for assembler .weak directive" >&5
+echo "configure:3280: checking for assembler .weak directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_weak_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3268,7 +3299,7 @@ echo "$ac_t""$libc_cv_asm_weak_directive" 1>&6
 
 if test $libc_cv_asm_weak_directive = no; then
   echo $ac_n "checking for assembler .weakext directive""... $ac_c" 1>&6
-echo "configure:3272: checking for assembler .weakext directive" >&5
+echo "configure:3303: checking for assembler .weakext directive" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_weakext_directive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3315,14 +3346,14 @@ EOF
     ;;
   hppa*linux*)
   echo $ac_n "checking for assembler line separator""... $ac_c" 1>&6
-echo "configure:3319: checking for assembler line separator" >&5
+echo "configure:3350: checking for assembler line separator" >&5
 if eval "test \"`echo '$''{'libc_cv_asm_line_sep'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
     cat > conftest.s <<EOF
  nop ; is_old_puffin
 EOF
-  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:3326: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+  if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'; { (eval echo configure:3357: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
     libc_cv_asm_line_sep='!'
   else
     if test -z "$enable_hacker_mode"; then
@@ -3344,7 +3375,7 @@ EOF
 esac
 
 echo $ac_n "checking for ld --no-whole-archive""... $ac_c" 1>&6
-echo "configure:3348: checking for ld --no-whole-archive" >&5
+echo "configure:3379: checking for ld --no-whole-archive" >&5
 if eval "test \"`echo '$''{'libc_cv_ld_no_whole_archive'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3355,7 +3386,7 @@ __throw () {}
 EOF
 if { ac_try='${CC-cc} $CFLAGS
 			    -nostdlib -nostartfiles -Wl,--no-whole-archive
-			    -o conftest conftest.c 1>&5'; { (eval echo configure:3359: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			    -o conftest conftest.c 1>&5'; { (eval echo configure:3390: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_ld_no_whole_archive=yes
 else
   libc_cv_ld_no_whole_archive=no
@@ -3369,7 +3400,7 @@ if test $libc_cv_ld_no_whole_archive = yes; then
 fi
 
 echo $ac_n "checking for gcc -fexceptions""... $ac_c" 1>&6
-echo "configure:3373: checking for gcc -fexceptions" >&5
+echo "configure:3404: checking for gcc -fexceptions" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_exceptions'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3380,7 +3411,7 @@ __throw () {}
 EOF
 if { ac_try='${CC-cc} $CFLAGS
 			    -nostdlib -nostartfiles -fexceptions
-			    -o conftest conftest.c 1>&5'; { (eval echo configure:3384: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			    -o conftest conftest.c 1>&5'; { (eval echo configure:3415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_gcc_exceptions=yes
 else
   libc_cv_gcc_exceptions=no
@@ -3395,14 +3426,14 @@ fi
 
 if test "$base_machine" = alpha ; then
 echo $ac_n "checking for function ..ng prefix""... $ac_c" 1>&6
-echo "configure:3399: checking for function ..ng prefix" >&5
+echo "configure:3430: checking for function ..ng prefix" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_alpha_ng_prefix'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.c <<\EOF
 foo () { }
 EOF
-if { ac_try='${CC-cc} -S conftest.c -o - | fgrep "\$foo..ng" > /dev/null'; { (eval echo configure:3406: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
+if { ac_try='${CC-cc} -S conftest.c -o - | fgrep "\$foo..ng" > /dev/null'; { (eval echo configure:3437: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
 then
   libc_cv_gcc_alpha_ng_prefix=yes
 else
@@ -3429,19 +3460,19 @@ if test "$host_cpu" = powerpc ; then
 # Check for a bug present in at least versions 2.8.x of GCC
 # and versions 1.0.x of EGCS.
 echo $ac_n "checking whether clobbering cr0 causes problems""... $ac_c" 1>&6
-echo "configure:3433: checking whether clobbering cr0 causes problems" >&5
+echo "configure:3464: checking whether clobbering cr0 causes problems" >&5
 if eval "test \"`echo '$''{'libc_cv_c_asmcr0_bug'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3438 "configure"
+#line 3469 "configure"
 #include "confdefs.h"
 int tester(int x) { asm ("" : : : "cc"); return x & 123; }
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:3445: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   libc_cv_c_asmcr0_bug='no'
 else
@@ -3463,12 +3494,12 @@ fi
 fi
 
 echo $ac_n "checking for DWARF2 unwind info support""... $ac_c" 1>&6
-echo "configure:3467: checking for DWARF2 unwind info support" >&5
+echo "configure:3498: checking for DWARF2 unwind info support" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_dwarf2_unwind_info'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.c <<EOF
-#line 3472 "configure"
+#line 3503 "configure"
 static char *__EH_FRAME_BEGIN__;
 _start ()
 {
@@ -3495,14 +3526,14 @@ __bzero () {}
 EOF
 if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame_info
 			    -nostdlib -nostartfiles
-			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3499: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3530: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_gcc_dwarf2_unwind_info=static
 else
   libc_cv_gcc_dwarf2_unwind_info=no
 fi
 if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame_info
                             -nostdlib -nostartfiles
-                            -o conftest conftest.c -lgcc -lgcc_eh >&5'; { (eval echo configure:3506: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+                            -o conftest conftest.c -lgcc -lgcc_eh >&5'; { (eval echo configure:3537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   if ${CC-cc} $CFLAGS -DCHECK__register_frame_info -nostdlib -nostartfiles \
      -o conftest conftest.c -lgcc -lgcc_eh -v 2>&1 >/dev/null \
      | grep -q -- --eh-frame-hdr; then
@@ -3516,7 +3547,7 @@ fi
 if test $libc_cv_gcc_dwarf2_unwind_info = no; then
   if { ac_try='${CC-cc} $CFLAGS -DCHECK__register_frame
 			      -nostdlib -nostartfiles
-			      -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3520: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			      -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3551: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
     libc_cv_gcc_dwarf2_unwind_info=yes
   else
     libc_cv_gcc_dwarf2_unwind_info=no
@@ -3546,12 +3577,12 @@ EOF
 esac
 
 echo $ac_n "checking for __builtin_expect""... $ac_c" 1>&6
-echo "configure:3550: checking for __builtin_expect" >&5
+echo "configure:3581: checking for __builtin_expect" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_builtin_expect'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.c <<EOF
-#line 3555 "configure"
+#line 3586 "configure"
 int foo (int a)
 {
   a = __builtin_expect (a, 10);
@@ -3559,7 +3590,7 @@ int foo (int a)
 }
 EOF
 if { ac_try='${CC-cc} $CFLAGS -nostdlib -nostartfiles
-			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3563: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3594: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_gcc_builtin_expect=yes
 else
   libc_cv_gcc_builtin_expect=no
@@ -3576,7 +3607,7 @@ EOF
 fi
 
 echo $ac_n "checking for __builtin_memset""... $ac_c" 1>&6
-echo "configure:3580: checking for __builtin_memset" >&5
+echo "configure:3611: checking for __builtin_memset" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_builtin_memset'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3586,7 +3617,7 @@ void zero (void *x)
   __builtin_memset (x, 0, 1000);
 }
 EOF
-if { ac_try='${CC-cc} -O3 -S conftest.c -o - | fgrep "memset" > /dev/null'; { (eval echo configure:3590: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
+if { ac_try='${CC-cc} -O3 -S conftest.c -o - | fgrep "memset" > /dev/null'; { (eval echo configure:3621: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; };
 then
   libc_cv_gcc_builtin_memset=no
 else
@@ -3604,12 +3635,12 @@ EOF
 fi
 
 echo $ac_n "checking for local label subtraction""... $ac_c" 1>&6
-echo "configure:3608: checking for local label subtraction" >&5
+echo "configure:3639: checking for local label subtraction" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc_subtract_local_labels'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.c <<EOF
-#line 3613 "configure"
+#line 3644 "configure"
 int foo (int a)
 {
   static const int ar[] = { &&l1 - &&l1, &&l2 - &&l1 };
@@ -3622,7 +3653,7 @@ int foo (int a)
 }
 EOF
 if { ac_try='${CC-cc} $CFLAGS -nostdlib -nostartfiles
-			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3626: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+			    -o conftest conftest.c -lgcc >&5'; { (eval echo configure:3657: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_gcc_subtract_local_labels=yes
 else
   libc_cv_gcc_subtract_local_labels=no
@@ -3639,14 +3670,14 @@ EOF
 fi
 
 echo $ac_n "checking for __thread""... $ac_c" 1>&6
-echo "configure:3643: checking for __thread" >&5
+echo "configure:3674: checking for __thread" >&5
 if eval "test \"`echo '$''{'libc_cv_gcc___thread'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.c <<EOF
 __thread int a = 42;
 EOF
-if { ac_try='${CC-cc} $CFLAGS -c conftest.c >&5'; { (eval echo configure:3650: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+if { ac_try='${CC-cc} $CFLAGS -c conftest.c >&5'; { (eval echo configure:3681: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
   libc_cv_gcc___thread=yes
 else
   libc_cv_gcc___thread=no
@@ -3664,7 +3695,7 @@ fi
 
 
 echo $ac_n "checking for libgd""... $ac_c" 1>&6
-echo "configure:3668: checking for libgd" >&5
+echo "configure:3699: checking for libgd" >&5
 if test "$with_gd" != "no"; then
   old_CFLAGS="$CFLAGS"
   CFLAGS="$CFLAGS $libgd_include"
@@ -3673,14 +3704,14 @@ if test "$with_gd" != "no"; then
   old_LIBS="$LIBS"
   LIBS="$LIBS -lgd -lpng -lz -lm"
   cat > conftest.$ac_ext <<EOF
-#line 3677 "configure"
+#line 3708 "configure"
 #include "confdefs.h"
 #include <gd.h>
 int main() {
 gdImagePng (0, 0)
 ; return 0; }
 EOF
-if { (eval echo configure:3684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   LIBGD=yes
 else
@@ -3700,7 +3731,7 @@ echo "$ac_t""$LIBGD" 1>&6
 
 
 echo $ac_n "checking size of long double""... $ac_c" 1>&6
-echo "configure:3704: checking size of long double" >&5
+echo "configure:3735: checking size of long double" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3708,7 +3739,7 @@ else
   ac_cv_sizeof_long_double=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 3712 "configure"
+#line 3743 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -3719,7 +3750,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:3723: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_double=`cat conftestval`
 else
@@ -3797,7 +3828,7 @@ if test "$uname" = "sysdeps/generic"; then
   fi
 
   echo $ac_n "checking OS release for uname""... $ac_c" 1>&6
-echo "configure:3801: checking OS release for uname" >&5
+echo "configure:3832: checking OS release for uname" >&5
 if eval "test \"`echo '$''{'libc_cv_uname_release'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3819,7 +3850,7 @@ echo "$ac_t""$libc_cv_uname_release" 1>&6
   uname_release="$libc_cv_uname_release"
 
   echo $ac_n "checking OS version for uname""... $ac_c" 1>&6
-echo "configure:3823: checking OS version for uname" >&5
+echo "configure:3854: checking OS version for uname" >&5
 if eval "test \"`echo '$''{'libc_cv_uname_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3848,7 +3879,7 @@ EOF
 # Test for old glibc 2.0.x headers so that they can be removed properly
 # Search only in includedir.
 echo $ac_n "checking for old glibc 2.0.x headers""... $ac_c" 1>&6
-echo "configure:3852: checking for old glibc 2.0.x headers" >&5
+echo "configure:3883: checking for old glibc 2.0.x headers" >&5
 if eval test -f "${includedir}/elfclass.h" -a -f "${includedir}/fcntlbits.h"
 then
   old_glibc_headers=yes
@@ -3909,7 +3940,7 @@ if test $shared = default; then
 fi
 
 echo $ac_n "checking whether -fPIC is default""... $ac_c" 1>&6
-echo "configure:3913: checking whether -fPIC is default" >&5
+echo "configure:3944: checking whether -fPIC is default" >&5
 if eval "test \"`echo '$''{'pic_default'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
diff --git a/configure.in b/configure.in
index f6a0fcb556..a467745635 100644
--- a/configure.in
+++ b/configure.in
@@ -871,6 +871,28 @@ if test $libc_cv_asm_set_directive = yes; then
   AC_DEFINE(HAVE_ASM_SET_DIRECTIVE)
 fi
 
+AC_CACHE_CHECK(for assembler .type directive prefix,
+	       libc_cv_asm_type_prefix, [dnl
+libc_cv_asm_type_prefix=no
+for ac_try_prefix in '@' '%' '#'; do
+  cat > conftest.s <<EOF
+	${libc_cv_dot_text}
+	${libc_cv_asm_global_directive} foo
+	.type foo, ${ac_try_prefix}object
+	.size foo, 1
+foo:
+	.byte 1
+EOF
+  if ${CC-cc} $CFLAGS -c conftest.s 2>/dev/null; then
+    libc_cv_asm_type_prefix=${ac_try_prefix}
+  fi
+  rm -f conftest*
+  test "x$libc_cv_asm_type_prefix" != xno && break
+done])
+if test "x$libc_cv_asm_type_prefix" != xno; then
+  AC_DEFINE_UNQUOTED(ASM_TYPE_DIRECTIVE_PREFIX, ${libc_cv_asm_type_prefix})
+fi
+
 # The Aix ld uses global .symbol_names instead of symbol_names.
 case "$os" in
 aix4.3*)
diff --git a/include/libc-symbols.h b/include/libc-symbols.h
index dcc4712f7d..bf77fda8d6 100644
--- a/include/libc-symbols.h
+++ b/include/libc-symbols.h
@@ -29,6 +29,8 @@
 
    * HAVE_ASM_SET_DIRECTIVE if we have `.set B, A' instead of `A = B'.
    * ASM_GLOBAL_DIRECTIVE with `.globl' or `.global'.
+   * ASM_TYPE_DIRECTIVE_PREFIX with `@' or `#' or whatever for .type,
+     or leave it undefined if there is no .type directive.
    * HAVE_GNU_LD if using GNU ld, with support for weak symbols in a.out,
    and for symbol set and warning messages extensions in a.out and ELF.
    * HAVE_ELF if using ELF, which supports weak symbols using `.weak'.
@@ -244,6 +246,34 @@
   link_warning (name, \
 		"warning: " #name " is not implemented and will always fail")
 
+
+/* Declare SYMBOL to be TYPE (`function' or `object') and of SIZE bytes,
+   when the assembler supports such declarations (such as in ELF).
+   This is only necessary when defining something in assembly, or playing
+   funny alias games where the size should be other than what the compiler
+   thinks it is.  */
+#define declare_symbol(symbol, type, size) \
+  declare_symbol_1 (symbol, type, size)
+#ifdef ASM_TYPE_DIRECTIVE_PREFIX
+# ifdef __ASSEMBLER__
+#  define declare_symbol_1(symbol, type, size) \
+    .type C_SYMBOL_NAME (symbol), \
+	  declare_symbol_1_paste (ASM_TYPE_DIRECTIVE_PREFIX, type), size
+#  define declare_symbol_1_paste(a, b)	declare_symbol_1_paste_1 (a,b)
+#  define declare_symbol_1_paste_1(a,b)	a##b
+# else /* Not __ASSEMBLER__.  */
+#  define declare_symbol_1(symbol, type, size) \
+    asm (".type " __SYMBOL_PREFIX #symbol \
+	 declare_symbol_1_stringify (ASM_TYPE_DIRECTIVE_PREFIX) #type \
+	 "\n\t.size " __SYMBOL_PREFIX #symbol ", " #size);
+#  define declare_symbol_1_stringify(x) declare_symbol_1_stringify_1 (x)
+#  define declare_symbol_1_stringify_1(x) #x
+# endif /* __ASSEMBLER__ */
+#else
+# define declare_symbol_1(symbol, type, size) /* Nothing.  */
+#endif
+
+
 /*
 
 */
diff --git a/manual/errno.texi b/manual/errno.texi
index ee0a6210fc..c799d268f8 100644
--- a/manual/errno.texi
+++ b/manual/errno.texi
@@ -981,6 +981,16 @@ This error code has no purpose.
 @comment errno 117
 @end deftypevr
 
+@comment errno.h
+@comment POSIX.1: Operation canceled
+@deftypevr Macro int ECANCELED
+@comment errno 118
+Operation canceled; an asynchronous operation was canceled before it
+completed.  @xref{Asynchronous I/O}.  When you call @code{aio_cancel},
+the normal result is for the operations affected to complete with this
+error; @pxref{Cancel AIO Operations}.
+@end deftypevr
+
 
 @emph{The following error codes are defined by the Linux/i386 kernel.
 They are not yet documented.}
diff --git a/sysdeps/mach/hurd/bits/errno.h b/sysdeps/mach/hurd/bits/errno.h
index e5d208c8f5..a7d57adeb6 100644
--- a/sysdeps/mach/hurd/bits/errno.h
+++ b/sysdeps/mach/hurd/bits/errno.h
@@ -212,6 +212,8 @@ enum __error_t_codes
 #define	EPROTO          _HURD_ERRNO (116)/* Protocol error */
 	ETIME           = _HURD_ERRNO (117),
 #define	ETIME           _HURD_ERRNO (117)/* Timer expired */
+	ECANCELED       = _HURD_ERRNO (118),
+#define	ECANCELED       _HURD_ERRNO (118)/* Operation canceled */
 
 	/* Errors from <mach/message.h>.  */
 	EMACH_SEND_IN_PROGRESS          = 0x10000001,