diff options
author | Tilghman Lesher <tilghman@meg.abyt.es> | 2009-02-03 00:29:49 +0000 |
---|---|---|
committer | Tilghman Lesher <tilghman@meg.abyt.es> | 2009-02-03 00:29:49 +0000 |
commit | e179e613f7c291fc09102b23498e8bd128f79aeb (patch) | |
tree | c079f69e8eb11a6b8f496256b795b31c9773d773 /include | |
parent | 673d85387a2cef9534007f13ba2d9cd770eaba1d (diff) |
1. Make OS X compile cleanly with app_stack.
2. Use curl to download sound files, as curl is installed natively on OS X,
whereas wget and fetch are not.
(closes issue #14332)
Reported by: oej
Tested by: Corydon76
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@173130 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include')
-rw-r--r-- | include/asterisk/autoconfig.h.in | 3 | ||||
-rw-r--r-- | include/asterisk/compiler.h | 6 | ||||
-rw-r--r-- | include/asterisk/optional_api.h | 5 |
3 files changed, 13 insertions, 1 deletions
diff --git a/include/asterisk/autoconfig.h.in b/include/asterisk/autoconfig.h.in index 200b96738..de71b7060 100644 --- a/include/asterisk/autoconfig.h.in +++ b/include/asterisk/autoconfig.h.in @@ -123,6 +123,9 @@ /* Define to 1 if your GCC C compiler supports the 'weak' attribute. */ #undef HAVE_ATTRIBUTE_weak +/* Define to 1 if your GCC C compiler supports the 'weak_import' attribute. */ +#undef HAVE_ATTRIBUTE_weak_import + /* Define this to indicate the ${BKTR_DESCRIP} library */ #undef HAVE_BKTR diff --git a/include/asterisk/compiler.h b/include/asterisk/compiler.h index 0468cd3d9..15a750f9c 100644 --- a/include/asterisk/compiler.h +++ b/include/asterisk/compiler.h @@ -74,4 +74,10 @@ #define attribute_weak #endif +#ifdef HAVE_ATTRIBUTE_weak_import +#define attribute_weak_import __attribute__((weak_import)) +#else +#define attribute_weak_import +#endif + #endif /* _ASTERISK_COMPILER_H */ diff --git a/include/asterisk/optional_api.h b/include/asterisk/optional_api.h index ad7169cc4..1af596ec1 100644 --- a/include/asterisk/optional_api.h +++ b/include/asterisk/optional_api.h @@ -83,7 +83,10 @@ */ #define AST_OPTIONAL_API_UNAVAILABLE INT_MIN -#if defined(HAVE_ATTRIBUTE_weak) && defined(HAVE_ATTRIBUTE_alias) && !defined(AST_API_MODULE) +#if defined(HAVE_ATTRIBUTE_weak_import) && !defined(AST_API_MODULE) +#define AST_OPTIONAL_API(result, name, proto, stub) result name proto __attribute__((weak_import)); +#define AST_OPTIONAL_API_ATTR(result, attr, name, proto, stub) result name proto __attribute__((weak_import,attr)); +#elif defined(HAVE_ATTRIBUTE_weak) && defined(HAVE_ATTRIBUTE_alias) && !defined(AST_API_MODULE) && !defined(HAVE_ATTRIBUTE_weak_import) #define AST_OPTIONAL_API(result, name, proto, stub) \ static result __##name proto stub; \ result __attribute__((weak, alias("__" __stringify(name)))) name proto; |