diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2013-10-02 15:27:09 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2013-10-02 15:27:09 +0200 |
commit | 54e282790067731b73ba1b5ec075680baa7ba47b (patch) | |
tree | 5e1efe22e55eb1ce74b39e7943564e18ae265e84 | |
parent | 7e9273da72c10a623f6deb6d2a127e1f00045e50 (diff) | |
parent | b9cac21d877b457d41fa4197b06c84b1d6f88304 (diff) |
Merge branch 'master' of git+ssh://openadk.org/git/openadk
-rw-r--r-- | package/alsa-lib/Makefile | 2 | ||||
-rw-r--r-- | package/alsa-lib/patches/patch-src_conf_c | 35 |
2 files changed, 36 insertions, 1 deletions
diff --git a/package/alsa-lib/Makefile b/package/alsa-lib/Makefile index ed9e41012..01d5fee2e 100644 --- a/package/alsa-lib/Makefile +++ b/package/alsa-lib/Makefile @@ -5,7 +5,7 @@ include ${TOPDIR}/rules.mk PKG_NAME:= alsa-lib PKG_VERSION:= 1.0.27.2 -PKG_RELEASE:= 2 +PKG_RELEASE:= 3 PKG_MD5SUM:= 69129a7c37697f81ac092335e9fa452b PKG_DESCR:= ALSA sound library PKG_SECTION:= libs diff --git a/package/alsa-lib/patches/patch-src_conf_c b/package/alsa-lib/patches/patch-src_conf_c new file mode 100644 index 000000000..f3c1e70bd --- /dev/null +++ b/package/alsa-lib/patches/patch-src_conf_c @@ -0,0 +1,35 @@ +from alpinelinux + http://git.alpinelinux.org/cgit/aports/tree/main/alsa-lib/alsa-lib-portable-mutex.patch +--- alsa-lib-1.0.27.2.orig/src/conf.c 2013-07-08 14:31:36.000000000 +0200 ++++ alsa-lib-1.0.27.2/src/conf.c 2013-10-02 14:32:15.000000000 +0200 +@@ -427,8 +427,8 @@ beginning:</P> + #ifndef DOC_HIDDEN + + #ifdef HAVE_LIBPTHREAD +-static pthread_mutex_t snd_config_update_mutex = +- PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP; ++static pthread_mutex_t snd_config_update_mutex; ++static pthread_once_t snd_config_update_mutex_once = PTHREAD_ONCE_INIT; + #endif + + struct _snd_config { +@@ -472,8 +472,19 @@ typedef struct { + + #ifdef HAVE_LIBPTHREAD + ++static void snd_config_init_mutex(void) ++{ ++ pthread_mutexattr_t attr; ++ ++ pthread_mutexattr_init(&attr); ++ pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); ++ pthread_mutex_init(&snd_config_update_mutex, &attr); ++ pthread_mutexattr_destroy(&attr); ++} ++ + static inline void snd_config_lock(void) + { ++ pthread_once(&snd_config_update_mutex_once, snd_config_init_mutex); + pthread_mutex_lock(&snd_config_update_mutex); + } + |