1
0
mirror of git://f0xx.org/android_cast synced 2026-07-29 02:59:00 +03:00
This commit is contained in:
Anton Afanasyeu
2026-05-17 22:49:49 +02:00
parent ab5c28b49a
commit 4f0be2785d
219 changed files with 14883 additions and 437 deletions

32
scripts/build-native-codecs.sh Executable file
View File

@@ -0,0 +1,32 @@
#!/usr/bin/env bash
# Optional: build third-party codecs for Android and point Gradle/CMake at the outputs.
#
# Prerequisites:
# git submodule update --init --recursive third-party/libvpx third-party/opus third-party/speex
# Android NDK (same as used by the app, see local.properties or ndk.dir)
#
# Usage:
# ./scripts/build-native-codecs.sh arm64-v8a
# ANDROIDCAST_LIBVPX_LIB=$PWD/build/native/arm64-v8a/libvpx.a ./gradlew assembleDebug
#
set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
ABI="${1:-arm64-v8a}"
OUT="$ROOT/build/native/$ABI"
mkdir -p "$OUT"
echo "Native codec build scaffold — ABI=$ABI"
echo "Output directory: $OUT"
echo ""
echo "libvpx Android cross-compile is project-specific. After you produce libvpx.a, rebuild with:"
echo " export ANDROIDCAST_LIBVPX_LIB=$OUT/libvpx.a"
echo " ./gradlew assembleDebug"
echo ""
if [[ ! -d "$ROOT/third-party/libvpx" ]]; then
echo "WARN: third-party/libvpx missing. Run: git submodule update --init third-party/libvpx"
exit 1
fi
echo "libvpx sources present at third-party/libvpx — add your configure/make steps here."
touch "$OUT/.placeholder"
echo "Done (placeholder). See ndk/README.md for integration notes."