-
Notifications
You must be signed in to change notification settings - Fork 0
Building
Condensed version of docs/BUILD.md — that file is the canonical, fully detailed guide; this page is a quick reference.
FFmpegKit native build pipeline only runs on Linux or macOS. On Windows, use WSL2 with Ubuntu.
wsl --install -d Ubuntu-22.04Inside Ubuntu:
sudo apt update
sudo apt install -y autoconf automake libtool pkg-config curl git \
build-essential yasm nasm gperf texinfo bison ragel \
python3 python3-pip unzip zip wget meson ninja-build openjdk-17-jdk
export ANDROID_SDK_ROOT="$HOME/android-sdk"
# ... install cmdline-tools, then:
sdkmanager "platform-tools" "platforms;android-35" "ndk;26.2.11394342"
export ANDROID_NDK_ROOT="$ANDROID_SDK_ROOT/ndk/26.2.11394342"
export JAVA_HOME="/usr/lib/jvm/java-17-openjdk-amd64"git clone --recurse-submodules https://github.com/ffmpegkit-maintained/ffmpeg-kit.git
cd ffmpeg-kit
./android.sh --enable-full # or --enable-audio / --enable-video / --enable-httpsUseful flags: --lts (older NDK/API baseline), -d/--debug, -s/--speed, --arch=<arch>. Run ./android.sh --help for the full list.
Output lands under prebuilt/android-<arch>/ffmpeg/lib/ (shared libraries) and prebuilt/bundle-android-aar/ (the .aar).
for so in $(find prebuilt -name "*.so"); do
echo "$so:"
objdump -p "$so" | grep -A1 LOAD | grep align
doneSegment alignment should report 2**14 (16384) or higher — see the Android 16 KB page size guide on developer.android.com. This check is currently manual; it is not enforced in CI yet (see Compatibility).
See docs/BUILD.md, Troubleshooting section, for the full list (missing autoreconf, NDK toolchain path issues, hung configure steps, WSL2 OOM).