Android NDK - Undefined reference to Android::Mutex, Android::AudioTrack

前端 未结 2 1972
情话喂你
情话喂你 2021-01-21 12:14

I\'m getting strange undefined references at link time for Android::Mutex and Android::AudioTrack used by a project I have taken over.

Does anyone have any ideas? There

相关标签:
2条回答
  • 2021-01-21 12:38

    Well these are some strange errors... It looks like every time you reference something from the android::Mutex or the android::AudioTrack libraries the linker is unable to find those functions. All I can say is that since those libraries are not part of the android standard library, make sure you have them in your build path, otherwise best of luck.

    0 讨论(0)
  • 2021-01-21 12:52

    This plagued me as well - but I finally resolved it by linking with Bionic's header (bionic/libc/include), and - the important part - #define'ing HAVE_PTHREADS (i.e. add LOCAL_CFLAGS += HAVE_PTHREADS).

    0 讨论(0)
提交回复
热议问题