[svn-commits] kpfleming: trunk r201090 - in /trunk: ./ autoconf/

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Jun 16 14:27:31 CDT 2009


Author: kpfleming
Date: Tue Jun 16 14:27:12 2009
New Revision: 201090

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=201090
Log:
Another minor fix to compiler attribute checking.

Defaulting to 'static' for the function scope was bad... so remove it.


Modified:
    trunk/autoconf/ast_gcc_attribute.m4
    trunk/configure
    trunk/configure.ac

Modified: trunk/autoconf/ast_gcc_attribute.m4
URL: http://svn.asterisk.org/svn-view/asterisk/trunk/autoconf/ast_gcc_attribute.m4?view=diff&rev=201090&r1=201089&r2=201090
==============================================================================
--- trunk/autoconf/ast_gcc_attribute.m4 (original)
+++ trunk/autoconf/ast_gcc_attribute.m4 Tue Jun 16 14:27:12 2009
@@ -7,17 +7,10 @@
 saved_CFLAGS="$CFLAGS"
 CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
 
-if test "x$3" = "x"
-then
-attribute_scope="static"
-else
-attribute_scope="$3"
-fi
-
 if test "x$2" = "x"
 then
 AC_COMPILE_IFELSE(
-	AC_LANG_PROGRAM([$attribute_scope void __attribute__(($1)) *test(void *muffin, ...) {return (void *) 0;}],
+	AC_LANG_PROGRAM([$3 void __attribute__(($1)) *test(void *muffin, ...) {return (void *) 0;}],
 			[]),
 	AC_MSG_RESULT(yes)
 	AC_DEFINE_UNQUOTED([HAVE_ATTRIBUTE_$1], 1, [Define to 1 if your GCC C compiler supports the '$1' attribute.]),
@@ -25,7 +18,7 @@
 )
 else
 AC_COMPILE_IFELSE(
-	AC_LANG_PROGRAM([$attribute_scope void __attribute__(($2)) *test(void *muffin, ...) {return (void *) 0;}],
+	AC_LANG_PROGRAM([$3 void __attribute__(($2)) *test(void *muffin, ...) {return (void *) 0;}],
 			[]),
 	AC_MSG_RESULT(yes)
 	AC_DEFINE_UNQUOTED([HAVE_ATTRIBUTE_$1], 1, [Define to 1 if your GCC C compiler supports the '$1' attribute.]),

Modified: trunk/configure.ac
URL: http://svn.asterisk.org/svn-view/asterisk/trunk/configure.ac?view=diff&rev=201090&r1=201089&r2=201090
==============================================================================
--- trunk/configure.ac (original)
+++ trunk/configure.ac Tue Jun 16 14:27:12 2009
@@ -515,7 +515,7 @@
 AST_GCC_ATTRIBUTE(sentinel)
 AST_GCC_ATTRIBUTE(warn_unused_result)
 AST_GCC_ATTRIBUTE(weakref, [weakref("foo")])
-AST_GCC_ATTRIBUTE(weak_import, , "")
+AST_GCC_ATTRIBUTE(weak_import)
 
 AC_MSG_CHECKING(for -ffunction-sections support)
 saved_CFLAGS="${CFLAGS}"




More information about the svn-commits mailing list