Skip to content

Commit 6db01dd

Browse files
committed
Update README.md
1 parent 6cfca65 commit 6db01dd

File tree

1 file changed

+45
-2
lines changed

1 file changed

+45
-2
lines changed

README.md

Lines changed: 45 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,56 @@
77
android-ndk64-r10-linux-x86_64
88

99
# 获取代码
10-
``
10+
```
1111
git clone git@github.com:dxjia/ffmpeg-for-android-shared-library.git
12-
``
12+
```
13+
14+
# 介绍
15+
build_android.sh<br>
16+
```java
17+
#!/bin/bash
18+
export TMPDIR=/home/djia/tmpdir
19+
NDK=/home/djia/android/android-ndk-r10
20+
SYSROOT=$NDK/platforms/android-16/arch-arm/
21+
TOOLCHAIN=/home/djia/android/android-ndk-r10/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64
22+
function build_one
23+
{
24+
./configure \
25+
--prefix=$PREFIX \
26+
--enable-shared \
27+
--disable-static \
28+
--disable-doc \
29+
--disable-ffmpeg \
30+
--disable-ffplay \
31+
--disable-ffprobe \
32+
--disable-ffserver \
33+
--disable-doc \
34+
--disable-symver \
35+
--enable-small \
36+
--cross-prefix=$TOOLCHAIN/bin/arm-linux-androideabi- \
37+
--target-os=linux \
38+
--arch=arm \
39+
--enable-cross-compile \
40+
--sysroot=$SYSROOT \
41+
--extra-cflags="-Os -fpic $ADDI_CFLAGS" \
42+
--extra-ldflags="$ADDI_LDFLAGS" \
43+
$ADDITIONAL_CONFIGURE_FLAG
44+
make clean
45+
make
46+
make install
47+
}
48+
CPU=arm
49+
PREFIX=/root/workspace/ffmpeg_shared_compile/dxjia_ffmpeg_install
50+
ADDI_CFLAGS="-marm"
51+
build_one
52+
```
53+
1354

1455
#编译
56+
```
1557
cd source/ffmpeg<br>
1658
./build_andrioid.sh
59+
```
1760

1861
# Reference & Thanks
1962
[android-ffmpeg-tutorial](https://github.com/roman10/android-ffmpeg-tutorial)

0 commit comments

Comments
 (0)