if[[$(echo$response| sed 's/ //g')=~ ^([yY][eE][sS]|[yY])$ ]];then
echo""
return0
else
return1
fi
read -r -p "" response
if[[$(echo$response| sed 's/ //g')=~ ^([yY][eE][sS]|[yY])$ ]];then
echo""
return0
else
return1
fi
}
}
##################################
##################################
INFO_SEP
echo -e "\e[1mINFO:\e[0m About installation\n\nThe installation may take long time because many development dependencies may be \
INFO_SEP
echo -e "\e[1mINFO:\e[0m About installation\n\nThe installation may take long time because many development dependencies may be \
installed and the following packages will be compiled from source(depending on your choise):\n\n\
installed and the following packages will be compiled from source(depending on your choise):\n\n\
\t- Wine/Wine Staging (latest git version)\n\
\t- Wine/Wine Staging (latest git version)\n\
\t- DXVK (latest git version)\n\
\t- DXVK (latest git version)\n\
\t- meson & glslang (latest git versions; these are build time dependencies for DXVK)\n\n\
\t- meson & glslang (latest git versions; these are build time dependencies for DXVK)\n\n\
Do you want to continue? [Y/n]"
Do you want to continue? [Y/n]"
questionresponse
questionresponse
if[[$? -ne 0]];then
echo -e "Cancelling.\n"
exit1
fi
if[[$? -ne 0]];then
echo -e "Cancelling.\n"
exit1
fi
####################
####################
AVAIL_SPACE=$(df -h -B MB --output=avail . | sed '1d; s/[A-Z]*//g')
REC_SPACE=8000
AVAIL_SPACE=$(df -h -B MB --output=avail . | sed '1d; s/[A-Z]*//g')
REC_SPACE=8000
if[[${AVAIL_SPACE} -lt ${REC_SPACE}]];then
INFO_SEP
if[[${AVAIL_SPACE} -lt ${REC_SPACE}]];then
INFO_SEP
echo -e "\e[1mWARNING:\e[0m Not sufficient storage space\n\nYou will possibly run out of space while compiling software.\n\
echo -e "\e[1mWARNING:\e[0m Not sufficient storage space\n\nYou will possibly run out of space while compiling software.\n\
The script strongly recommends ~\e[1m$((${REC_SPACE}/1000)) GB\e[0m at least to compile software successfully but you have only\n\
The script strongly recommends ~\e[1m$((${REC_SPACE}/1000)) GB\e[0m at least to compile software successfully but you have only\n\
\e[1m${AVAIL_SPACE} MB\e[0m left on the filesystem the script is currently placed at.\n\n\
\e[1m${AVAIL_SPACE} MB\e[0m left on the filesystem the script is currently placed at.\n\n\
Be aware that the script process may fail because of this, especially while compiling Wine Staging.\n\n\
Be aware that the script process may fail because of this, especially while compiling Wine Staging.\n\n\
Do you really want to continue? [Y/n]"
Do you really want to continue? [Y/n]"
questionresponse
questionresponse
if[[$? -ne 0]];then
echo -e "Cancelling.\n"
exit1
fi
if[[$? -ne 0]];then
echo -e "Cancelling.\n"
exit1
fi
unset AVAIL_SPACE REC_SPACE
fi
unset AVAIL_SPACE REC_SPACE
fi
####################
####################
INFO_SEP
INFO_SEP
echo -e "\e[1mINFO:\e[0m Update existing dependencies?\n\nIn a case you have old build time dependencies on your system, do you want to update them?\n\
echo -e "\e[1mINFO:\e[0m Update existing dependencies?\n\nIn a case you have old build time dependencies on your system, do you want to update them?\n\
If you answer 'yes', then those dependencies are updated if needed. Otherwise, already installed\n\
If you answer 'yes', then those dependencies are updated if needed. Otherwise, already installed\n\
build time dependencies are not updated. If you don't have 'meson' or 'glslang' installed on your system, they will be compiled, anyway.\n\
build time dependencies are not updated. If you don't have 'meson' or 'glslang' installed on your system, they will be compiled, anyway.\n\
Be aware, that updating these packages may increase total run time used by this script.\n\n\
Be aware, that updating these packages may increase total run time used by this script.\n\n\
Update dependency packages & other system packages? [Y/n]"
Update dependency packages & other system packages? [Y/n]"
# Skip Wine build & installation process all together
# Skip Wine build & installation process all together
NO_WINE=
;;
;;
--no-dxvk)
--no-dxvk)
# Skip DXVK build & installation process all together
# Skip DXVK build & installation process all together
NO_DXVK=
;;
;;
--no-pol)
--no-pol)
# Skip PlayOnLinux Wine prefixes update process
# Skip PlayOnLinux Wine prefixes update process
@ -178,10 +156,10 @@ done
function sudoQuestion(){
function sudoQuestion(){
sudo -k
sudo -k
echo -e "\e[1mINFO:\e[0m sudo password required\n\nThis script requires elevated permissions for package updates & installations. Please provide your sudo password for these script commands. Sudo permissions are not used for any other purposes.\n"
echo -e "\e[1mINFO:\e[0m sudo password required\n\nThis script requires elevated permissions for package updates & installations. Please provide your sudo password for these script commands. Sudo permissions are not used for any other purposes.\n"
sudo echo"" > /dev/null
sudo -v
if[[$? -ne 0]];then
if[[$? -ne 0]];then
echo"Invalid sudo password.\n"
echo-e "Invalid sudo password.\n"
exit1
exit1
fi
fi
@ -249,7 +227,11 @@ function determineDistroFamily() {