1 添加ROS软件源
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
2 添加密钥
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
3 安装ROS
sudo apt-get update
sudo apt-get install ros-kinetic-desktop-full
4 初始化ROS dep
sudo rosdep init
rosdep update
5 设置环境变量
echo "source /opt/ros/kinetic/setup.bash" >> ~/.bashrc
source ~/.bashrc
6 安装rosinstall(可选)
sudo apt install python-rosinstall python-rosinstall-generator python-wstool build-essential
来源:oschina
链接:https://my.oschina.net/u/4228078/blog/3138824