mirror of https://github.com/ArduPilot/ardupilot
Tools: install-prereqs-ubuntu.sh: add support for Ubuntu Noble (24.04)
This commit is contained in:
parent
8c91077c35
commit
4320063bd6
|
@ -114,6 +114,11 @@ elif [ ${RELEASE_CODENAME} == 'mantic' ]; then
|
||||||
SITLCFML_VERSION="2.5"
|
SITLCFML_VERSION="2.5"
|
||||||
PYTHON_V="python3"
|
PYTHON_V="python3"
|
||||||
PIP=pip3
|
PIP=pip3
|
||||||
|
elif [ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
|
SITLFML_VERSION="2.6"
|
||||||
|
SITLCFML_VERSION="2.6"
|
||||||
|
PYTHON_V="python3"
|
||||||
|
PIP=pip3
|
||||||
elif [ ${RELEASE_CODENAME} == 'groovy' ] ||
|
elif [ ${RELEASE_CODENAME} == 'groovy' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'bullseye' ]; then
|
[ ${RELEASE_CODENAME} == 'bullseye' ]; then
|
||||||
SITLFML_VERSION="2.5"
|
SITLFML_VERSION="2.5"
|
||||||
|
@ -169,7 +174,8 @@ ARM_LINUX_PKGS="g++-arm-linux-gnueabihf $INSTALL_PKG_CONFIG"
|
||||||
|
|
||||||
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'mantic' ]; then
|
[ ${RELEASE_CODENAME} == 'mantic' ] ||
|
||||||
|
[ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
# on Lunar (and presumably later releases), we install in venv, below
|
# on Lunar (and presumably later releases), we install in venv, below
|
||||||
PYTHON_PKGS+=" numpy pyparsing psutil"
|
PYTHON_PKGS+=" numpy pyparsing psutil"
|
||||||
SITL_PKGS="python3-dev"
|
SITL_PKGS="python3-dev"
|
||||||
|
@ -181,7 +187,8 @@ fi
|
||||||
if [[ $SKIP_AP_GRAPHIC_ENV -ne 1 ]]; then
|
if [[ $SKIP_AP_GRAPHIC_ENV -ne 1 ]]; then
|
||||||
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'mantic' ]; then
|
[ ${RELEASE_CODENAME} == 'mantic' ] ||
|
||||||
|
[ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
PYTHON_PKGS+=" matplotlib scipy opencv-python pyyaml"
|
PYTHON_PKGS+=" matplotlib scipy opencv-python pyyaml"
|
||||||
SITL_PKGS+=" xterm libcsfml-dev libcsfml-audio${SITLCFML_VERSION} libcsfml-dev libcsfml-graphics${SITLCFML_VERSION} libcsfml-network${SITLCFML_VERSION} libcsfml-system${SITLCFML_VERSION} libcsfml-window${SITLCFML_VERSION} libsfml-audio${SITLFML_VERSION} libsfml-dev libsfml-graphics${SITLFML_VERSION} libsfml-network${SITLFML_VERSION} libsfml-system${SITLFML_VERSION} libsfml-window${SITLFML_VERSION}"
|
SITL_PKGS+=" xterm libcsfml-dev libcsfml-audio${SITLCFML_VERSION} libcsfml-dev libcsfml-graphics${SITLCFML_VERSION} libcsfml-network${SITLCFML_VERSION} libcsfml-system${SITLCFML_VERSION} libcsfml-window${SITLCFML_VERSION} libsfml-audio${SITLFML_VERSION} libsfml-dev libsfml-graphics${SITLFML_VERSION} libsfml-network${SITLFML_VERSION} libsfml-system${SITLFML_VERSION} libsfml-window${SITLFML_VERSION}"
|
||||||
else
|
else
|
||||||
|
@ -274,7 +281,8 @@ elif [ ${RELEASE_CODENAME} == 'lunar' ]; then
|
||||||
SITL_PKGS+=" libpython3-stdlib" # for argparse
|
SITL_PKGS+=" libpython3-stdlib" # for argparse
|
||||||
elif [ ${RELEASE_CODENAME} == 'buster' ]; then
|
elif [ ${RELEASE_CODENAME} == 'buster' ]; then
|
||||||
SITL_PKGS+=" libpython3-stdlib" # for argparse
|
SITL_PKGS+=" libpython3-stdlib" # for argparse
|
||||||
elif [ ${RELEASE_CODENAME} != 'mantic' ]; then
|
elif [ ${RELEASE_CODENAME} != 'mantic' ] &&
|
||||||
|
[ ${RELEASE_CODENAME} != 'noble' ]; then
|
||||||
SITL_PKGS+=" python-argparse"
|
SITL_PKGS+=" python-argparse"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -293,6 +301,9 @@ if [[ $SKIP_AP_GRAPHIC_ENV -ne 1 ]]; then
|
||||||
elif [ ${RELEASE_CODENAME} == 'mantic' ]; then
|
elif [ ${RELEASE_CODENAME} == 'mantic' ]; then
|
||||||
SITL_PKGS+=" libgtk-3-dev libwxgtk3.2-dev "
|
SITL_PKGS+=" libgtk-3-dev libwxgtk3.2-dev "
|
||||||
# see below
|
# see below
|
||||||
|
elif [ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
|
SITL_PKGS+=" libgtk-3-dev libwxgtk3.2-dev "
|
||||||
|
# see below
|
||||||
elif apt-cache search python-wxgtk3.0 | grep wx; then
|
elif apt-cache search python-wxgtk3.0 | grep wx; then
|
||||||
SITL_PKGS+=" python-wxgtk3.0"
|
SITL_PKGS+=" python-wxgtk3.0"
|
||||||
elif apt-cache search python3-wxgtk4.0 | grep wx; then
|
elif apt-cache search python3-wxgtk4.0 | grep wx; then
|
||||||
|
@ -312,7 +323,8 @@ if [[ $SKIP_AP_GRAPHIC_ENV -ne 1 ]]; then
|
||||||
PYTHON_PKGS+=" wxpython opencv-python"
|
PYTHON_PKGS+=" wxpython opencv-python"
|
||||||
SITL_PKGS+=" python3-wxgtk4.0"
|
SITL_PKGS+=" python3-wxgtk4.0"
|
||||||
SITL_PKGS+=" fonts-freefont-ttf libfreetype6-dev libpng16-16 libportmidi-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsdl1.2-dev" # for pygame
|
SITL_PKGS+=" fonts-freefont-ttf libfreetype6-dev libpng16-16 libportmidi-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsdl1.2-dev" # for pygame
|
||||||
elif [ ${RELEASE_CODENAME} == 'mantic' ]; then
|
elif [ ${RELEASE_CODENAME} == 'mantic' ] ||
|
||||||
|
[ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
PYTHON_PKGS+=" wxpython opencv-python"
|
PYTHON_PKGS+=" wxpython opencv-python"
|
||||||
SITL_PKGS+=" python3-wxgtk4.0"
|
SITL_PKGS+=" python3-wxgtk4.0"
|
||||||
SITL_PKGS+=" fonts-freefont-ttf libfreetype6-dev libpng16-16 libportmidi-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsdl1.2-dev" # for pygame
|
SITL_PKGS+=" fonts-freefont-ttf libfreetype6-dev libpng16-16 libportmidi-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev libsdl1.2-dev" # for pygame
|
||||||
|
@ -360,10 +372,17 @@ fi
|
||||||
PIP_USER_ARGUMENT="--user"
|
PIP_USER_ARGUMENT="--user"
|
||||||
|
|
||||||
# create a Python venv on more recent releases:
|
# create a Python venv on more recent releases:
|
||||||
|
PYTHON_VENV_PACKAGE=""
|
||||||
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'mantic' ]; then
|
[ ${RELEASE_CODENAME} == 'mantic' ]; then
|
||||||
$APT_GET install python3.11-venv
|
PYTHON_VENV_PACKAGE=python3.11-venv
|
||||||
|
elif [ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
|
PYTHON_VENV_PACKAGE=python3.12-venv
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$PYTHON_VENV_PACKAGE" ]; then
|
||||||
|
$APT_GET install $PYTHON_VENV_PACKAGE
|
||||||
python3 -m venv $HOME/venv-ardupilot
|
python3 -m venv $HOME/venv-ardupilot
|
||||||
|
|
||||||
# activate it:
|
# activate it:
|
||||||
|
@ -389,7 +408,8 @@ fi
|
||||||
|
|
||||||
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
if [ ${RELEASE_CODENAME} == 'bookworm' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
[ ${RELEASE_CODENAME} == 'lunar' ] ||
|
||||||
[ ${RELEASE_CODENAME} == 'mantic' ]; then
|
[ ${RELEASE_CODENAME} == 'mantic' ] ||
|
||||||
|
[ ${RELEASE_CODENAME} == 'noble' ]; then
|
||||||
# must do this ahead of wxPython pip3 run :-/
|
# must do this ahead of wxPython pip3 run :-/
|
||||||
$PIP install $PIP_USER_ARGUMENT -U attrdict3
|
$PIP install $PIP_USER_ARGUMENT -U attrdict3
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue