#!/usr/bin/env bash # Copyright (c) 2018, University of Kaiserslautern # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # 1. Redistributions of source code must retain the above copyright notice, # this list of conditions and the following disclaimer. # # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # 3. Neither the name of the copyright holder nor the names of its # contributors may be used to endorse or promote products derived from # this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER # OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR # PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF # LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING # NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # # Author: Éder F. Zulian # Check distro. This script supports Debian/Ubuntu distro=`lsb_release -a | grep "Distributor ID:" | awk {'print $3'}` if [ "$distro" != "Debian" ] && [ "$distro" != "Ubuntu" ]; then echo -e "Error unsupported distribution (${distro}). This script supports Debian/Ubuntu." 1>&2 exit 1 fi # Ensure the newest versions of all packages currently installed sudo apt-get update sudo apt-get upgrade # Required dependencies deplist=" gitk synaptic subversion locate qt4-qmake libqt4-dev python3.5 python3.5-dev libc6 libstdc++6 sqlite3 libsqlite3-dev libqt5gui5 libqt5sql5 libqt5widgets5 libqt5core5a qtcreator qt5-default astyle uncrustify clang-format qttools5-dev libqt4-svg libqt5svg5 libqt5svg5-dev " for d in $deplist; do sudo apt-get -y install $d done echo -e "Done."