思科的
安装NASM
Android Builds
install android sdk and ndk.
export PATH=**ANDROID_SDK**/tools:$PATH
make OS=android NDKROOT=**ANDROID_NDK** TARGET=**ANDROID_TARGET**
Valid **ANDROID_TARGET** can be found in **ANDROID_SDK**/platforms, such as android-12.
You can also set ARCH, NDKLEVELaccording to your device and NDK version. 
ARC:arm, arm64, x86 and x86_64
NDKLEVEL specifies android api level, the default is 12.Available possibilities can be found in **ANDROID_NDK**/platforms,
By default these commands build for the armeabi-v7a
  • codec - encoder, decoder, console (test app), build (makefile, vcproj)
  • build - scripts for Makefile build system
  • test - GTest unittest files
  • testbin - autobuild scripts, test app config files
  • res - yuv and bitstream test files
# armeabi-v7a
make OS=android NDKROOT=$NDK_ROOT TARGET=android-21 ARCH=arm NDKLEVEL=21 clean
make OS=android NDKROOT=$NDK_ROOT TARGET=android-17 ARCH=arm NDKLEVEL=17
NDK 从 level21 开始支持 64位架构,因此 TARGET 低于 android-21 的将无法编译 arm64、x86_64、mips64 库
 mips、mips64 两种架构未做优化处理
生成的文件位于 ~/openh264 目录下,共计5个静态库,1个动态库
libcommon.a
libdecoder.a
libencoder.a
libopenh264.a
libprocessing.a
libopenh264.so
Invalid or unsupported command "update project -t android-17 -p ."
看makefile
"cd ./test/build/android && $(NDKROOT)/ndk-build -B APP_ABI=$(APP_ABI) && android update project -t $(TARGET) -p . && ant debug"
this error caused by using a higher SDK tool to build encoder & decoder demo program. The "android" tool does not support "update project" in the higher SDK version. Actually, the openh264 libraries have been built successfully.
实际已经编译成功了
ffmpeg
./configure --list-decoders和./configure --list-encoders都有
libopenh264
--enable-libopenh264
ffmpeg中
#include <wels/codec_api.h>
#include <wels/codec_ver.h>
vim meson.build
foreach t : ['', '-static']
pkgconf = configuration_data()
pkgconf.set('prefix', join_paths(get_option('prefix')))
pkgconf.set('VERSION', meson.project_version())
if t == '-static'
do_install = false
pkgconf.set('LIBS', '-lstdc++ -lpthread -lm')
pkgconf.set('LIBS_PRIVATE', '')
else
do_install = true
pkgconf.set('LIBS', '')
pkgconf.set('LIBS_PRIVATE', '-lstdc++ -lpthread -lm')
endif
undefined reference to '__dso_handle'
make install PREFIX=/some/path
make install-static PREFIX=/root/starRTC_ffmpeg/ffmpeg_compile/build_result/armeabi-v7a-neon
undefined reference to XXX_neonerrors at the stage of FFmpeg configuring.
In the end, I set USE_ASM to no and everything was okay.
Makefile
ifeq ($(BUILDTYPE), Release)
CFLAGS += $(CFLAGS_OPT)
USE_ASM = No
else
CFLAGS += $(CFLAGS_DEBUG)
USE_ASM = No
endif
arm-linux-androideabi/bin/ld: error: cannot find -lpthread
改为 -pthread
因为android的ndk虽然有pthread.h,但是没有libpthread.a,集成到libc.a里了-lc

OpenH264编译ffmpeg android的更多相关文章

  1. [原]如何用Android NDK编译FFmpeg

    我们知道在Ubuntu下直接编译FFmpeg是很简单的,主要是先执行./configure,接着执行make命令来编译,完了紧接着执行make install执行安装.那么如何使用Android的ND ...

  2. Android 环境下编译FFmpeg

    Android 环境下编译FFmpeg 开发环境:Ubuntu 12.04.2 LTS , android-sdk-linux, android-ndk-r8e 一 .X264 编译 1.    X2 ...

  3. Android NDK 编译FFmpeg(不需要复杂的环境变量设置)

    环境: CentOS6.2——64位 借鉴:https://vec.io/posts/how-to-build-ffmpeg-with-android-ndk 在根目录下创建work文件夹:cd  / ...

  4. Android开发学习之路--Android Studio cmake编译ffmpeg

      最新的android studio2.2引入了cmake可以很好地实现ndk的编写.这里使用最新的方式,对于以前的android下的ndk编译什么的可以参考之前的文章:Android开发学习之路– ...

  5. 手把手图文并茂教你用Android Studio编译FFmpeg库并移植

    转载请把头部出处链接和尾部二维码一起转载,本文出自逆流的鱼yuiop:http://blog.csdn.net/hejjunlin/article/details/52661331 之前曾写过一篇&l ...

  6. 用Android NDK编译FFmpeg

    附(2018-01-06):     有一个将x264及lame等库集成进去了且基于android的ffmpeg的编译方法,地址参见:       https://github.com/writing ...

  7. [笔记] Ubuntu下编译ffmpeg+openh264+x264

    [下载代码]   - ffmpeg: git clone git://source.ffmpeg.org/ffmpeg.git - openh264: git clone https://github ...

  8. Android中集成ffmpeg(一):编译ffmpeg

    方案选择 Android中集成ffmpeg的codec功能无非两种方式: JNI直接调用,主要用于App开发(无权限修改系统底层),如EXOPlayer,JPlayer等. 集成ffmpeg到OMX, ...

  9. android编译ffmpeg+x264

    下载最新版的x264ftp://ftp.videolan.org/pub/videolan/x264/snapshots/1.解压到指定的目录2.切换当前目录为该目录3.创建一个shell脚本buil ...

随机推荐

  1. C# string和byte[]的转换

    转自 http://www.cnblogs.com/Mainz/archive/2008/04/09/String_Byte_Array_Convert_CSharp.html string类型转成b ...

  2. Sql Server删除数据表中重复记录 三种方法

    本文介绍了Sql Server数据库中删除数据表中重复记录的方法. [项目]数据库中users表,包含u_name,u_pwd两个字段,其中u_name存在重复项,现在要实现把重复的项删除![分析]1 ...

  3. iOS-登录认证/json解析

    用户输入用户名和密码,点击登录...我们把用户名和密码(用post方式或者get方式,get方式多用于测试看你需要)传给服务器,服务器进行判断,然后返回一个接口给我们(这里服务器返回的json接口,正 ...

  4. GitBash:修改GitBash主题配色和字体

    打开GitBash,使用命令: cd ~ 然后: vi .minttyrc 使用下列内容替换已有内容: Font=Consolas FontHeight= ForegroundColour=,, Ba ...

  5. linux系统卡解决方案

    1.查看内存使用率 free -g 运行结果: 2.查看磁盘使用率 df -h 运行结果: 3.查看磁盘IO iostat -x 1 运行结果: 60表示60秒钟刷新一次 4.查看CPU使用情况 to ...

  6. lua的模块加载require

    加载指定的模块.首先函数会在 package.loaded 这个表中查看是否已经加载 了 modname 这个模块.如果是,那么 require 会返回保存在 package.loaded[modna ...

  7. JavaScript 模块化简述

    JavaScript 模块化简述 前言 关于模块化,最直接的表现就是我们写的 require 和 import 关键字,如果查阅相关资料,就一定会遇到 CommonJS .CMD AMD 这些名词,以 ...

  8. 【设计模式】适配器模式与Reader、InputStream之间的适配

    简述 适配器模式,目的是将A对象通过适配.转换的方式转换成B对象来使用,为什么转换为B对象?因为用户通过依赖B对象来使用. 适配器的实现有两种方式. 继承实现 组合实现 基于Java单继承的机制,组合 ...

  9. APT典型应用示例

    Ubuntu下的APT(Advanced Packaging Tools,高级软件包管理工具)是用于在Ubuntu下用于软件安装.升级.维护的工具.注意运行apt指令需要root权限. 下面是一个简单 ...

  10. 九章面试题:Find first K frequency numbers 解题报告

    Find first K frequency numbers /* * Input: int[] A = {1, 1, 2, 3, 4, 5, 2}; k = 3 * return the highe ...