solve_cmake 578 Bytes
Newer Older
incardon's avatar
incardon committed
1 2

#! /bin/bash 
3 4

function solve_cmake() {        
incardon's avatar
incardon committed
5 6 7 8 9 10 11 12 13 14 15 16 17
source script/show_solutions
source script/discover_package_manager
discover_package_manager $1
pcman=$discover_package_manager_ret

if [ x"$pcman" = x"" ]; then
        exit 1
fi

if [ x"$1" = x"osx" ]; then 
        commands[0]="$pcman install cmake"
        possible_solutions "${commands[@]}"
elif [ x"$1" = x"linux"  ]; then
incardon's avatar
incardon committed
18
	pc_install_command "$pcman"
19 20
        commands[0]="su -c \"$pc_install_command_ret cmake\""
        commands[1]="sudo $pc_install_command_ret cmake"
incardon's avatar
incardon committed
21 22
        possible_solutions "${commands[@]}"
fi 
23
}
incardon's avatar
incardon committed
24