diff options
author | Timo Teräs <timo.teras@iki.fi> | 2013-12-18 13:51:44 +0000 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2013-12-18 13:52:44 +0000 |
commit | 211f26ed8b6729fd1e9e2ece00aa4dea0f6b3c12 (patch) | |
tree | abba4836561757f118a90219ac2a6398ac25e0a8 /main | |
parent | 9af45942aa6dbc7e70666270163d894fb3dc9b3a (diff) | |
download | aports-211f26ed8b6729fd1e9e2ece00aa4dea0f6b3c12.tar.bz2 aports-211f26ed8b6729fd1e9e2ece00aa4dea0f6b3c12.tar.xz |
main/asterisk: fix musl build
Diffstat (limited to 'main')
-rw-r--r-- | main/asterisk/APKBUILD | 13 | ||||
-rw-r--r-- | main/asterisk/musl-cdefs.patch | 20 | ||||
-rw-r--r-- | main/asterisk/musl-glob-compat.patch | 31 | ||||
-rw-r--r-- | main/asterisk/musl-pjsip-mutex.patch | 22 |
4 files changed, 86 insertions, 0 deletions
diff --git a/main/asterisk/APKBUILD b/main/asterisk/APKBUILD index f9989c0751..5a1842025e 100644 --- a/main/asterisk/APKBUILD +++ b/main/asterisk/APKBUILD @@ -35,6 +35,9 @@ source="$_download/asterisk-$_xy.0.tar.gz $_patches 100-uclibc-daemon.patch 101-caps-uclibc.patch + musl-cdefs.patch + musl-glob-compat.patch + musl-pjsip-mutex.patch ASTERISK-18995.patch ASTERISK-19109.patch ASTERISK-20527.patch @@ -61,6 +64,7 @@ prepare() { sed -i -e 's:lua5.1/::' pbx/pbx_lua.c sed -i -e 's/PBX_ICONV=1/PBX_ICONV=0/g' configure.ac sed -i -e 's/int foo = res_ninit(NULL);/res_ninit_is_not_really_here();/g' configure.ac + update_config_sub || return 1 ./bootstrap.sh } @@ -228,6 +232,9 @@ sound_en() { md5sums="f0c6b577f1efd8dc2de1f259b95a8d66 asterisk-11.7.0.tar.gz 837fc3bc835699462a8d2a7a16b9b6a3 100-uclibc-daemon.patch 6e1129e30c4fd2c25c86c81685a485a9 101-caps-uclibc.patch +735e5ae1e2121878a55eb2f5c6946ee2 musl-cdefs.patch +9b3e6cb75464a6ef4c40d191bdfdf7ea musl-glob-compat.patch +dfbd596ac95f52e3e668ade2c38147b1 musl-pjsip-mutex.patch bc6713f5434e07b79d3afdd155461d72 ASTERISK-18995.patch 146befabe95798a67c58d8ac00d397a6 ASTERISK-19109.patch 676ca42ee1859d8a7bae4345ede5eb89 ASTERISK-20527.patch @@ -237,6 +244,9 @@ ed31d7ba37bcf8b0346dcf8593c395f0 asterisk.confd sha256sums="4fb283b96447f5d871632a14069f35643c8c34d08d6ec5fedf0ae3df30e0c397 asterisk-11.7.0.tar.gz 6f56ea997513c10fa39835e8dd11fbfb4ec0bb23f4b771963e56691b15a5c003 100-uclibc-daemon.patch c2ef786e9a8082fe8ba7b4eb2f130925cb823d100ec567909ad465c279e335bf 101-caps-uclibc.patch +ad2506945246a6c2010bf39c1b3a8b10a6a635f02b56cbfa3014dcb2257298ff musl-cdefs.patch +c6a5c32646b767f09ebffccc49cac6a4ff9181498499e4453300775e75284b52 musl-glob-compat.patch +84e8d17572ee362c411bb641ae339eb42cb4542c32b0d1f41b7ac5f22b3328cb musl-pjsip-mutex.patch 7a7140156ae7fc7e833035db1e428db8d90159579cd2678c4b5cc829ded47485 ASTERISK-18995.patch d657634d4c96f42ac1a8b7103104185e8cd9d5a59e5214cc1658e01805975ce8 ASTERISK-19109.patch 1f822e618554e9962fe4599975bdcc24413e087dbd7ea4ce0305ecb7ea9bef94 ASTERISK-20527.patch @@ -246,6 +256,9 @@ d221148583b57f9c37d7160f2493f0d204ad11f7abb17e3a3534e108ad5452d7 asterisk.confd sha512sums="cd7ee59f9133fbd088b30c0495ac4d94cb0ca273015681340eeb4192ee1c510b59c8290255fc2df81f070369ff2ca56073fdee3f39e0b0186d95bb85f9ad1bd6 asterisk-11.7.0.tar.gz 24a0d3c0ae86117ead8d2e35fc9a5945e04b9f80f3baf122337c8361c015e5ad904c206579962aefe3eb35a1fbf269515228ae5f34a801d7725d73dc235cf831 100-uclibc-daemon.patch 601681b9a33e77b33a0393a494c4140aa6c1f174c514093242a4081661bb7f78b6af867100996c97f3bf12e8dd10873dd3e116b61e2a0e04832f4ee470664368 101-caps-uclibc.patch +29c74eee1df4826a8b63a049b57cc1a3d898b6e54bc32f4895e8e4e0ed88aece0061755ec1294fd6fb3d1cc4b2fd4de56ee5a8f036230609b0b08d2213c2d1cf musl-cdefs.patch +edf65eba44e8f1f0e78671aba312bcff2090134cf94e89ebb4b6beef7b2d57b24381ae9511cbf9fffe6b555e695a3dbe2cedcd04f1d237df822fa742bd5092ac musl-glob-compat.patch +33f376cf37ff6a916a4ca67edc686b4afbfaecd74fdc7ef08ed19bf3fb01f4e6a604ff2de3b2a14b4313c91037e6587b85917111998b5166eeccab5317601f11 musl-pjsip-mutex.patch 42b2385d88e72473fe34c63e1be8cdf7f37688649fe5bf033b5ba17627008b771aec8f0a583e9ad483a20f9e1f7c33922cb42bf5b73adc68aa43fd46c5da1daa ASTERISK-18995.patch a9a0a4199291a6ef5ebdf07daee07293d96a16a38116f6afdea61d68b167235d63b5a54e3ae45b7e11be0b9dc82863fdced1ad45110dcac29b353ddcc1d6337a ASTERISK-19109.patch 6edd8e0a1dce326aadf659c8bf8ed34083e8247b6c0f032d097c77df25feb93107375ba505e9076c084fe80676336d6c863e04c3c6808a850e24257fd7a7702d ASTERISK-20527.patch diff --git a/main/asterisk/musl-cdefs.patch b/main/asterisk/musl-cdefs.patch new file mode 100644 index 0000000000..94f07ae8ea --- /dev/null +++ b/main/asterisk/musl-cdefs.patch @@ -0,0 +1,20 @@ +--- asterisk-11.7.0.orig/main/ast_expr2.c ++++ asterisk-11.7.0/main/ast_expr2.c +@@ -93,6 +93,7 @@ + + #include "asterisk.h" + ++#include <sys/cdefs.h> + #include <sys/types.h> + #include <stdio.h> + +--- asterisk-11.7.0.orig/main/ast_expr2.y ++++ asterisk-11.7.0/main/ast_expr2.y +@@ -14,6 +14,7 @@ + + #include "asterisk.h" + ++#include <sys/cdefs.h> + #include <sys/types.h> + #include <stdio.h> + diff --git a/main/asterisk/musl-glob-compat.patch b/main/asterisk/musl-glob-compat.patch new file mode 100644 index 0000000000..429babb573 --- /dev/null +++ b/main/asterisk/musl-glob-compat.patch @@ -0,0 +1,31 @@ +--- asterisk-11.7.0.orig/res/ael/ael.flex ++++ asterisk-11.7.0/res/ael/ael.flex +@@ -79,6 +79,12 @@ + #if !defined(GLOB_ABORTED) + #define GLOB_ABORTED GLOB_ABEND + #endif ++#if !defined(GLOB_BRACE) ++#define GLOB_BRACE 0 ++#endif ++#if !defined(GLOB_NOMAGIC) ++#define GLOB_NOMAGIC 0 ++#endif + + #include "asterisk/logger.h" + #include "asterisk/utils.h" +Only in asterisk-11.7.0: res/ael/ael.tab.o +--- asterisk-11.7.0.orig/res/ael/ael_lex.c ++++ asterisk-11.7.0/res/ael/ael_lex.c +@@ -838,6 +838,12 @@ + #if !defined(GLOB_ABORTED) + #define GLOB_ABORTED GLOB_ABEND + #endif ++#if !defined(GLOB_BRACE) ++#define GLOB_BRACE 0 ++#endif ++#if !defined(GLOB_NOMAGIC) ++#define GLOB_NOMAGIC 0 ++#endif + + #include "asterisk/logger.h" + #include "asterisk/utils.h" diff --git a/main/asterisk/musl-pjsip-mutex.patch b/main/asterisk/musl-pjsip-mutex.patch new file mode 100644 index 0000000000..b73d93f7eb --- /dev/null +++ b/main/asterisk/musl-pjsip-mutex.patch @@ -0,0 +1,22 @@ +--- asterisk-11.7.0.orig/res/pjproject/pjlib/src/pj/os_core_unix.c ++++ asterisk-11.7.0/res/pjproject/pjlib/src/pj/os_core_unix.c +@@ -1091,8 +1091,7 @@ + return PJ_RETURN_OS_ERROR(rc); + + if (type == PJ_MUTEX_SIMPLE) { +-#if (defined(PJ_LINUX) && PJ_LINUX!=0) || \ +- defined(PJ_HAS_PTHREAD_MUTEXATTR_SETTYPE) ++#if defined(PJ_LINUX) && PJ_LINUX!=0 && defined(__GLIBC__) + rc = pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_FAST_NP); + #elif (defined(PJ_RTEMS) && PJ_RTEMS!=0) || \ + defined(PJ_PTHREAD_MUTEXATTR_T_HAS_RECURSIVE) +@@ -1101,8 +1100,7 @@ + rc = pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_NORMAL); + #endif + } else { +-#if (defined(PJ_LINUX) && PJ_LINUX!=0) || \ +- defined(PJ_HAS_PTHREAD_MUTEXATTR_SETTYPE) ++#if (defined(PJ_LINUX) && PJ_LINUX!=0) && defined(__GLIBC__) + rc = pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP); + #elif (defined(PJ_RTEMS) && PJ_RTEMS!=0) || \ + defined(PJ_PTHREAD_MUTEXATTR_T_HAS_RECURSIVE) |