add ffmpeg option to android build script
This commit is contained in:
parent
0fb83a304d
commit
cdb7563cf7
@ -736,7 +736,6 @@ if(ANDROID)
|
|||||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
set(PULSE_FEATURE_TYPE "DISABLED")
|
||||||
set(CUPS_FEATURE_TYPE "DISABLED")
|
set(CUPS_FEATURE_TYPE "DISABLED")
|
||||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||||
set(FFMPEG_FEATURE_TYPE "DISABLED")
|
|
||||||
set(VAAPI_FEATURE_TYPE "DISABLED")
|
set(VAAPI_FEATURE_TYPE "DISABLED")
|
||||||
set(OPENSLES_FEATURE_TYPE "REQUIRED")
|
set(OPENSLES_FEATURE_TYPE "REQUIRED")
|
||||||
endif()
|
endif()
|
||||||
|
@ -7,6 +7,7 @@ OPENSSL_TAG=master
|
|||||||
WITH_JPEG=0
|
WITH_JPEG=0
|
||||||
WITH_OPENH264=0
|
WITH_OPENH264=0
|
||||||
WITH_OPENSSL=0
|
WITH_OPENSSL=0
|
||||||
|
WITH_FFMPEG=0
|
||||||
|
|
||||||
SRC_DIR=$(dirname "${BASH_SOURCE[0]}")
|
SRC_DIR=$(dirname "${BASH_SOURCE[0]}")
|
||||||
SRC_DIR=$(realpath "$SRC_DIR")
|
SRC_DIR=$(realpath "$SRC_DIR")
|
||||||
@ -43,6 +44,14 @@ do
|
|||||||
ANDROID_NDK_OPENH264=$1
|
ANDROID_NDK_OPENH264=$1
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
|
--ffmpeg)
|
||||||
|
WITH_FFMPEG=1
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
--ffmpeg-path)
|
||||||
|
FFMPEG_PATH="$2"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
--openssl)
|
--openssl)
|
||||||
WITH_OPENSSL=1
|
WITH_OPENSSL=1
|
||||||
shift
|
shift
|
||||||
@ -133,6 +142,15 @@ do
|
|||||||
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_OPENH264=ON"
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_OPENH264=ON"
|
||||||
else
|
else
|
||||||
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_OPENH264=OFF"
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_OPENH264=OFF"
|
||||||
|
fi
|
||||||
|
if [ $WITH_FFMPEG -ne 0 ];
|
||||||
|
then
|
||||||
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_FFMPEG=ON"
|
||||||
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DAVCODEC_INCLUDE_DIRS=$FFMPEG_PATH/$ARCH/include -DAVCODEC_LIBRARY_DIRS=$FFMPEG_PATH/$ARCH/lib"
|
||||||
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DAVUTIL_INCLUDE_DIRS=$FFMPEG_PATH/$ARCH/include -DAVUTIL_LIBRARY_DIRS=$FFMPEG_PATH/$ARCH/lib"
|
||||||
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DSWRESAMPLE_INCLUDE_DIRS=$FFMPEG_PATH/$ARCH/include -DSWRESAMPLE_LIBRARY_DIRS=$FFMPEG_PATH/$ARCH/lib"
|
||||||
|
else
|
||||||
|
CMAKE_CMD_ARGS="$CMAKE_CMD_ARGS -DWITH_FFMPEG=OFF"
|
||||||
fi
|
fi
|
||||||
if [ $WITH_OPENSSL -ne 0 ];
|
if [ $WITH_OPENSSL -ne 0 ];
|
||||||
then
|
then
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
# create seperate configurations for each NDK API level
|
# create seperate configurations for each NDK API level
|
||||||
# and architecture you want to support.
|
# and architecture you want to support.
|
||||||
WITH_JPEG=0
|
WITH_JPEG=0
|
||||||
|
WITH_FFMPEG=0
|
||||||
WITH_OPENH264=1
|
WITH_OPENH264=1
|
||||||
WITH_OPENSSL=1
|
WITH_OPENSSL=1
|
||||||
BUILD_DEPS=1
|
BUILD_DEPS=1
|
||||||
|
Loading…
Reference in New Issue
Block a user