Commit 0ad7f2c5 authored by Joseph Mirabel's avatar Joseph Mirabel Committed by Joseph Mirabel
Browse files

Add a script to autonomously check if installation is straightforward.

parent fcfecc85
if [ -z ${DEVEL_DIR} ]; then
export DEVEL_DIR=/local/devel/hpp
# Add ros repositories
sudo sh -c 'echo "deb $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
sudo apt-key adv --keyserver hkp:// --recv-key 0xB01FA116
sudo sh -c 'echo "deb trusty universe" > /etc/apt/sources.list.d/trusty-universe.list'
sudo apt-get update && sudo apt-get --assume-yes upgrade
# Install dependencies
# FIXME: I do not know why this is not in the installed Ubuntu. Is wget missing in Ubuntu 14.04
# or is it deboostrap that is not installing the good version ?
sudo apt-get --assume-yes install wget
# This is required by OpenSceneGraph and is usually installed with Ubuntu 14.04 and graphic card
# drivers.
sudo apt-get --assume-yes install doxygen freeglut3-dev
# From here, it is a standard HPP installation
sudo apt-get --assume-yes install autoconf g++ cmake libboost-dev liburdfdom-dev libassimp-dev ros-indigo-xacro ros-indigo-kdl-parser ros-indigo-common-msgs ros-indigo-tf ros-indigo-tf-conversions ros-indigo-libccd ros-indigo-octomap ros-indigo-resource-retriever ros-indigo-srdfdom ros-indigo-pr2-robot flex bison asciidoc source-highlight git libomniorb4-dev omniorb-nameserver omniidl omniidl-python libltdl-dev python-matplotlib libtinyxml2-dev
sudo apt-get --assume-yes build-dep openscenegraph
# Setup environment
mkdir --parents $DEVEL_DIR
mkdir --parents $DEVEL_DIR/src
mkdir --parents $DEVEL_DIR/install
# Get config script
wget -O $DEVEL_DIR/${BRANCH}/doc/
wget -O $DEVEL_DIR/src/Makefile${BRANCH}/doc/Makefile
source $DEVEL_DIR/
cd $DEVEL_DIR/src
make robot_state_chain_publisher.install
source ../
make all
# read arguments
if [ $# -ne 1 ] && [ $# -ne 2 ]; then
echo "usage: $0 <install-directory> <bash_script_to_launch>"
exit 1
if [ $# -eq 2 ]; then
HERE="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
if [ -f ${SCRIPT} -a -r ${SCRIPT} ]; then
echo "Will run '/bin/bash ${SCRIPT}' in the fresh install."
echo "${SCRIPT} not found"
exit 1
RUN=`basename "${SCRIPT}"`
# install ubuntu
debootstrap trusty "$DST"
# put the installation script in the fresh install
cp "${SCRIPT}" "$DST/root/$RUN"
chroot "${DST}" /bin/bash "/root/$RUN"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment