From cbd87efc64bf060f50ac9da0cfedc9aa5cc579fa Mon Sep 17 00:00:00 2001 From: Pier Date: Sun, 15 Oct 2017 18:16:07 +0100 Subject: [PATCH] fix(build): pow10 not defined on Fedora Rawhide (#807) pow10 is a GNU extension and not available everywhere --- src/adapters/alsa/mixer.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/adapters/alsa/mixer.cpp b/src/adapters/alsa/mixer.cpp index 47a9d5cf..34f51a27 100644 --- a/src/adapters/alsa/mixer.cpp +++ b/src/adapters/alsa/mixer.cpp @@ -136,9 +136,9 @@ namespace alsa { return math_util::percentage(vol_total / chan_n, vol_min, vol_max); } - normalized = pow10((vol_total / chan_n - vol_max) / 6000.0); + normalized = pow(10, (vol_total / chan_n - vol_max) / 6000.0); if (vol_min != SND_CTL_TLV_DB_GAIN_MUTE) { - min_norm = pow10((vol_min - vol_max) / 6000.0); + min_norm = pow(10, (vol_min - vol_max) / 6000.0); normalized = (normalized - min_norm) / (1 - min_norm); } @@ -182,7 +182,7 @@ namespace alsa { } if (vol_min != SND_CTL_TLV_DB_GAIN_MUTE) { - min_norm = pow10((vol_min - vol_max) / 6000.0); + min_norm = pow(10, (vol_min - vol_max) / 6000.0); percentage = percentage * (1 - min_norm) + min_norm; }