Skip to content
Snippets Groups Projects
Commit 25dfd226 authored by Pietro Incardona's avatar Pietro Incardona
Browse files

Fixing installation of g++ and user input skip

parent 44622177
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@
function possible_solutions {
if [ $sq -eq 0 ]; then
if [ $sq -eq 1 ]; then
return
fi
......@@ -21,6 +21,10 @@ function possible_solutions {
fi
possible_solutions_ret=`expr $choose - 1`
echo "Executing: ${command[$possible_solutions_ret]}"
eval ${commands[$possible_solutions_ret]}
if [ -a input_install ]; then
eval ${commands[$possible_solutions_ret]} < input_install
else
eval ${commands[$possible_solutions_ret]}
fi
}
......@@ -18,11 +18,19 @@ if [ x"$1" = x"osx" ]; then
compiler_gcc="gcc-4.9"
compiler_gpp="g++-4.9"
elif [ x"$1" = x"linux" ]; then
commands[0]="su -c \"$pcman install gcc-c++\""
commands[1]="sudo $pcman install gcc-c++"
possible_solutions "${commands[@]}"
compiler_gcc="gcc"
compiler_gpp="g++"
if [ x"$pcman" == x"yum" ]; then
commands[0]="su -c \"$pcman install gcc-c++\""
commands[1]="sudo $pcman install gcc-c++"
possible_solutions "${commands[@]}"
compiler_gcc="gcc"
compiler_gpp="g++"
else
commands[0]="su -c \"$pcman install g++\""
commands[1]="sudo $pcman install g++"
possible_solutions "${commands[@]}"
compiler_gcc="gcc"
compiler_gpp="g++"
fi
fi
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment