forked from Archive/PX4-Autopilot
cmake and Tools/setup.sh default to python3
This commit is contained in:
parent
f593e3de9c
commit
4b3f68f90c
|
@ -18,22 +18,34 @@ do
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# install Homebrew
|
||||||
|
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null
|
||||||
|
|
||||||
|
# confirm Homebrew installed correctly
|
||||||
|
brew doctor
|
||||||
|
|
||||||
# Install px4-dev formula
|
# Install px4-dev formula
|
||||||
brew tap PX4/px4
|
echo
|
||||||
if [ brew ls --versions px4-dev > /dev/null ]; then
|
echo "Installing PX4 general dependencies (homebrew px4-dev)"
|
||||||
brew install px4-dev
|
|
||||||
elif [[ $REINSTALL_FORMULAS == "--reinstall" ]]; then
|
if [[ $REINSTALL_FORMULAS == "--reinstall" ]]; then
|
||||||
|
brew tap PX4/px4
|
||||||
brew reinstall px4-dev
|
brew reinstall px4-dev
|
||||||
|
elif brew ls --versions px4-dev > /dev/null; then
|
||||||
|
brew tap PX4/px4
|
||||||
|
brew install px4-dev
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Python dependencies
|
# Python3 dependencies
|
||||||
sudo easy_install pip
|
echo
|
||||||
sudo -H python3 -m pip install --upgrade --force-reinstall pip
|
echo "Installing PX4 Python3 dependencies"
|
||||||
sudo -H python3 -m pip install -I -r ${DIR}/requirements.txt
|
brew install python3
|
||||||
|
sudo -H python3 -m pip install --upgrade pip
|
||||||
|
sudo -H python3 -m pip install -r ${DIR}/requirements.txt
|
||||||
|
|
||||||
# Optional, but recommended additional simulation tools:
|
# Optional, but recommended additional simulation tools:
|
||||||
if [[ $INSTALL_SIM == "--sim-tools" ]]; then
|
if [[ $INSTALL_SIM == "--sim-tools" ]]; then
|
||||||
if [ brew ls --versions px4-sim > /dev/null ]; then
|
if brew ls --versions px4-sim > /dev/null; then
|
||||||
brew install px4-sim
|
brew install px4-sim
|
||||||
elif [[ $REINSTALL_FORMULAS == "--reinstall" ]]; then
|
elif [[ $REINSTALL_FORMULAS == "--reinstall" ]]; then
|
||||||
brew reinstall px4-sim
|
brew reinstall px4-sim
|
||||||
|
|
|
@ -2,6 +2,7 @@ argparse>=1.2
|
||||||
cerberus
|
cerberus
|
||||||
empy>=3.3
|
empy>=3.3
|
||||||
jinja2>=2.8
|
jinja2>=2.8
|
||||||
|
matplotlib
|
||||||
nose
|
nose
|
||||||
numpy>=1.13
|
numpy>=1.13
|
||||||
pandas>=0.21
|
pandas>=0.21
|
||||||
|
@ -12,4 +13,3 @@ setuptools>=39.2.0
|
||||||
toml>=0.9
|
toml>=0.9
|
||||||
tornado
|
tornado
|
||||||
wheel>=0.31.1
|
wheel>=0.31.1
|
||||||
matplotlib
|
|
||||||
|
|
|
@ -49,6 +49,7 @@ fi
|
||||||
|
|
||||||
export DEBIAN_FRONTEND=noninteractive
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
|
echo
|
||||||
echo "Installing PX4 general dependencies"
|
echo "Installing PX4 general dependencies"
|
||||||
|
|
||||||
sudo apt-get update -yy --quiet
|
sudo apt-get update -yy --quiet
|
||||||
|
@ -81,20 +82,16 @@ sudo apt-get -yy --quiet --no-install-recommends install \
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
# python dependencies
|
# Python3 dependencies
|
||||||
echo "Installing PX4 Python dependencies"
|
echo
|
||||||
|
echo "Installing PX4 Python3 dependencies"
|
||||||
# TODO: deprecate python 2
|
|
||||||
sudo python -m pip install --upgrade pip setuptools wheel
|
|
||||||
sudo python -m pip install -r ${DIR}/requirements.txt
|
|
||||||
|
|
||||||
sudo python3 -m pip install --upgrade pip setuptools wheel
|
sudo python3 -m pip install --upgrade pip setuptools wheel
|
||||||
sudo python3 -m pip install -r ${DIR}/requirements.txt
|
sudo python3 -m pip install -r ${DIR}/requirements.txt
|
||||||
|
|
||||||
|
|
||||||
# NuttX toolchain (arm-none-eabi-gcc)
|
# NuttX toolchain (arm-none-eabi-gcc)
|
||||||
if [[ $INSTALL_NUTTX == "true" ]]; then
|
if [[ $INSTALL_NUTTX == "true" ]]; then
|
||||||
|
|
||||||
|
echo
|
||||||
echo "Installing NuttX dependencies"
|
echo "Installing NuttX dependencies"
|
||||||
|
|
||||||
sudo apt-get -yy --quiet --no-install-recommends install \
|
sudo apt-get -yy --quiet --no-install-recommends install \
|
||||||
|
@ -145,6 +142,7 @@ fi
|
||||||
# Simulation tools
|
# Simulation tools
|
||||||
if [[ $INSTALL_SIM == "true" ]]; then
|
if [[ $INSTALL_SIM == "true" ]]; then
|
||||||
|
|
||||||
|
echo
|
||||||
echo "Installing PX4 simulation dependencies"
|
echo "Installing PX4 simulation dependencies"
|
||||||
|
|
||||||
# java (jmavsim or fastrtps)
|
# java (jmavsim or fastrtps)
|
||||||
|
@ -156,6 +154,7 @@ if [[ $INSTALL_SIM == "true" ]]; then
|
||||||
|
|
||||||
# Gazebo
|
# Gazebo
|
||||||
sudo sh -c 'echo "deb http://packages.osrfoundation.org/gazebo/ubuntu-stable `lsb_release -cs` main" > /etc/apt/sources.list.d/gazebo-stable.list'
|
sudo sh -c 'echo "deb http://packages.osrfoundation.org/gazebo/ubuntu-stable `lsb_release -cs` main" > /etc/apt/sources.list.d/gazebo-stable.list'
|
||||||
|
wget http://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add -
|
||||||
sudo apt-get update -yy --quiet
|
sudo apt-get update -yy --quiet
|
||||||
sudo apt-get -yy --quiet --no-install-recommends install gazebo9
|
sudo apt-get -yy --quiet --no-install-recommends install gazebo9
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue