update buildroot to 2017.02.11
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
Fix musl-related build errors in packages depending on alsa, in our case
|
||||
this fixes openal.
|
||||
|
||||
Downloaded from
|
||||
http://git.alpinelinux.org/cgit/aports/tree/main/alsa-lib/alsa-lib_pcm_h.patch
|
||||
|
||||
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
||||
|
||||
--- alsa-lib-1.0.25/include/pcm.h
|
||||
+++ alsa-lib-1.0.25.patched/include/pcm.h
|
||||
@@ -33,6 +33,7 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
+#include <stdint.h>
|
||||
/**
|
||||
* \defgroup PCM PCM Interface
|
||||
* See the \ref pcm page for more details.
|
||||
@@ -941,10 +942,10 @@
|
||||
int snd_pcm_format_physical_width(snd_pcm_format_t format); /* in bits */
|
||||
snd_pcm_format_t snd_pcm_build_linear_format(int width, int pwidth, int unsignd, int big_endian);
|
||||
ssize_t snd_pcm_format_size(snd_pcm_format_t format, size_t samples);
|
||||
-u_int8_t snd_pcm_format_silence(snd_pcm_format_t format);
|
||||
-u_int16_t snd_pcm_format_silence_16(snd_pcm_format_t format);
|
||||
-u_int32_t snd_pcm_format_silence_32(snd_pcm_format_t format);
|
||||
-u_int64_t snd_pcm_format_silence_64(snd_pcm_format_t format);
|
||||
+uint8_t snd_pcm_format_silence(snd_pcm_format_t format);
|
||||
+uint16_t snd_pcm_format_silence_16(snd_pcm_format_t format);
|
||||
+uint32_t snd_pcm_format_silence_32(snd_pcm_format_t format);
|
||||
+uint64_t snd_pcm_format_silence_64(snd_pcm_format_t format);
|
||||
int snd_pcm_format_set_silence(snd_pcm_format_t format, void *buf, unsigned int samples);
|
||||
|
||||
snd_pcm_sframes_t snd_pcm_bytes_to_frames(snd_pcm_t *pcm, ssize_t bytes);
|
||||
45
bsp/buildroot-2017.02.11/package/alsa-lib/0002-no-mmu.patch
Normal file
45
bsp/buildroot-2017.02.11/package/alsa-lib/0002-no-mmu.patch
Normal file
@@ -0,0 +1,45 @@
|
||||
Don't use fork() on noMMU platforms
|
||||
|
||||
[Gustavo: update patch for 1.0.28]
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
|
||||
Index: alsa-lib-1.0.26/configure.ac
|
||||
===================================================================
|
||||
--- alsa-lib-1.0.26.orig/configure.ac 2012-09-06 10:55:14.000000000 +0200
|
||||
+++ alsa-lib-1.0.26/configure.ac 2013-03-09 16:22:08.000000000 +0100
|
||||
@@ -66,6 +66,8 @@
|
||||
AM_CONDITIONAL(ALSA_HSEARCH_R, [test "x$HAVE_HSEARCH_R" != xyes])
|
||||
AC_CHECK_FUNCS([uselocale])
|
||||
|
||||
+AC_CHECK_FUNC([fork])
|
||||
+
|
||||
SAVE_LIBRARY_VERSION
|
||||
AC_SUBST(LIBTOOL_VERSION_INFO)
|
||||
|
||||
Index: alsa-lib-1.0.26/src/pcm/pcm_direct.c
|
||||
===================================================================
|
||||
--- alsa-lib-1.0.26.orig/src/pcm/pcm_direct.c 2012-09-06 10:55:14.000000000 +0200
|
||||
+++ alsa-lib-1.0.26/src/pcm/pcm_direct.c 2013-03-09 16:22:51.000000000 +0100
|
||||
@@ -424,13 +424,21 @@
|
||||
close(dmix->server_fd);
|
||||
return ret;
|
||||
}
|
||||
-
|
||||
+
|
||||
+#ifdef HAVE_FORK
|
||||
ret = fork();
|
||||
+#else
|
||||
+ ret = vfork();
|
||||
+#endif
|
||||
if (ret < 0) {
|
||||
close(dmix->server_fd);
|
||||
return ret;
|
||||
} else if (ret == 0) {
|
||||
+#ifdef HAVE_FORK
|
||||
ret = fork();
|
||||
+#else
|
||||
+ ret = vfork();
|
||||
+#endif
|
||||
if (ret == 0)
|
||||
server_job(dmix);
|
||||
_exit(EXIT_SUCCESS);
|
||||
59
bsp/buildroot-2017.02.11/package/alsa-lib/0003-dlmisc.patch
Normal file
59
bsp/buildroot-2017.02.11/package/alsa-lib/0003-dlmisc.patch
Normal file
@@ -0,0 +1,59 @@
|
||||
alsa-lib: provide dummy definitions of RTLD_* if necessary
|
||||
|
||||
The FLAT GNU toolchain (e.g. blackfin) doesn't include the dlfcn.h header
|
||||
file, so we need to guard that include. Additionally, provide dummy
|
||||
definitions for parameters RTLD_GLOBAL / RTLD_NOW which are normally
|
||||
provided by dlfcn.h.
|
||||
|
||||
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
|
||||
[Thomas: don't add separate dlmisc.h, move dummy defs to global.h]
|
||||
Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
|
||||
|
||||
diff --git a/include/global.h b/include/global.h
|
||||
--- a/include/global.h
|
||||
+++ b/include/global.h
|
||||
@@ -97,6 +97,16 @@ extern struct snd_dlsym_link *snd_dlsym_
|
||||
/** \brief Returns the version of a dynamic symbol as a string. */
|
||||
#define SND_DLSYM_VERSION(version) __STRING(version)
|
||||
|
||||
+/* RTLD_NOW and RTLD_GLOBAL (used for 'mode' in snd_dlopen) are not defined
|
||||
+ * on all arches (e.g. blackfin), so provide a dummy definition here. */
|
||||
+#ifndef RTLD_NOW
|
||||
+#define RTLD_NOW 0
|
||||
+#endif
|
||||
+
|
||||
+#ifndef RTLD_GLOBAL
|
||||
+#define RTLD_GLOBAL 0
|
||||
+#endif
|
||||
+
|
||||
void *snd_dlopen(const char *file, int mode);
|
||||
void *snd_dlsym(void *handle, const char *name, const char *version);
|
||||
int snd_dlclose(void *handle);
|
||||
diff --git a/modules/mixer/simple/sbasedl.c b/modules/mixer/simple/sbasedl.c
|
||||
--- a/modules/mixer/simple/sbasedl.c
|
||||
+++ b/modules/mixer/simple/sbasedl.c
|
||||
@@ -27,7 +27,9 @@
|
||||
#include <fcntl.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <math.h>
|
||||
+#include "config.h"
|
||||
+#ifdef HAVE_DLFCN
|
||||
#include <dlfcn.h>
|
||||
+#endif
|
||||
-#include "config.h"
|
||||
#include "asoundlib.h"
|
||||
#include "mixer_abst.h"
|
||||
diff --git a/src/mixer/simple_abst.c b/src/mixer/simple_abst.c
|
||||
--- a/src/mixer/simple_abst.c
|
||||
+++ b/src/mixer/simple_abst.c
|
||||
@@ -34,7 +34,9 @@
|
||||
#include <fcntl.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <math.h>
|
||||
+#include "config.h"
|
||||
+#ifdef HAVE_DLFCN
|
||||
#include <dlfcn.h>
|
||||
+#endif
|
||||
-#include "config.h"
|
||||
#include "asoundlib.h"
|
||||
#include "mixer_simple.h"
|
||||
@@ -0,0 +1,35 @@
|
||||
alsa-lib: conditionally enable libdl in AM_PATH_ALSA m4 macro
|
||||
|
||||
The AM_PATH_ALSA macro in utils/alsa.m4 unconditionally uses -ldl. This
|
||||
breaks compilation of alsa-utils (and probably other packages using this
|
||||
macro) for targets that do not support dynamic loading, such as for
|
||||
Blackfin FLAT binaries.
|
||||
|
||||
This patch updates the macro to check if dlopen is available, and use that
|
||||
result to conditionally add -ldl to the list of libraries.
|
||||
|
||||
Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
|
||||
|
||||
---
|
||||
|
||||
diff --git a/utils/alsa.m4 b/utils/alsa.m4
|
||||
--- a/utils/alsa.m4
|
||||
+++ b/utils/alsa.m4
|
||||
@@ -44,6 +44,8 @@ if test "$alsa_inc_prefix" != "" ; then
|
||||
fi
|
||||
AC_MSG_RESULT($ALSA_CFLAGS)
|
||||
|
||||
+AC_CHECK_LIB(c, dlopen, LIBDL="", [AC_CHECK_LIB(dl, dlopen, LIBDL="-ldl")])
|
||||
+
|
||||
dnl add any special lib dirs
|
||||
AC_MSG_CHECKING(for ALSA LDFLAGS)
|
||||
if test "$alsa_prefix" != "" ; then
|
||||
@@ -52,7 +54,7 @@ if test "$alsa_prefix" != "" ; then
|
||||
fi
|
||||
|
||||
dnl add the alsa library
|
||||
-ALSA_LIBS="$ALSA_LIBS -lasound -lm -ldl -lpthread"
|
||||
+ALSA_LIBS="$ALSA_LIBS -lasound -lm $LIBDL -lpthread"
|
||||
LIBS="$ALSA_LIBS $LIBS"
|
||||
AC_MSG_RESULT($ALSA_LIBS)
|
||||
|
||||
@@ -0,0 +1,67 @@
|
||||
Linking currently fails on powerpc64 and powerpc64le when configured
|
||||
with --without-versioned, as follows:
|
||||
../src/.libs/libasound.so: undefined reference to `.__snd_pcm_hw_params_set_format_first'
|
||||
(And many similar messages.)
|
||||
|
||||
This appears to be due to a very old (2003) workaround for powerpc64,
|
||||
(introduced by commit 06221f86) in include/alsa-symbols.h which alters
|
||||
symbol names. While it was probably necessary at the time, it does not
|
||||
appear to be necessary now and removing it fixes the build.
|
||||
|
||||
Signed-off-by: Sam Bobroff <sam.bobroff@au1.ibm.com>
|
||||
---
|
||||
include/alsa-symbols.h | 25 ++++---------------------
|
||||
1 file changed, 4 insertions(+), 21 deletions(-)
|
||||
|
||||
diff --git a/include/alsa-symbols.h b/include/alsa-symbols.h
|
||||
index 51cb982..0cb0b9f 100644
|
||||
--- a/include/alsa-symbols.h
|
||||
+++ b/include/alsa-symbols.h
|
||||
@@ -29,19 +29,10 @@
|
||||
#define INTERNAL_CONCAT2_2(Pre, Post) Pre##Post
|
||||
#define INTERNAL(Name) INTERNAL_CONCAT2_2(__, Name)
|
||||
|
||||
-#ifdef __powerpc64__
|
||||
-# define symbol_version(real, name, version) \
|
||||
- __asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@" #version); \
|
||||
- __asm__ (".symver ." ASM_NAME(#real) ",." ASM_NAME(#name) "@" #version)
|
||||
-# define default_symbol_version(real, name, version) \
|
||||
- __asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@@" #version); \
|
||||
- __asm__ (".symver ." ASM_NAME(#real) ",." ASM_NAME(#name) "@@" #version)
|
||||
-#else
|
||||
-# define symbol_version(real, name, version) \
|
||||
- __asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@" #version)
|
||||
-# define default_symbol_version(real, name, version) \
|
||||
- __asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@@" #version)
|
||||
-#endif
|
||||
+#define symbol_version(real, name, version) \
|
||||
+__asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@" #version)
|
||||
+#define default_symbol_version(real, name, version) \
|
||||
+__asm__ (".symver " ASM_NAME(#real) "," ASM_NAME(#name) "@@" #version)
|
||||
|
||||
#ifdef USE_VERSIONED_SYMBOLS
|
||||
#define use_symbol_version(real, name, version) \
|
||||
@@ -50,13 +41,6 @@
|
||||
default_symbol_version(real, name, version)
|
||||
#else
|
||||
#define use_symbol_version(real, name, version) /* nothing */
|
||||
-#ifdef __powerpc64__
|
||||
-#define use_default_symbol_version(real, name, version) \
|
||||
- __asm__ (".weak " ASM_NAME(#name)); \
|
||||
- __asm__ (".weak ." ASM_NAME(#name)); \
|
||||
- __asm__ (".set " ASM_NAME(#name) "," ASM_NAME(#real)); \
|
||||
- __asm__ (".set ." ASM_NAME(#name) ",." ASM_NAME(#real))
|
||||
-#else
|
||||
#if defined(__alpha__) || defined(__mips__)
|
||||
#define use_default_symbol_version(real, name, version) \
|
||||
__asm__ (".weak " ASM_NAME(#name)); \
|
||||
@@ -67,6 +51,5 @@
|
||||
__asm__ (".set " ASM_NAME(#name) "," ASM_NAME(#real))
|
||||
#endif
|
||||
#endif
|
||||
-#endif
|
||||
|
||||
#endif /* __ALSA_SYMBOLS_H */
|
||||
--
|
||||
2.10.0.297.gf6727b0
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
From 13a796b4bd00defa9f9297fd23d508b430682aed Mon Sep 17 00:00:00 2001
|
||||
From: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
Date: Wed, 21 Dec 2016 19:41:26 -0300
|
||||
Subject: [PATCH] ucm: parser needs limits.h
|
||||
|
||||
It's using PATH_MAX which is defined there, otherwise the build fails on
|
||||
musl libc.
|
||||
|
||||
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
---
|
||||
Patch status: sent to alsa-devel ML.
|
||||
|
||||
src/ucm/parser.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/ucm/parser.c b/src/ucm/parser.c
|
||||
index c98373a..f520abc 100644
|
||||
--- a/src/ucm/parser.c
|
||||
+++ b/src/ucm/parser.c
|
||||
@@ -32,6 +32,7 @@
|
||||
|
||||
#include "ucm_local.h"
|
||||
#include <dirent.h>
|
||||
+#include <limits.h>
|
||||
|
||||
/** The name of the environment variable containing the UCM directory */
|
||||
#define ALSA_CONFIG_UCM_VAR "ALSA_CONFIG_UCM"
|
||||
--
|
||||
2.10.2
|
||||
|
||||
78
bsp/buildroot-2017.02.11/package/alsa-lib/Config.in
Normal file
78
bsp/buildroot-2017.02.11/package/alsa-lib/Config.in
Normal file
@@ -0,0 +1,78 @@
|
||||
comment "alsa-lib needs a toolchain w/ threads"
|
||||
depends on !BR2_TOOLCHAIN_HAS_THREADS
|
||||
|
||||
menuconfig BR2_PACKAGE_ALSA_LIB
|
||||
bool "alsa-lib"
|
||||
# Temporary until
|
||||
# https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4913
|
||||
# is fixed
|
||||
select BR2_PACKAGE_ALSA_LIB_PCM
|
||||
# Even though some parts of alsa-lib use threads only when
|
||||
# available, some PCM plugins use them unconditionally. Since
|
||||
# the usage of alsa-lib on no-thread systems is pretty
|
||||
# unlikely, just require thread support globally for alsa-lib.
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||
help
|
||||
The Advanced Linux Sound Architecture (ALSA) provides audio and MIDI
|
||||
functionality to the Linux operating system.
|
||||
|
||||
http://www.alsa-project.org/
|
||||
|
||||
if BR2_PACKAGE_ALSA_LIB
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_PYTHON
|
||||
bool "Python support for alsa-lib"
|
||||
depends on BR2_PACKAGE_PYTHON
|
||||
help
|
||||
Add python support for alsa-lib.
|
||||
Python will be built and libpython will be installed
|
||||
in the target directory
|
||||
http://www.alsa-project.org/
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_DEVDIR
|
||||
string "directory with ALSA device files"
|
||||
default "/dev/snd"
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_PCM_PLUGINS
|
||||
string "built PCM plugins"
|
||||
default "all" if BR2_USE_MMU
|
||||
default "copy linear route mulaw alaw adpcm rate plug multi file null empty share meter hooks lfloat ladspa dmix dshare dsnoop asym iec958 softvol extplug ioplug mmap_emul" if !BR2_USE_MMU
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_CTL_PLUGINS
|
||||
string "built control plugins"
|
||||
default "all"
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_ALOAD
|
||||
bool "aload"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_MIXER
|
||||
bool "mixer"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_PCM
|
||||
bool "pcm"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_RAWMIDI
|
||||
bool "rawmidi"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_HWDEP
|
||||
bool "hwdep"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_SEQ
|
||||
bool "seq"
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_ALISP
|
||||
bool "alisp"
|
||||
depends on BR2_USE_MMU
|
||||
default y
|
||||
|
||||
config BR2_PACKAGE_ALSA_LIB_OLD_SYMBOLS
|
||||
bool "old-symbols"
|
||||
default y
|
||||
|
||||
endif
|
||||
2
bsp/buildroot-2017.02.11/package/alsa-lib/alsa-lib.hash
Normal file
2
bsp/buildroot-2017.02.11/package/alsa-lib/alsa-lib.hash
Normal file
@@ -0,0 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 71282502184c592c1a008e256c22ed0ba5728ca65e05273ceb480c70f515969c alsa-lib-1.1.3.tar.bz2
|
||||
75
bsp/buildroot-2017.02.11/package/alsa-lib/alsa-lib.mk
Normal file
75
bsp/buildroot-2017.02.11/package/alsa-lib/alsa-lib.mk
Normal file
@@ -0,0 +1,75 @@
|
||||
################################################################################
|
||||
#
|
||||
# alsa-lib
|
||||
#
|
||||
################################################################################
|
||||
|
||||
ALSA_LIB_VERSION = 1.1.3
|
||||
ALSA_LIB_SOURCE = alsa-lib-$(ALSA_LIB_VERSION).tar.bz2
|
||||
ALSA_LIB_SITE = ftp://ftp.alsa-project.org/pub/lib
|
||||
ALSA_LIB_LICENSE = LGPLv2.1+ (library), GPLv2+ (aserver)
|
||||
ALSA_LIB_LICENSE_FILES = COPYING aserver/COPYING
|
||||
ALSA_LIB_INSTALL_STAGING = YES
|
||||
ALSA_LIB_CFLAGS = $(TARGET_CFLAGS)
|
||||
ALSA_LIB_AUTORECONF = YES
|
||||
ALSA_LIB_CONF_OPTS = \
|
||||
--with-alsa-devdir=$(call qstrip,$(BR2_PACKAGE_ALSA_LIB_DEVDIR)) \
|
||||
--with-pcm-plugins="$(call qstrip,$(BR2_PACKAGE_ALSA_LIB_PCM_PLUGINS))" \
|
||||
--with-ctl-plugins="$(call qstrip,$(BR2_PACKAGE_ALSA_LIB_CTL_PLUGINS))" \
|
||||
--without-versioned
|
||||
|
||||
# Can't build with static & shared at the same time (1.0.25+)
|
||||
ifeq ($(BR2_STATIC_LIBS),y)
|
||||
ALSA_LIB_CONF_OPTS += \
|
||||
--enable-shared=no \
|
||||
--without-libdl
|
||||
else
|
||||
ALSA_LIB_CONF_OPTS += --enable-static=no
|
||||
endif
|
||||
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_ALOAD),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-aload
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_MIXER),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-mixer
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_PCM),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-pcm
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_RAWMIDI),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-rawmidi
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_HWDEP),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-hwdep
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_SEQ),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-seq
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_ALISP),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-alisp
|
||||
endif
|
||||
ifneq ($(BR2_PACKAGE_ALSA_LIB_OLD_SYMBOLS),y)
|
||||
ALSA_LIB_CONF_OPTS += --disable-old-symbols
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_ALSA_LIB_PYTHON),y)
|
||||
ALSA_LIB_CONF_OPTS += \
|
||||
--with-pythonlibs=-lpython$(PYTHON_VERSION_MAJOR) \
|
||||
--with-pythonincludes=$(STAGING_DIR)/usr/include/python$(PYTHON_VERSION_MAJOR)
|
||||
ALSA_LIB_CFLAGS += -I$(STAGING_DIR)/usr/include/python$(PYTHON_VERSION_MAJOR)
|
||||
ALSA_LIB_DEPENDENCIES = python
|
||||
else
|
||||
ALSA_LIB_CONF_OPTS += --disable-python
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_bfin),y)
|
||||
# blackfin external toolchains don't have versionsort. Fake it using alphasort
|
||||
# instead
|
||||
ALSA_LIB_CFLAGS += -Dversionsort=alphasort
|
||||
endif
|
||||
|
||||
ALSA_LIB_CONF_ENV = \
|
||||
CFLAGS="$(ALSA_LIB_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS) -lm"
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user