[svn-commits] kpfleming: branch 1.6.1 r200989 - in /branches/1.6.1: ./ autoconf/

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Jun 16 11:35:49 CDT 2009


Author: kpfleming
Date: Tue Jun 16 11:35:45 2009
New Revision: 200989

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=200989
Log:
Merged revisions 200985 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

........
  r200985 | kpfleming | 2009-06-16 11:32:36 -0500 (Tue, 16 Jun 2009) | 7 lines
  
  Fix problems with new compiler attribute checking in configure script.
  
  The last changes to ast_gcc_attribute.m4 caused some problems checking for
  various attributes, because the scope of the symbol the attribute is applied
  to can be important; this patch allows the scope to be specified for the check.
........

Modified:
    branches/1.6.1/   (props changed)
    branches/1.6.1/autoconf/ast_gcc_attribute.m4
    branches/1.6.1/configure
    branches/1.6.1/configure.ac

Propchange: branches/1.6.1/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.1/autoconf/ast_gcc_attribute.m4
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.1/autoconf/ast_gcc_attribute.m4?view=diff&rev=200989&r1=200988&r2=200989
==============================================================================
--- branches/1.6.1/autoconf/ast_gcc_attribute.m4 (original)
+++ branches/1.6.1/autoconf/ast_gcc_attribute.m4 Tue Jun 16 11:35:45 2009
@@ -1,5 +1,5 @@
 # Helper function to check for gcc attributes.
-# AST_GCC_ATTRIBUTE([attribute name], [attribute syntax])
+# AST_GCC_ATTRIBUTE([attribute name], [attribute syntax], [attribute scope])
 
 AC_DEFUN([AST_GCC_ATTRIBUTE],
 [
@@ -7,10 +7,17 @@
 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([static void __attribute__(($1)) *test(void *muffin, ...) {return (void *) 0;}],
+	AC_LANG_PROGRAM([$attribute_scope 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.]),
@@ -18,7 +25,7 @@
 )
 else
 AC_COMPILE_IFELSE(
-	AC_LANG_PROGRAM([static void __attribute__(($2)) *test(void *muffin, ...) {return (void *) 0;}],
+	AC_LANG_PROGRAM([$attribute_scope 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: branches/1.6.1/configure.ac
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.1/configure.ac?view=diff&rev=200989&r1=200988&r2=200989
==============================================================================
--- branches/1.6.1/configure.ac (original)
+++ branches/1.6.1/configure.ac Tue Jun 16 11:35:45 2009
@@ -488,7 +488,7 @@
 AST_GCC_ATTRIBUTE(deprecated)
 AST_GCC_ATTRIBUTE(sentinel)
 AST_GCC_ATTRIBUTE(warn_unused_result)
-AST_GCC_ATTRIBUTE(weak)
+AST_GCC_ATTRIBUTE(weak, , "")
 
 AC_MSG_CHECKING(for -ffunction-sections support)
 saved_CFLAGS="${CFLAGS}"




More information about the svn-commits mailing list