kumquat-buildroot/package/alsa-lib/0002-src-ucm-main.c-fix-build-without-mixer.patch
Fabrice Fontaine 99767380ed package/alsa-lib: fix build without mixer
Fixes:
 - http://autobuild.buildroot.org/results/4d91c9f82a2a61c50c457a851073b85cc09ea345

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
2019-12-03 22:51:46 +01:00

40 lines
1.3 KiB
Diff

From 65eb51668f87668d994f260f36a6325f248cdff3 Mon Sep 17 00:00:00 2001
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Date: Tue, 3 Dec 2019 18:56:40 +0100
Subject: [PATCH] src/ucm/main.c: fix build without mixer
Commit 4ce38a5ff466d18039b2606938f866ea3a6c9f3c breaks the build without
mixer on:
CCLD libasound.la
/home/buildroot/autobuild/instance-1/output-1/host/lib/gcc/xtensa-buildroot-linux-uclibc/8.3.0/../../../../xtensa-buildroot-linux-uclibc/bin/ld: ucm/.libs/libucm.a(main.o): in function `snd_use_case_set':
main.c:(.text+0x185c): undefined reference to `snd_mixer_selem_id_parse'
Fixes:
- http://autobuild.buildroot.org/results/4d91c9f82a2a61c50c457a851073b85cc09ea345
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
[Upstream status: https://github.com/alsa-project/alsa-lib/pull/15]
---
src/ucm/main.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/ucm/main.c b/src/ucm/main.c
index d2078a23..61922f10 100644
--- a/src/ucm/main.c
+++ b/src/ucm/main.c
@@ -2115,8 +2115,10 @@ int snd_use_case_parse_selem_id(snd_mixer_selem_id_t *dst,
const char *ucm_id,
const char *value)
{
+#ifdef BUILD_MIXER
if (strcmp(ucm_id, "PlaybackMixerId") == 0 ||
strcmp(ucm_id, "CaptureMixerId") == 0)
return snd_mixer_selem_id_parse(dst, value);
+#endif
return -EINVAL;
}
--
2.24.0