美文网首页
ijkplayer编译遇到的问题和解决办法

ijkplayer编译遇到的问题和解决办法

作者: 紫水依 | 来源:发表于2019-04-06 16:47 被阅读0次

    环境:Xcode 10.2,iOS11

    1、执行./compile-ffmpeg.sh all时遇到

    xcrun -sdk iphoneos clang is unable to create an executable file.C compiler test failed.If you think configure made a mistake, make sure you are using the latestversion from Git.Ifthe latest version fails, report the problem to theffmpeg-user@ffmpeg.org mailinglistorIRC#ffmpeg on irc.freenode.net.Includethe log file"config.log"produced by configureasthis will helpsolve the problem.

    解决办法:

    执行以下命令
    sudo xcode-select --switch /Applications/Xcode.app
    之后再次执行

    cd ios
    ./compile-ffmpeg.sh clean
    ./compile-ffmpeg.sh all
    

    2、再次执行./compile-ffmpeg.sh all时遇到

    ./libavutil/arm/asm.S:50:9: error: unknown directive
    .arch armv7-a
    ^
    make: *** [libavcodec/arm/aacpsdsp_neon.o] Error 1
    make: *** Waiting for unfinished jobs....

    解决办法:

    ios/complile-ffmpeg.sh 25行添加
    FF_ALL_ARCHS_IOS10_SDK="arm64 i386 x86_64"
    修改
    FF_ALL_ARCHS=$FF_ALL_ARCHS_IOS10_SDK
    Xcode 10 测试没问题

    3、集成ijkplayer时运行报错

    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    operator delete", referenced from:
    operator new [] (unsigned long) , referenced from:

    解决办法:
    General-->Linked Frameworks and Libraries添加一个库
    libc++.tdb

    参考链接:
    1、iOS集成FFmpeg及视频格式转码
    2、armv7 编译问题处理咨询
    3、关于集成ijkplayer的framework中的那些坑

    相关文章

      网友评论

          本文标题:ijkplayer编译遇到的问题和解决办法

          本文链接:https://www.haomeiwen.com/subject/wdkkiqtx.html