#!/usr/bin/env bash if [ -z "$1" ] then printf "Usage: setup.sh install_directory [dependencies].\n" 1>&2 exit 1 fi cd $(dirname $0) libname=$(basename $(pwd)) mkdir -p build cd build cmake ../ -Wno-dev -DBUILD_TESTING=0 -DCMAKE_INSTALL_PREFIX="$1" make -j8 make install -k # Moving directories mv "$1/include/vtk-5.0" "$1/temp" rmdir "$1/include" mv "$1/temp" "$1/include"