improve error reporting in scripts

development
Taner Sener 7 months ago
parent f86a678a96
commit bfc6c95a5e
  1. 10
      android.sh
  2. 1
      ios.sh
  3. 1
      linux.sh
  4. 1
      macos.sh
  5. 10
      scripts/android/ffmpeg.sh
  6. 2
      scripts/apple/ffmpeg-kit.sh
  7. 8
      scripts/apple/ffmpeg.sh
  8. 15
      scripts/function-apple.sh
  9. 8
      scripts/function-linux.sh
  10. 60
      scripts/function.sh
  11. 2
      scripts/linux/ffmpeg-kit.sh
  12. 8
      scripts/linux/ffmpeg.sh
  13. 8
      scripts/main-android.sh
  14. 8
      scripts/main-ios.sh
  15. 8
      scripts/main-linux.sh
  16. 8
      scripts/main-macos.sh
  17. 8
      scripts/main-tvos.sh
  18. 1
      tvos.sh

@ -229,6 +229,7 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
fi
done
trap fail_operation EXIT
echo -n -e "\nDownloading sources: "
echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1
@ -328,8 +329,7 @@ if [[ -n ${ANDROID_ARCHITECTURES} ]]; then
RC=$(copy_external_library_license_file ${library} "${LICENSE_FILE}")
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi
@ -349,8 +349,7 @@ if [[ -n ${ANDROID_ARCHITECTURES} ]]; then
RC=$?
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi
@ -381,7 +380,6 @@ if [[ -n ${ANDROID_ARCHITECTURES} ]]; then
if [ $? -eq 0 ]; then
echo "ok"
else
echo "failed"
exit 1
fi
else
@ -399,7 +397,6 @@ if [[ -n ${ANDROID_ARCHITECTURES} ]]; then
rm -f "${BASEDIR}"/android/ffmpeg-kit-android-lib/build/outputs/aar/ffmpeg-kit-release.aar 1>>"${BASEDIR}"/build.log 2>&1
./gradlew ffmpeg-kit-android-lib:clean ffmpeg-kit-android-lib:assembleRelease ffmpeg-kit-android-lib:testReleaseUnitTest 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -ne 0 ]; then
echo -e "failed\n"
exit 1
fi
@ -409,7 +406,6 @@ if [[ -n ${ANDROID_ARCHITECTURES} ]]; then
mkdir -p "${FFMPEG_KIT_AAR}" 1>>"${BASEDIR}"/build.log 2>&1
cp "${BASEDIR}"/android/ffmpeg-kit-android-lib/build/outputs/aar/ffmpeg-kit-release.aar "${FFMPEG_KIT_AAR}"/ffmpeg-kit.aar 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -ne 0 ]; then
echo -e "failed\n"
exit 1
fi

@ -254,6 +254,7 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
fi
done
trap fail_operation EXIT
echo -n -e "\nDownloading sources: "
echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1

@ -185,6 +185,7 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_LINUX_XVIDCORE,$LIBRARY_LINUX_X265,$L
fi
done
trap fail_operation EXIT
echo -n -e "\nDownloading sources: "
echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1

@ -220,6 +220,7 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
fi
done
trap fail_operation EXIT
echo -n -e "\nDownloading sources: "
echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1

@ -85,7 +85,7 @@ for library in {0..61}; do
pkg-config --libs --static cpu-features 2>>"${BASEDIR}"/build.log 1>/dev/null
if [[ $? -eq 1 ]]; then
echo -e "ERROR: cpu-features was not found in the pkg-config search path\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "\nffmpeg: failed\n\nSee build.log for details\n"
echo -e "\nffmpeg: "
exit 1
fi
;;
@ -469,7 +469,6 @@ fi
${CONFIGURE_POSTFIX} 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -477,18 +476,15 @@ if [[ -z ${NO_OUTPUT_REDIRECTION} ]]; then
make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
echo -e "started\n"
make -j$(get_cpu_count)
echo -n -e "\n${LIB_NAME}: "
if [[ $? -ne 0 ]]; then
echo -n -e "\n${LIB_NAME}: failed\n\nSee build.log for details\n"
exit 1
else
echo -n -e "\n${LIB_NAME}: "
fi
fi
@ -499,7 +495,6 @@ fi
make install 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -511,6 +506,5 @@ rsync -am --include='*.h' --include='*/' --exclude='*' "${BASEDIR}"/src/ffmpeg/
if [ $? -eq 0 ]; then
echo "ok"
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi

