mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
Fix build with softfloat option
Fix build of alsa-lib when --with-softfloat is used: - disable ladspa plugin - don't use sqrt() function Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
b06414151d
commit
a789b66d00
2 changed files with 9 additions and 0 deletions
|
|
@ -367,6 +367,7 @@ AC_ARG_ENABLE(seq,
|
|||
AC_ARG_ENABLE(alisp,
|
||||
AS_HELP_STRING([--disable-alisp], [disable the alisp component]),
|
||||
[build_alisp="$enableval"], [build_alisp="yes"])
|
||||
test "$softfloat" = "yes" && build_alisp="no"
|
||||
AC_ARG_ENABLE(old-symbols,
|
||||
AS_HELP_STRING([--disable-old-symbols], [disable old obsoleted symbols]),
|
||||
[keep_old_symbols="$enableval"], [keep_old_symbols="yes"])
|
||||
|
|
@ -474,6 +475,7 @@ fi
|
|||
|
||||
if test "$softfloat" = "yes"; then
|
||||
build_pcm_lfloat="no"
|
||||
build_pcm_ladspa="no"
|
||||
fi
|
||||
|
||||
AM_CONDITIONAL(BUILD_PCM_PLUGIN, test x$build_pcm_plugin = xyes)
|
||||
|
|
|
|||
|
|
@ -1450,7 +1450,14 @@ static int simple_add1(snd_mixer_class_t *class, const char *name,
|
|||
}
|
||||
if (ctype != SND_CTL_ELEM_TYPE_BOOLEAN)
|
||||
return 0;
|
||||
#ifdef HAVE_SOFT_FLOAT
|
||||
/* up to 256 channels */
|
||||
for (n = 1; n < 256; n++)
|
||||
if (n * n == values)
|
||||
break;
|
||||
#else
|
||||
n = sqrt((double)values);
|
||||
#endif
|
||||
if (n * n != values)
|
||||
return 0;
|
||||
values = n;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue