【问题标题】:undefined reference to 'av_rdft_init(int, RDFTransformType)'未定义对 'av_rdft_init(int, RDFTransformType)' 的引用
【发布时间】:2015-09-12 05:36:52
【问题描述】:

我正在尝试将 ffmpeg 库集成到 android ndk 项目中。我关注了this 文档。当我尝试从 avcodec 库中调用方法时,例如 av_malloc,没有问题。但是当我尝试调用 av_rdft_init 或 av_rdft_calc 方法时,ndk 会给出如下错误;

 error: undefined reference to 'av_rdft_init(int, RDFTransformType)'  
 error: undefined reference to 'av_rdft_calc(RDFTContext*)'

我可以在头文件中看到这些方法,也可以在 libavcodec.so 文件的符号表中看到这些方法,但无法使用 ndk 构建。

有解决这个问题的想法吗? 提前致谢。

【问题讨论】:

    标签: c++ ffmpeg android-ndk libavcodec


    【解决方案1】:

    通过将 LOCAL_ALLOW_UNDEFINED_SYMBOLS := true 添加到 android makefile 解决了问题

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-10-24
      • 2022-01-12
      • 1970-01-01
      • 2011-07-20
      • 2018-10-13
      • 2012-07-20
      • 2018-02-02
      相关资源
      最近更新 更多