diff options
| author | Ulrich Drepper <drepper@redhat.com> | 2007-03-17 17:04:28 +0000 |
|---|---|---|
| committer | Ulrich Drepper <drepper@redhat.com> | 2007-03-17 17:04:28 +0000 |
| commit | b037a293a48718af30d706c2e18c929d0e69a621 (patch) | |
| tree | c92ad78668ac60e155f6d3cd18a7d005e9f4a457 | |
| parent | 63375de01e89283a60c045591c573cf2f51ee368 (diff) | |
| download | glibc-b037a293a48718af30d706c2e18c929d0e69a621.tar.xz glibc-b037a293a48718af30d706c2e18c929d0e69a621.zip | |
* configure.in (libc_cv_gnu89_inline): Test for -fgnu89-inline.
* config.make.in (gnu89-inline-CFLAGS): New variable.
* Makeconfig (CFLAGS): Use $(gnu89-inline-CFLAGS) together with
-std=gnu99.
* misc/sys/cdefs.h (__extern_inline, __extern_always_inline): Define.
* argp/argp.h: Use it.
* bits/mathinline.h: Likewise.
* bits/sigset.h: Likewise.
* bits/string.h: Likewise.
* ctype/ctype.h: Likewise.
* hurd/hurd.h: Likewise.
* hurd/hurd/fd.h: Likewise.
* hurd/hurd/port.h: Likewise.
* hurd/hurd/signal.h: Likewise.
* hurd/hurd/threadvar.h: Likewise.
* hurd/hurd/userlink.h: Likewise.
* io/sys/stat.h: Likewise.
* libio/bits/stdio.h: Likewise.
* libio/bits/stdio2.h: Likewise.
* mach/lock-intern.h: Likewise.
* mach/mach/mig_support.h: Likewise.
* math/bits/cmathcalls.h: Likewise.
* posix/bits/unistd.h: Likewise.
* socket/bits/socket2.h: Likewise.
* stdlib/bits/stdlib.h: Likewise.
* stdlib/stdlib.h: Likewise.
* string/argz.h: Likewise.
* string/bits/string2.h: Likewise.
* string/bits/string3.h: Likewise.
* sysdeps/alpha/fpu/bits/mathinline.h: Likewise.
* sysdeps/generic/inttypes.h: Likewise.
* sysdeps/generic/machine-lock.h: Likewise.
* sysdeps/generic/machine-sp.h: Likewise.
* sysdeps/i386/fpu/bits/mathinline.h: Likewise.
* sysdeps/i386/i486/bits/string.h: Likewise.
* sysdeps/ia64/fpu/bits/mathinline.h: Likewise.
* sysdeps/mach/alpha/machine-lock.h: Likewise.
* sysdeps/mach/alpha/machine-sp.h: Likewise.
* sysdeps/mach/i386/machine-lock.h: Likewise.
* sysdeps/mach/powerpc/machine-lock.h: Likewise.
* sysdeps/mach/powerpc/machine-sp.h: Likewise.
* sysdeps/powerpc/fpu/bits/mathinline.h: Likewise.
* sysdeps/s390/bits/string.h: Likewise.
* sysdeps/s390/fpu/bits/mathinline.h: Likewise.
* sysdeps/sparc/fpu/bits/mathinline.h: Likewise.
* sysdeps/unix/bsd/bsd4.4/bits/socket.h: Likewise.
* sysdeps/unix/sysv/linux/bits/sigset.h: Likewise.
* sysdeps/unix/sysv/linux/bits/socket.h: Likewise.
* sysdeps/unix/sysv/linux/sys/sysmacros.h: Likewise.
* sysdeps/x86_64/fpu/bits/mathinline.h: Likewise.
* wcsmbs/bits/wchar2.h: Likewise.
* wcsmbs/wchar.h: Likewise.
* stdlib/gmp.h: Likewise. Include <features.h> to get
__extern_inline definition.
* locale/programs/ld-ctype.c (find_translit): Return NULL if ctype is
NULL.
56 files changed, 293 insertions, 183 deletions
@@ -1,5 +1,65 @@ +2007-03-16 Jakub Jelinek <jakub@redhat.com> + + * configure.in (libc_cv_gnu89_inline): Test for -fgnu89-inline. + * config.make.in (gnu89-inline-CFLAGS): New variable. + * Makeconfig (CFLAGS): Use $(gnu89-inline-CFLAGS) together with + -std=gnu99. + * misc/sys/cdefs.h (__extern_inline, __extern_always_inline): Define. + * argp/argp.h: Use it. + * bits/mathinline.h: Likewise. + * bits/sigset.h: Likewise. + * bits/string.h: Likewise. + * ctype/ctype.h: Likewise. + * hurd/hurd.h: Likewise. + * hurd/hurd/fd.h: Likewise. + * hurd/hurd/port.h: Likewise. + * hurd/hurd/signal.h: Likewise. + * hurd/hurd/threadvar.h: Likewise. + * hurd/hurd/userlink.h: Likewise. + * io/sys/stat.h: Likewise. + * libio/bits/stdio.h: Likewise. + * libio/bits/stdio2.h: Likewise. + * mach/lock-intern.h: Likewise. + * mach/mach/mig_support.h: Likewise. + * math/bits/cmathcalls.h: Likewise. + * posix/bits/unistd.h: Likewise. + * socket/bits/socket2.h: Likewise. + * stdlib/bits/stdlib.h: Likewise. + * stdlib/stdlib.h: Likewise. + * string/argz.h: Likewise. + * string/bits/string2.h: Likewise. + * string/bits/string3.h: Likewise. + * sysdeps/alpha/fpu/bits/mathinline.h: Likewise. + * sysdeps/generic/inttypes.h: Likewise. + * sysdeps/generic/machine-lock.h: Likewise. + * sysdeps/generic/machine-sp.h: Likewise. + * sysdeps/i386/fpu/bits/mathinline.h: Likewise. + * sysdeps/i386/i486/bits/string.h: Likewise. + * sysdeps/ia64/fpu/bits/mathinline.h: Likewise. + * sysdeps/mach/alpha/machine-lock.h: Likewise. + * sysdeps/mach/alpha/machine-sp.h: Likewise. + * sysdeps/mach/i386/machine-lock.h: Likewise. + * sysdeps/mach/powerpc/machine-lock.h: Likewise. + * sysdeps/mach/powerpc/machine-sp.h: Likewise. + * sysdeps/powerpc/fpu/bits/mathinline.h: Likewise. + * sysdeps/s390/bits/string.h: Likewise. + * sysdeps/s390/fpu/bits/mathinline.h: Likewise. + * sysdeps/sparc/fpu/bits/mathinline.h: Likewise. + * sysdeps/unix/bsd/bsd4.4/bits/socket.h: Likewise. + * sysdeps/unix/sysv/linux/bits/sigset.h: Likewise. + * sysdeps/unix/sysv/linux/bits/socket.h: Likewise. + * sysdeps/unix/sysv/linux/sys/sysmacros.h: Likewise. + * sysdeps/x86_64/fpu/bits/mathinline.h: Likewise. + * wcsmbs/bits/wchar2.h: Likewise. + * wcsmbs/wchar.h: Likewise. + * stdlib/gmp.h: Likewise. Include <features.h> to get + __extern_inline definition. + 2007-03-15 Jakub Jelinek <jakub@redhat.com> + * locale/programs/ld-ctype.c (find_translit): Return NULL if ctype is + NULL. + [BZ #3919] * math/libm-test.inc (log_test): Test -Inf and NaN. (log10_test, log1p_test, log2_test): Test -Inf. diff --git a/Makeconfig b/Makeconfig index 349f94d9ac..049e4ca83a 100644 --- a/Makeconfig +++ b/Makeconfig @@ -1,4 +1,4 @@ -# Copyright (C) 1991-2003,2004,2005,2006 Free Software Foundation, Inc. +# Copyright (C) 1991-2003,2004,2005,2006,2007 Free Software Foundation, Inc. # This file is part of the GNU C Library. # The GNU C Library is free software; you can redistribute it and/or @@ -672,7 +672,7 @@ CPPFLAGS = $($(subdir)-CPPFLAGS) $(+includes) $(defines) \ $(foreach lib,$(libof-$(basename $(@F))) \ $(libof-$(<F)) $(libof-$(@F)),$(CPPFLAGS-$(lib))) \ $(CPPFLAGS-$(<F)) $(CPPFLAGS-$(@F)) $(CPPFLAGS-$(basename $(@F))) -override CFLAGS = -std=gnu99 \ +override CFLAGS = -std=gnu99 $(gnu89-inline-CFLAGS) \ $(filter-out %frame-pointer,$(+cflags)) $(+gccwarn-c) \ $(sysdep-CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(<F)) \ $(CFLAGS-$(@F)) diff --git a/argp/argp.h b/argp/argp.h index 3a5cb01fd8..baf3afd826 100644 --- a/argp/argp.h +++ b/argp/argp.h @@ -1,5 +1,6 @@ /* Hierarchial argument parsing, layered over getopt. - Copyright (C) 1995-1999,2003,2004,2005,2006 Free Software Foundation, Inc. + Copyright (C) 1995-1999, 2003, 2004, 2005, 2006, 2007 + Free Software Foundation, Inc. This file is part of the GNU C Library. Written by Miles Bader <miles@gnu.ai.mit.edu>. @@ -558,7 +559,7 @@ extern void *__argp_input (__const struct argp *__restrict __argp, # endif # ifndef ARGP_EI -# define ARGP_EI extern __inline__ +# define ARGP_EI __extern_inline # endif ARGP_EI void diff --git a/bits/mathinline.h b/bits/mathinline.h index 5498af6b63..02ec21b438 100644 --- a/bits/mathinline.h +++ b/bits/mathinline.h @@ -1,6 +1,6 @@ /* This file should provide inline versions of math functions. - Surround GCC-specific parts with #ifdef __GNUC__, and use `extern __inline'. + Surround GCC-specific parts with #ifdef __GNUC__, and use `__extern_inline'. This file should define __MATH_INLINES if functions are actually defined as inlines. */ diff --git a/bits/sigset.h b/bits/sigset.h index 5fc8692df0..d6f9311e71 100644 --- a/bits/sigset.h +++ b/bits/sigset.h @@ -1,5 +1,6 @@ /* __sig_atomic_t, __sigset_t, and related definitions. Generic/BSD version. - Copyright (C) 1991, 1992, 1994, 1996, 1997 Free Software Foundation, Inc. + Copyright (C) 1991, 1992, 1994, 1996, 1997, 2007 + Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -38,7 +39,7 @@ typedef unsigned long int __sigset_t; #define _SIGSET_H_fns 1 #ifndef _EXTERN_INLINE -# define _EXTERN_INLINE extern __inline +# define _EXTERN_INLINE __extern_inline #endif /* Return a mask that includes SIG only. The cast to `sigset_t' avoids diff --git a/bits/string.h b/bits/string.h index ad68b038b6..f8630d2c52 100644 --- a/bits/string.h +++ b/bits/string.h @@ -1,6 +1,6 @@ /* This file should provide inline versions of string functions. - Surround GCC-specific parts with #ifdef __GNUC__, and use `extern __inline'. + Surround GCC-specific parts with #ifdef __GNUC__, and use `__extern_inline'. This file should define __STRING_INLINES if functions are actually defined as inlines. */ diff --git a/config.make.in b/config.make.in index 7aa9c1c12d..35597f808d 100644 --- a/config.make.in +++ b/config.make.in @@ -53,6 +53,7 @@ have-cpp-asm-debuginfo = @libc_cv_cpp_asm_debuginfo@ enable-check-abi = @enable_check_abi@ have-forced-unwind = @libc_cv_forced_unwind@ have-fpie = @libc_cv_fpie@ +gnu89-inline-CFLAGS = @libc_cv_gnu89_inline@ have-ssp = @libc_cv_ssp@ have-selinux = @have_selinux@ have-libaudit = @have_libaudit@ diff --git a/configure.in b/configure.in index 71ceb04b33..baf37598b2 100644 --- a/configure.in +++ b/configure.in @@ -1641,6 +1641,30 @@ fi rm -f conftest*]) AC_SUBST(libc_cv_ssp) +AC_CACHE_CHECK(for -fgnu89-inline, libc_cv_gnu89_inline, [dnl +cat > conftest.c <<EOF +int foo; +#ifdef __GNUC_GNU_INLINE__ +main () { return 0;} +#else +#error +#endif +EOF +if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -std=gnu99 -fgnu89-inline + -o conftest conftest.c 1>&AS_MESSAGE_LOG_FD]) +then + libc_cv_gnu89_inline=yes +else + libc_cv_gnu89_inline=no +fi +rm -f conftest*]) +if test $libc_cv_gnu89_inline = yes; then + libc_cv_gnu89_inline=-fgnu89-inline +else + libc_cv_gnu89_inline= +fi +AC_SUBST(libc_cv_gnu89_inline) + if test $elf != yes; then AC_CACHE_CHECK(for .init and .fini sections, libc_cv_have_initfini, [AC_TRY_COMPILE(, [asm (".section .init"); diff --git a/ctype/ctype.h b/ctype/ctype.h index e08545359d..9ae7fb6088 100644 --- a/ctype/ctype.h +++ b/ctype/ctype.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1991,92,93,95,96,97,98,99,2001,2002,2004 +/* Copyright (C) 1991,92,93,95,96,97,98,99,2001,2002,2004,2007 Free Software Foundation, Inc. This file is part of the GNU C Library. @@ -187,13 +187,13 @@ __exctype (_tolower); # endif # ifdef __USE_EXTERN_INLINES -extern __inline int +__extern_inline int __NTH (tolower (int __c)) { return __c >= -128 && __c < 256 ? (*__ctype_tolower_loc ())[__c] : __c; } -extern __inline int +__extern_inline int __NTH (toupper (int __c)) { return __c >= -128 && __c < 256 ? (*__ctype_toupper_loc ())[__c] : __c; diff --git a/hurd/hurd.h b/hurd/hurd.h index 0dc9f2158b..642ea43b7b 100644 --- a/hurd/hurd.h +++ b/hurd/hurd.h @@ -1,4 +1,5 @@ -/* Copyright (C) 1993,94,95,96,97,98,99,2001,02 Free Software Foundation, Inc. +/* Copyright (C) 1993,94,95,96,97,98,99,2001,2002,2007 + Free Software Foundation, Inc. This file is part of the GNU C Library. The |
