diff --git a/utils/common.sh b/utils/common.sh index 1baf3f5..2b696a7 100644 --- a/utils/common.sh +++ b/utils/common.sh @@ -207,6 +207,16 @@ function required_packages() { case "$DISTRO_NAME" in debian | ubuntu | raspbian | linuxmint | zorin) [ "$DISTRO_VERSION_ID" == "11" ] && export PYTHON_VERSION="3" + # This is a temporary fix until OVOS is confirmed to work with + # Python 3.12. Requirements are PocketSphinx, tflite-runtime and + # onnxruntime Python packages. + if [ "$(ver "$DISTRO_VERSION_ID")" -ge "$(ver 24.04)" ]; then + { + apt-get update + apt-get install --no-install-recommends -y software-properties-common + add-apt-repository ppa:deadsnakes/ppa -y + } &>>"$LOG_FILE" + fi apt-get update &>>"$LOG_FILE" apt-get install --no-install-recommends -y "python${PYTHON_VERSION}" "python${PYTHON_VERSION}-dev" python3-pip "python${PYTHON_VERSION}-venv" whiptail expect jq "${extra_packages[@]}" &>>"$LOG_FILE" ;;