@ -73,7 +73,6 @@ ${SED_INLINE} "s|allow_undefined_flag -o|allow_undefined_flag -target $(get_targ
${SED_INLINE} 's|\$rpath/\\$soname|@rpath/ffmpegkit.framework/ffmpegkit|g' libtool 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -ne 0 ]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -89,6 +88,5 @@ make install 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -eq 0 ]; then
echo "ok"
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi

@ -552,7 +552,6 @@ ${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR
${CONFIGURE_POSTFIX} 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -561,18 +560,15 @@ build_ffmpeg() {
make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
echo -e "started\n"
make -j$(get_cpu_count)
echo -n -e "\n${LIB_NAME}: "
if [[ $? -ne 0 ]]; then
echo -n -e "\n${LIB_NAME}: failed\n\nSee build.log for details\n"
exit 1
else
echo -n -e "\n${LIB_NAME}: "
fi
fi
}
@ -595,7 +591,6 @@ install_ffmpeg() {
make install 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
}
@ -641,6 +636,5 @@ rsync -am --include='*.h' --include='*/' --exclude='*' "${BASEDIR}"/src/ffmpeg/
if [ $? -eq 0 ]; then
echo "ok"
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi

@ -262,8 +262,7 @@ create_ffmpeg_universal_library() {
RC=$?
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi
@ -427,8 +426,7 @@ create_ffmpeg_framework() {
RC=$?
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi
@ -1112,8 +1110,7 @@ get_sdk_path() {
# 1. XCFRAMEWORK NAME
#
exit_xcframework() {
echo -e "INFO: Building $1 xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Building $1 xcframework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
}
@ -1121,8 +1118,7 @@ exit_xcframework() {
# 1. FRAMEWORK NAME
#
exit_framework() {
echo -e "INFO: Building $1 framework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Building $1 framework failed\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
}
@ -1130,8 +1126,7 @@ exit_framework() {
# 1. UNIVERSAL LIBRARY NAME
#
exit_universal_library() {
echo -e "\nINFO: Failed to build universal $1 library\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "\nERROR: Failed to build universal $1 library\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
}

@ -98,14 +98,12 @@ install_pkg_config_file() {
# DELETE OLD FILE
rm -f "$DESTINATION" 2>>"${BASEDIR}"/build.log
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
# INSTALL THE NEW FILE
cp "$SOURCE" "$DESTINATION" 2>>"${BASEDIR}"/build.log
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -165,8 +163,7 @@ create_linux_bundle() {
RC=$(copy_external_library_license_file ${library} "${LICENSE_FILE}")
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of ${ENABLED_LIBRARY}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi
@ -186,8 +183,7 @@ create_linux_bundle() {
RC=$?
if [[ ${RC} -ne 0 ]]; then
echo -e "DEBUG: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n\nSee build.log for details\n"
echo -e "ERROR: Failed to copy the license file of custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
fi

@ -1928,8 +1928,8 @@ clone_git_repository_with_commit_id() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to create local directory $2\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to create local directory $2\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$2" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -1941,8 +1941,8 @@ clone_git_repository_with_commit_id() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to clone $1\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to clone $1\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$2" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -1952,8 +1952,8 @@ clone_git_repository_with_commit_id() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to cd into $2\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to cd into $2\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$2" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -1963,8 +1963,8 @@ clone_git_repository_with_commit_id() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to fetch commit id $3 from $1\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to fetch commit id $3 from $1\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$2" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -1974,8 +1974,8 @@ clone_git_repository_with_commit_id() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to checkout commit id $3 from $1\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to checkout commit id $3 from $1\n" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
fi
@ -1995,8 +1995,8 @@ clone_git_repository_with_tag() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to create local directory $3\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to create local directory $3\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$3" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -2008,8 +2008,8 @@ clone_git_repository_with_tag() {
RC=$?
if [ ${RC} -ne 0 ]; then
echo -e "\nINFO: Failed to clone $1 -> $2\n" 1>>"${BASEDIR}"/build.log 2>&1
if [[ ${RC} -ne 0 ]]; then
echo -e "\nERROR: Failed to clone $1 -> $2\n" 1>>"${BASEDIR}"/build.log 2>&1
rm -rf "$3" 1>>"${BASEDIR}"/build.log 2>&1
echo ${RC}
return
@ -2035,34 +2035,26 @@ is_gpl_licensed() {
downloaded_library_sources() {
# DOWNLOAD FFMPEG SOURCE CODE FIRST
DOWNLOAD_RESULT=$(download_library_source "ffmpeg")
if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
echo -e "failed\n"
if [[ $(download_library_source "ffmpeg") -ne 0 ]]; then
exit 1
fi
# DOWNLOAD LIBRARY SOURCES
for library in {1..50}; do
if [[ ${!library} -eq 1 ]]; then
library_name=$(get_library_name $((library - 1)))
echo -e "\nDEBUG: Downloading library ${library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
DOWNLOAD_RESULT=$(download_library_source "${library_name}")
if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
echo -e "failed\n"
if [[ $(download_library_source "${library_name}") -ne 0 ]]; then
exit 1
fi
fi
done
# DOWNLOAD CUSTOM LIBRARY SOURCES
for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
library_name="CUSTOM_LIBRARY_${custom_library_index}_NAME"
echo -e "\nDEBUG: Downloading custom library ${!library_name}\n" 1>>"${BASEDIR}"/build.log 2>&1
DOWNLOAD_RESULT=$(download_custom_library_source "${custom_library_index}")
if [[ ${DOWNLOAD_RESULT} -ne 0 ]]; then
echo -e "failed\n"
if [[ $(download_custom_library_source "${custom_library_index}") -ne 0 ]]; then
exit 1
fi
done
@ -2089,7 +2081,7 @@ download() {
else
rm -f "${FFMPEG_KIT_TMPDIR}"/"$2" 1>>"${BASEDIR}"/build.log 2>&1
echo -e -n "\nINFO: Failed to download $1 to ${FFMPEG_KIT_TMPDIR}/$2, rc=${RC}. " 1>>"${BASEDIR}"/build.log 2>&1
echo -e -n "\nERROR: Failed to download $1 to ${FFMPEG_KIT_TMPDIR}/$2, rc=${RC}. " 1>>"${BASEDIR}"/build.log 2>&1
if [ "$3" == "exit" ]; then
echo -e "DEBUG: Build will now exit.\n" 1>>"${BASEDIR}"/build.log 2>&1
@ -2135,7 +2127,7 @@ download_library_source() {
fi
if [ ${DOWNLOAD_RC} -ne 0 ]; then
echo -e "INFO: Downloading library $1 failed. Can not get library from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "ERROR: Downloading library $1 failed. Can not get library from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo ${DOWNLOAD_RC}
else
echo -e "\nINFO: $1 library downloaded" 1>>"${BASEDIR}"/build.log 2>&1
@ -2186,7 +2178,7 @@ download_custom_library_source() {
fi
if [ ${DOWNLOAD_RC} -ne 0 ]; then
echo -e "INFO: Downloading custom library ${LIB_NAME} failed. Can not get library from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "ERROR: Downloading custom library ${LIB_NAME} failed. Can not get library from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo ${DOWNLOAD_RC}
else
echo -e "\nINFO: ${LIB_NAME} custom library downloaded" 1>>"${BASEDIR}"/build.log 2>&1
@ -2222,8 +2214,7 @@ download_gnu_config() {
DOWNLOAD_RC=$(clone_git_repository_with_tag "${SOURCE_REPO_URL}" "${SOURCE_ID}" "${LIB_LOCAL_PATH}")
if [[ ${DOWNLOAD_RC} -ne 0 ]]; then
echo -e "INFO: Downloading gnu config failed. Can not get source from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
echo -e "failed\n"
echo -e "ERROR: Downloading gnu config failed. Can not get source from ${SOURCE_REPO_URL}\n" 1>>"${BASEDIR}"/build.log 2>&1
exit 1
else
echo -e "\nINFO: gnu config downloaded successfully\n" 1>>"${BASEDIR}"/build.log 2>&1
@ -2423,3 +2414,8 @@ initialize_folder() {
return 0
}
fail_operation() {
echo -e "failed\n"
echo -e "See build.log for the details\n"
}

@ -48,7 +48,6 @@ autoreconf_library "${LIB_NAME}" 1>>"${BASEDIR}"/build.log 2>&1 || return 1
--host="${HOST}" 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -ne 0 ]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -62,7 +61,6 @@ make -j$(get_cpu_count) install 1>>"${BASEDIR}"/build.log 2>&1
if [ $? -eq 0 ]; then
echo "ok"
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi

@ -414,7 +414,6 @@ ${SED_INLINE} 's/static int av_log_level/__thread int av_log_level/g' "${BASEDIR
${CONFIGURE_POSTFIX} 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -422,18 +421,15 @@ if [[ -z ${NO_OUTPUT_REDIRECTION} ]]; then
make -j$(get_cpu_count) 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
echo -e "started\n"
make -j$(get_cpu_count)
echo -n -e "\n${LIB_NAME}: "
if [[ $? -ne 0 ]]; then
echo -n -e "\n${LIB_NAME}: failed\n\nSee build.log for details\n"
exit 1
else
echo -n -e "\n${LIB_NAME}: "
fi
fi
@ -444,7 +440,6 @@ fi
make install 1>>"${BASEDIR}"/build.log 2>&1
if [[ $? -ne 0 ]]; then
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
@ -465,6 +460,5 @@ rsync -am --include='*.h' --include='*/' --exclude='*' "${BASEDIR}"/src/ffmpeg/
if [ $? -eq 0 ]; then
echo "ok"
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi

@ -178,11 +178,7 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
@ -219,11 +215,7 @@ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
# SET SOME FLAGS AFTER THE BUILD
if [ $RC -eq 0 ]; then
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else

@ -155,11 +155,7 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
@ -196,11 +192,7 @@ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
# SET SOME FLAGS AFTER THE BUILD
if [ $RC -eq 0 ]; then
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else

@ -75,11 +75,7 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
@ -116,11 +112,7 @@ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
# SET SOME FLAGS AFTER THE BUILD
if [ $RC -eq 0 ]; then
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else

@ -154,11 +154,7 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
@ -195,11 +191,7 @@ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
# SET SOME FLAGS AFTER THE BUILD
if [ $RC -eq 0 ]; then
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else

@ -153,11 +153,7 @@ while [ ${#enabled_library_list[@]} -gt $completed ]; do
declare "$BUILD_COMPLETED_FLAG=1"
check_if_dependency_rebuilt "${library}"
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else
@ -194,11 +190,7 @@ for custom_library_index in "${CUSTOM_LIBRARIES[@]}"; do
# SET SOME FLAGS AFTER THE BUILD
if [ $RC -eq 0 ]; then
echo "ok"
elif [ $RC -eq 200 ]; then
echo -e "not supported\n\nSee build.log for details\n"
exit 1
else
echo -e "failed\n\nSee build.log for details\n"
exit 1
fi
else

@ -234,6 +234,7 @@ for gpl_library in {$LIBRARY_X264,$LIBRARY_XVIDCORE,$LIBRARY_X265,$LIBRARY_LIBVI
fi
done
trap fail_operation EXIT
echo -n -e "\nDownloading sources: "
echo -e "INFO: Downloading the source code of ffmpeg and external libraries.\n" 1>>"${BASEDIR}"/build.log 2>&1

Loading…
Cancel
Save