asoundlib.h: No such file or directory
Closed this issue · 4 comments
I am can't build 0.3.11 release with this error:
/builddir/build/BUILD/freshplayerplugin-0.3.11/src/audio_thread_alsa.c:32:10: fatal error: asoundlib.h: No such file or directory
32 | #include <asoundlib.h>
| ^~~~~~~~~~~~~
Alsa lib installed and it's headers in /usr/include/alsa
Full build log
http://koji.rpmfusion.org/kojifiles/work/tasks/5878/325878/build.log
As far as I understand, ALSA libraries removed /usr/include/alsa
from include paths, so instead of using asoundlib.h
one should use alsa/asoundlib.h
. So, use this patch: e608336. It should help.
May be in othet distro alsa headers in other path. Can you make cmake autodetect it instead hardcoding?
Can you make cmake autodetect it instead hardcoding?
I don't think it's necessary. Inside alsa-lib repository #include <alsa/asoundlib.h>
was used at least for 10 years. It was my mistake to use #include <asoundlib.h>
. I peeked at some examples over the Internet when I was learning ALSA libraries.
Here is the change in ALSA libraries that surfaced the issue: https://git.alsa-project.org/?p=alsa-lib.git;a=commit;h=fc0e54c3cc6ad48d12d2cdad18df4473c559a448. As you can see, they say the #include <alsa/asoundlib.h>
is the way it should be included.
OK. It works.
Thanks.