android arch linux,Linux上配置AndroidStudio并在Arch编译Bilibili的ijkplayer

Linux配置AndroidStudio

编译ijdkplayer

建议先安装yasm,下载好ndk,10就行,我下的12,本来现在是15,但是15是不行的。

打开终端:

1 先clone代码

git clone https://github.com/Bilibili/ijkplayer.git ijkplayer-android

cd ijkplayer-android

2 检查更新代码,切换分支,现在github上是0.8.4

git checkout -B latest k0.8.4

3 主要是把ffmpeg的代码拉取到本地。

./init-android.sh

4 如果需要增加 https 协议支持。

./init-android-openssl.sh

5 到contrib目录中,编译openssl

cd android/contrib

./compile-openssl.sh clean

./compile-openssl.sh all

如果遇到这个提示:

47232b5bf1e9

Screenshot_20171030_153350.png

解决:

export ANDROID_NDK=你的NDK路径

例如:

47232b5bf1e9

Screenshot_20171030_155120.png

再次执行

./compile-openssl.sh clean

./compile-openssl.sh all

然后如果遇到这个问题:

47232b5bf1e9

Screenshot_20171030_155356.png

解决:只能换ndk版本了 ndk各个版本下载

执行

export ANDROID_NDK=你的NDK路径

例如:

47232b5bf1e9

Screenshot_20171030_155833.png

然后再次执行

./compile-openssl.sh clean

./compile-openssl.sh all

6 编译ffmpeg

./compile-ffmpeg.sh clean

./compile-ffmpeg.sh all

如果遇到这个问题:

47232b5bf1e9

Screenshot_20171030_161620.png

解决:安装yasm

arch,manjaro执行yaourt yasm

安装完成后执行:

./compile-ffmpeg.sh clean

./compile-ffmpeg.sh all

7 返回到android目录,编译ijkplayer native code,生成全部架构的so文件。

cd ..

./compile-ijk.sh all

ok,大功告成,在目录/home/用户名/ijkplayer-android/android/下的ijkplayer可以直接用stuido导入了。

导入后:

47232b5bf1e9

Screenshot_20171030_172619.png

47232b5bf1e9

Screenshot_20171030_174811.png

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值