Closed zoff99 closed 1 year ago
Thanks. I actually wasn't able to replicate this, but I've nonetheless done a possible fix. It's in the dev branch. Are you able to give that a try?
now its giving this error:
miniaudio.h:14833:9: error: misaligned atomic operation may incur significant performance penalty; the expected alignment (8 bytes) exceeds the actual alignment (4 bytes) [-Werror,-Watomic-alignment] __atomic_compare_exchange_n(dst, &expected, desired, 0, ATOMIC_SEQ_CST, ATOMIC_SEQ_CST);
121 warnings and 1 error generated.
also there are a bunch of warnings that may be something to fix.
warning: comparing floating point with == or != is unsafe [-Wfloat-equal] note: expanded from macro 'ma_dr_wav_offset_ptr'
That -Watomic-alignment
warning is a false positive. It probably needs to be silenced somehow, but I don't want to disable the warning at the level of the entire file so I'm not sure how to address that. You might need to disable that warning in your build system.
I have no interest in addressing -Wfloat-equal
. You'll need to disable that warning. Note that I'm not supporting any warnings that are enabled in -Weverything
.
you dont have to. i just wanted to show you that they are there. i know how to disable them in my project.
miniaudio - v0.11.18, compiling on android gives these errors:
miniaudio.h:77481:23: error: signed shift result (0x8000000000000000) sets the sign bit of the shift expression's type ('ma_int64' (aka 'long long')) and becomes negative [-Werror,-Wshift-sign-overflow] return sign ? MA_DR_WAV_INT64_MIN : MA_DR_WAV_INT64_MAX;
miniaudio.h:77485:23: error: signed shift result (0x8000000000000000) sets the sign bit of the shift expression's type ('ma_int64' (aka 'long long')) and becomes negative [-Werror,-Wshift-sign-overflow] return sign ? MA_DR_WAV_INT64_MIN : MA_DR_WAV_INT64_MAX;