ffmpeg-kit/scripts/android/xvidcore.sh

38 lines
880 B
Bash
Raw Permalink Normal View History

2020-08-05 03:53:02 +03:00
#!/bin/bash
2020-11-23 00:51:45 +02:00
cd "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/build/generic || return 1
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
# SET BUILD OPTIONS
ASM_OPTIONS=""
case ${ARCH} in
x86)
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
# please note that asm is disabled
# enabling asm for x86 causes text relocations in libavcodec.so
ASM_OPTIONS="--disable-assembly"
;;
esac
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
# ALWAYS CLEAN THE PREVIOUS BUILD
2020-08-05 03:53:02 +03:00
make distclean 2>/dev/null 1>/dev/null
2020-11-23 00:51:45 +02:00
# REGENERATE BUILD FILES IF NECESSARY OR REQUESTED
if [[ ! -f "${BASEDIR}"/src/"${LIB_NAME}"/"${LIB_NAME}"/build/generic/configure ]] || [[ ${RECONF_xvidcore} -eq 1 ]]; then
./bootstrap.sh
2020-08-05 03:53:02 +03:00
fi
./configure \
2020-11-23 00:51:45 +02:00
--prefix="${LIB_INSTALL_PREFIX}" \
${ASM_OPTIONS} \
--host="${HOST}" || return 1
2020-08-05 03:53:02 +03:00
make || return 1
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
make install || return 1
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
# CREATE PACKAGE CONFIG MANUALLY
create_xvidcore_package_config "1.3.7" || return 1
2020-08-05 03:53:02 +03:00
2020-11-23 00:51:45 +02:00
# WORKAROUND TO REMOVE DYNAMIC LIBS
rm -f "${LIB_INSTALL_PREFIX}"/lib/libxvidcore.so*