aboutsummaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-06-16 16:35:45 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-06-16 16:35:45 +0000
commit6884c6e29fa62766f3a3678ae9be34b4d82d5d96 (patch)
tree57f861f8a6b094473d05e986624a0add1f9d2283 /configure
parent67829e47017352239dab646fb9d65941a898e0d1 (diff)
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. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.1@200989 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure99
1 files changed, 81 insertions, 18 deletions
diff --git a/configure b/configure
index 3ba512bad..2149fa1da 100755
--- a/configure
+++ b/configure
@@ -17472,13 +17472,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((pure)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((pure)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17529,7 +17536,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17586,13 +17593,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((malloc)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((malloc)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17643,7 +17657,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17700,13 +17714,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((const)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((const)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17757,7 +17778,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17814,13 +17835,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((unused)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((unused)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17871,7 +17899,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17928,13 +17956,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((always_inline)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((always_inline)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -17985,7 +18020,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18042,13 +18077,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((deprecated)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((deprecated)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18099,7 +18141,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18156,13 +18198,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((sentinel)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((sentinel)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18213,7 +18262,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18270,13 +18319,20 @@ CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
if test "x" = "x"
then
+attribute_scope="static"
+else
+attribute_scope=""
+fi
+
+if test "x" = "x"
+then
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((warn_unused_result)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((warn_unused_result)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18327,7 +18383,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18382,6 +18438,13 @@ $as_echo_n "checking for compiler 'attribute weak' support... " >&6; }
saved_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
+if test "x""" = "x"
+then
+attribute_scope="static"
+else
+attribute_scope=""""
+fi
+
if test "x" = "x"
then
cat >conftest.$ac_ext <<_ACEOF
@@ -18390,7 +18453,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__((weak)) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__((weak)) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{
@@ -18441,7 +18504,7 @@ _ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-static void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
+$attribute_scope void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
int
main ()
{