Commit 9278a8d0 authored by Mikhail Tergoev's avatar Mikhail Tergoev

###Scripts version 2022###

parent ad6fd6d8
......@@ -7,6 +7,12 @@
* добавить комментарии описывающие функционал скриптов и db файлов
* заниматься только развитием проекта за счет вашей подписки на https://boosty.to/portwine-linux.ru
-----------------------------------------
###Scripts version 2022###
* добавлен фикc для работы EVE Online
* добавлен в GUI вывод версий WINE используемых по умолчанию
* в функцию "GET OTHER WINE" добавлена вкладка с версиями WINE от PortWINE-Linux.ru (тест)
* исправлено завершение тихого режима установки
###Scripts version 2021###
* HOTFIX - создание каталогов mono и gecko при первом запуске
* Добавлена поддержка работы PortProton под ROSA FRESH R12 (необходимые зависимости опубликованы на сайте)
......
......@@ -89,6 +89,10 @@ try_force_link_dir () {
return 1
}
check_process () {
[ ! -n "`ps cax | grep "$1" | awk '{print $1}'`" ] && return 0 || return 1
}
try_download () {
set -o pipefail
wget -c -t 5 -T 3 "$1" --output-document="$2" 2>&1 | \
......@@ -97,6 +101,14 @@ try_download () {
[ "${PIPESTATUS[0]}" != 0 ] && print_error "failed to download $1. Scipping." && return 1 || return 0
}
try_download_to_path () {
set -o pipefail
wget -c -t 5 -T 3 "$1" --directory-prefix="$2" 2>&1 | \
tr '\r' '\n' | sed -u 's/.* \([0-9]\+%\)\ \+\([0-9,.]\+.\) \(.*\)/\1\n#Downloading at \1\/, \2\/s, ETA \3/; s/^20[0-9][0-9].*/#Done./' | \
zenity --progress --percentage=0 --title="Download $(basename $1)" --text=Starting... --auto-close --auto-kill --width=500 --height=90
[ "${PIPESTATUS[0]}" != 0 ] && print_error "failed to download $1. Scipping." && return 1 || return 0
}
try_download_silent () {
wget -t 2 -T 10 "$1" --output-document="$2"
[ "$?" != 0 ] && print_error "failed to download $1. Scipping." && return 1 || return 0
......@@ -272,8 +284,14 @@ init_wine_ver () {
done
fi
if [[ ! -d "${WINEDIR}/lib64/" && -d "${WINEDIR}/lib/wine/x86_64-unix" ]] ; then
create_new_dir "${WINEDIR}/lib64/wine"
mv -f "${WINEDIR}/lib/wine/x86_64-unix" "${WINEDIR}/lib64/wine/"
mv -f "${WINEDIR}/lib/wine/x86_64-windows" "${WINEDIR}/lib64/wine/"
fi
for copy_proton_dll in "dxvk" "vkd3d-proton" ; do
if [ ! -d "${WINEDIR}/lib/wine/${copy_proton_dll}/" ] ; then
if [[ ! -d "${WINEDIR}/lib/wine/${copy_proton_dll}/" || ! -d "${WINEDIR}/lib64/wine/${copy_proton_dll}/" ]] ; then
try_copy_dir "${PORT_WINE_PATH}/data/dist/PROTON_STEAM/lib/wine/${copy_proton_dll}" "${WINEDIR}/lib/wine/"
try_copy_dir "${PORT_WINE_PATH}/data/dist/PROTON_STEAM/lib64/wine/${copy_proton_dll}" "${WINEDIR}/lib64/wine/"
fi
......@@ -303,19 +321,19 @@ sszen() {
pw_start_progress_bar_cs () {
"${pw_yad}" --progress --progress-text="$@" --pulsate --close-on-unfocus \
--no-buttons --undecorated --center --skip-taskbar --width=500 --wrap-width=500 &
--no-buttons --undecorated --center --skip-taskbar --width=500 --wrap-width=500 > /dev/null 2>&1 &
echo ""
}
pw_start_progress_bar_block () {
"${pw_yad}" --progress --progress-text="$@" --pulsate \
--no-buttons --undecorated --center --skip-taskbar --width=500 --wrap-width=500 &
--no-buttons --undecorated --center --skip-taskbar --width=500 --wrap-width=500 > /dev/null 2>&1 &
echo ""
}
pw_stop_progress_bar () {
while [ ! -z "`pgrep -a yad | grep "\-\-progress" | awk '{print $1}'`" ]
do kill -n 9 `pgrep -a yad | grep "\-\-progress" | awk '{print $1}' | head -n 1` &> /dev/null
do kill -n 9 `pgrep -a yad | grep "\-\-progress" | awk '{print $1}' | head -n 1` > /dev/null 2>&1
done
}
......@@ -749,42 +767,77 @@ pw_check_and_download_wine () {
}
gui_proton_downloader () {
set -o pipefail
export PORT_WINE_TMP_PATH="${HOME}"
pw_start_progress_bar_block "Check new version WINE from GitHub"
#PROTON_GE
export PROTON_GE_GIT=($(curl -s "https://api.github.com/repos/GloriousEggroll/proton-ge-custom/releases" | grep "browser_download_url.*\.tar\.gz" | cut -d \" -f 4))
[ "${PIPESTATUS[0]}" != 0 ] && exit 1
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
for PGEGIT in ${PROTON_GE_GIT[@]} ; do
echo ${PGEGIT} | awk -F/ '{print $NF}' | sed 's/.tar.gz//' >> "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
done
sed -i '/Proton-6.5-GE-2/,$d' "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
sed -i '/github-action/d' "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
for INSTALLING_VERSION_IN_DIST in `ls "${PORT_WINE_PATH}/data/dist/"` ; do
sed -i "/${INSTALLING_VERSION_IN_DIST}/Id" "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
#PROTON_PW
export PROTON_PW_GIT=($(curl -s "https://api.github.com/repos/Castro-Fidel/wine_builds/releases" | grep "browser_download_url.*\.tar\.xz" | cut -d \" -f 4))
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_proton_pw_git"
for PPWGIT in ${PROTON_PW_GIT[@]} ; do
echo $PPWGIT
echo ${PPWGIT} | awk -F/ '{print $NF}' | sed 's/.tar.xz//' >> "${PORT_WINE_TMP_PATH}/tmp_proton_pw_git"
done
for INSTALLING_VERSION_IN_DIST in `ls "${PORT_WINE_PATH}/data/dist/"` ; do
sed -i "/${INSTALLING_VERSION_IN_DIST}/Id" "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
sed -i "/${INSTALLING_VERSION_IN_DIST}/Id" "${PORT_WINE_TMP_PATH}/tmp_proton_pw_git"
done
VERSION_PROTON_GIT=`"${pw_yad_new}" --list --cheklist --separator="" --listen --width=400 --height=600 --center --borders=15 \
--column "Select WINE for download:" --title "Download..." < "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"`
if [ "${PIPESTATUS[0]}" != 0 ]; then
pw_stop_progress_bar
#GUI
export KEY_WINE=$RANDOM
"${pw_yad}" --plug=$KEY_WINE --tabnum=2 --list --cheklist --separator="" --listen \
--column "Select WINE for download:" < "${PORT_WINE_TMP_PATH}/tmp_proton_pw_git" &> "${PORT_WINE_TMP_PATH}/tmp_proton_pw_set" &
"${pw_yad}" --plug=$KEY_WINE --tabnum=1 --list --cheklist --separator="" --listen \
--column "Select WINE for download:" < "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git" &> "${PORT_WINE_TMP_PATH}/tmp_proton_set" &
`yad --key=$KEY_WINE --notebook --width=500 --height=600 --text-align=center --center \
--window-icon="$PW_GUI_ICON_PATH/port_proton.png" --title "Download..." --separator="" \
--tab-pos=top --tab="PROTON-GE" --tab="PROTON-PW"`
YAD_WINE_STATUS="$?"
if [[ "$YAD_WINE_STATUS" == "1" || "$YAD_WINE_STATUS" == "252" ]] ; then
/bin/bash -c ${pw_full_command_line[*]} &
exit 0
fi
if [ ! -z `cat "${PORT_WINE_TMP_PATH}/tmp_proton_set"` ] ; then
export VERSION_WINE_GIT=`cat "${PORT_WINE_TMP_PATH}/tmp_proton_set"`
elif [ ! -z `cat "${PORT_WINE_TMP_PATH}/tmp_proton_pw_set"` ] ; then
export VERSION_WINE_GIT=`cat "${PORT_WINE_TMP_PATH}/tmp_proton_pw_set"`
fi
echo "$VERSION_WINE_GIT"
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_proton_ge_git"
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_proton_pw_git"
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_proton_set"
for PGEGIT2 in ${PROTON_GE_GIT[@]} ; do
if [ ! -z `echo ${PGEGIT2} | grep "$VERSION_PROTON_GIT"` ] ; then
export URL_VERSION_PROTON_GIT="${PGEGIT2}"
for GIVE_WINE_URL in ${PROTON_GE_GIT[@]} ${PROTON_PW_GIT[@]} ; do
if [ ! -z `echo ${GIVE_WINE_URL} | grep "$VERSION_WINE_GIT"` ] ; then
export URL_VERSION_PROTON_GIT="${GIVE_WINE_URL}"
fi
done
print_info "Download and install ${VERSION_PROTON_GIT}..."
if try_download "${URL_VERSION_PROTON_GIT}" "${PORT_WINE_PATH}/data/tmp/${VERSION_PROTON_GIT}.tar.gz" ; then
if unpack_tar_gz "${PORT_WINE_PATH}/data/tmp/${VERSION_PROTON_GIT}.tar.gz" "${PORT_WINE_PATH}/data/dist/" ; then
try_remove_file "${PORT_WINE_PATH}/data/tmp/${VERSION_PROTON_GIT}.tar.gz"
else
try_remove_file "${PORT_WINE_PATH}/data/tmp/${VERSION_PROTON_GIT}.tar.gz"
try_remove_dir "${PORT_WINE_PATH}/data/dist/${VERSION_PROTON_GIT}"
zenity_error_download && gui_proton_downloader
fi
print_info "Download and install ${VERSION_WINE_GIT}..."
if try_download_to_path "${URL_VERSION_PROTON_GIT}" "${PORT_WINE_PATH}/data/tmp/" ; then
for archive_type in "gz" "xz" ; do
if [ -f "${PORT_WINE_PATH}/data/tmp/${VERSION_WINE_GIT}.tar.${archive_type}" ] ; then
if unpack_tar_${archive_type} "${PORT_WINE_PATH}/data/tmp/${VERSION_WINE_GIT}.tar.${archive_type}" "${PORT_WINE_PATH}/data/dist/" ; then
try_remove_file "${PORT_WINE_PATH}/data/tmp/${VERSION_WINE_GIT}.tar.${archive_type}"
else
try_remove_file "${PORT_WINE_PATH}/data/tmp/${VERSION_WINE_GIT}.tar.${archive_type}"
try_remove_dir "${PORT_WINE_PATH}/data/dist/${VERSION_WINE_GIT}"
zenity_error_download && gui_proton_downloader
fi
fi
done
else
zenity_error_download && gui_proton_downloader
fi
......
......@@ -13,6 +13,8 @@ export WINEDLLOVERRIDES="concrt140,msvcp140,msvcp140_1,msvcp140_2,d3dcompiler_47
##export PW_FORCE_USE_VSYNC=2 # Vsync: 0-FORCE_OFF, 1-FORCE_ON, 2-BY_DEFAULT
##export ENABLE_VKBASALT=1
export PW_VKBASALT_EFFECTS="cas:FilmGrain2"
export PW_VKBASALT_FFX_CAS="0.5"
##export PW_NO_FSYNC=1 # Do not use futex-based in-process synchronization primitives. (Automatically disabled on systems with no FUTEX_WAIT_MULTIPLE support.
##export PW_NO_ESYNC=1 # Do not use eventfd-based in-process synchronization primitives
......@@ -32,4 +34,20 @@ export WINEDLLOVERRIDES="concrt140,msvcp140,msvcp140_1,msvcp140_2,d3dcompiler_47
##export PW_LOG=0 # Enable debug mode fo terminal
##export PW_GUI_DISABLED_CS=1 # 1 = disabled GUI
##add_in_start_portwine () { commands ; }
eve_fix () {
export EVE_SHADER_CASH="$WINEPREFIX/drive_c/Games/EVE Online/SharedCache"
if [[ ! -f "$EVE_SHADER_CASH/tq/bin64/launchdarkly_client.pyd" ]] ; then
sleep 30
while check_process evelauncher.exe && [[ ! -f "$EVE_SHADER_CASH/tq/bin64/launchdarkly_client.pyd" ]]
do sleep 1
done
fi
sleep 2
try_remove_file "$EVE_SHADER_CASH/tq/launchdarkly_client.pyd"
try_copy_file "$EVE_SHADER_CASH/tq/bin64/launchdarkly_client.pyd" "$EVE_SHADER_CASH/tq/"
chmod 444 "$EVE_SHADER_CASH/tq/launchdarkly_client.pyd"
}
add_in_start_portwine () {
eve_fix &
}
......@@ -31,7 +31,7 @@ echo "Icon="${PORT_WINE_PATH}/data/img/readme.png"" >> "${PORT_WINE_PATH}/${name
echo "URL=${urlg}" >> "${PORT_WINE_PATH}/${name_desktop}.desktop"
chmod u+x "${PORT_WINE_PATH}/${name_desktop}.desktop"
if [ "${s_install}" = "1" ]; then
if [ "${silent_install}" = "1" ]; then
echo "Installation completed successfully."
else
`zenity --info --title "${inst_set_top}" --text "${inst_succ}" --no-wrap ` > /dev/null 2>&1
......
......@@ -202,7 +202,7 @@ pw_winetricks () {
pw_edit_db () {
pw_gui_for_edit_db ENABLE_VKBASALT PW_NO_ESYNC PW_NO_FSYNC PW_DXR_ON PW_VULKAN_NO_ASYNC PW_USE_NVAPI_AND_DLSS \
PW_OLD_GL_STRING PW_HIDE_NVIDIA_GPU PW_FORCE_USE_VSYNC PW_VIRTUAL_DESKTOP PW_WINEDBG_DISABLE PW_USE_TERMINAL \
PW_WINE_ALLOW_XIM PW_HEAP_DELAY_FREE PW_NO_WRITE_WATCH PW_GUI_DISABLED_CS PW_USE_GSTREAMER
PW_WINE_ALLOW_XIM PW_HEAP_DELAY_FREE PW_NO_WRITE_WATCH PW_GUI_DISABLED_CS PW_USE_GSTREAMER PW_USE_RUNTIME
if [ "$?" == 0 ] ; then
/bin/bash -c ${pw_full_command_line[*]} &
exit 0
......@@ -250,15 +250,15 @@ if [ ! -z "${PORTWINE_DB_FILE}" ] ; then
*) export PW_DEFAULT_VULKAN_USE='DXVK (DX 9-11 to Vulkan)\!VKD3D (DX 12 to Vulkan)\!OPENGL ' ;;
esac
case "${PW_WINE_USE}" in
"PROTON_GE") export PW_DEFAULT_WINE_USE="PROTON_GE\!PROTON_STEAM${DIST_ADD_TO_GUI}" ;;
"PROTON_STEAM") export PW_DEFAULT_WINE_USE="PROTON_STEAM\!PROTON_GE${DIST_ADD_TO_GUI}" ;;
"PROTON_GE") export PW_DEFAULT_WINE_USE="PROTON_GE (${PW_GE_VER})\!PROTON_STEAM (${PW_STEAM_VER})${DIST_ADD_TO_GUI}" ;;
"PROTON_STEAM") export PW_DEFAULT_WINE_USE="PROTON_STEAM (${PW_STEAM_VER})\!PROTON_GE (${PW_GE_VER})${DIST_ADD_TO_GUI}" ;;
*)
export DIST_ADD_TO_GUI=`echo ${DIST_ADD_TO_GUI} | sed -e s/"\!${PW_WINE_USE}$//g"`
export PW_DEFAULT_WINE_USE="${PW_WINE_USE}\!PROTON_STEAM\!PROTON_GE${DIST_ADD_TO_GUI}" ;;
export PW_DEFAULT_WINE_USE="${PW_WINE_USE}\!PROTON_STEAM (${PW_STEAM_VER})\!PROTON_GE (${PW_GE_VER})${DIST_ADD_TO_GUI}" ;;
esac
else
export PW_DEFAULT_VULKAN_USE='DXVK (DX 9-11 to Vulkan)\!VKD3D (DX 12 to Vulkan)\!OPENGL '
export PW_DEFAULT_WINE_USE="PROTON_STEAM\!PROTON_GE${DIST_ADD_TO_GUI}"
export PW_DEFAULT_WINE_USE="PROTON_STEAM (${PW_STEAM_VER})\!PROTON_GE (${PW_GE_VER})${DIST_ADD_TO_GUI}"
unset PW_GUI_DISABLED_CS
fi
if [ ! -z "${portwine_exe}" ]; then
......@@ -330,7 +330,7 @@ else
--field="CLEAR PREFIX":"BTN" '@bash -c "button_click gui_clear_pfx"' \
--field="EDIT SCRIPT VAR":"BTN" '@bash -c "button_click gui_open_var"' \
--field="WINE UNINSTALLER":"BTN" '@bash -c "button_click gui_wine_uninstaller"' \
--field="REMOVE PORTPROTON":"BTN" '@bash -c "button_click gui_rm_portproton"' & \
--field="REMOVE PORTPROTON":"BTN" '@bash -c "button_click gui_rm_portproton"' &
"${pw_yad}" --plug=$KEY --tabnum=2 --form --columns=3 --scroll --height=500 \
--field=" Wargaming Game Center"!"$PW_GUI_ICON_PATH/wgc.png":"BTN" '@bash -c "button_click PW_WGC"' \
......@@ -348,7 +348,7 @@ else
--field=" Glyph Client"!"$PW_GUI_ICON_PATH/glyph.png":"BTN" '@bash -c "button_click PW_GLYPH"' \
--field=" Ankama Launcher"!"$PW_GUI_ICON_PATH/ankama.png":"BTN" '@bash -c "button_click PW_ANKAMA"' \
--field=" League of Legends"!"$PW_GUI_ICON_PATH/lol.png":"BTN" '@bash -c "button_click PW_LOL"' \
--field=" Gameforge Client"!"$PW_GUI_ICON_PATH/gameforge.png":"BTN" '@bash -c "button_click PW_GAMEFORGE"' & \
--field=" Gameforge Client"!"$PW_GUI_ICON_PATH/gameforge.png":"BTN" '@bash -c "button_click PW_GAMEFORGE"' &
"${pw_yad}" --plug=${KEY} --tabnum=1 --columns=3 --form --separator=";" \
--image "$PW_GUI_ICON_PATH/port_proton.png" \
......@@ -356,14 +356,14 @@ else
--field=":LBL" "" \
--field='DEBUG'!!"${loc_debug}":"BTN" '@bash -c "button_click DEBUG"' \
--field='WINECFG'!!"${loc_winecfg}":"BTN" '@bash -c "button_click WINECFG"' \
--field=":CB" "PROTON_STEAM\!PROTON_GE${DIST_ADD_TO_GUI}" \
--field=":CB" "PROTON_STEAM (${PW_STEAM_VER})\!PROTON_GE (${PW_GE_VER})${DIST_ADD_TO_GUI}" \
--field=":LBL" "" \
--field='WINEFILE'!!"${loc_winefile}":"BTN" '@bash -c "button_click WINEFILE"' \
--field='WINECMD'!!"${loc_winecmd}":"BTN" '@bash -c "button_click WINECMD"' \
--field="GET OTHER WINE"!!"":"FBTN" '@bash -c "button_click gui_proton_downloader"' \
--field=":LBL" "" \
--field='WINEREG'!!"${loc_winereg}":"BTN" '@bash -c "button_click WINEREG"' \
--field='WINETRICKS'!!"${loc_winetricks}":"BTN" '@bash -c "button_click WINETRICKS"' &> "${PORT_WINE_TMP_PATH}/tmp_yad_form_vulkan" & \
--field='WINETRICKS'!!"${loc_winetricks}":"BTN" '@bash -c "button_click WINETRICKS"' &> "${PORT_WINE_TMP_PATH}/tmp_yad_form_vulkan" &
"${pw_yad}" --key=$KEY --notebook --borders=10 --width=1000 --height=168 --no-buttons --text-align=center \
--window-icon="$PW_GUI_ICON_PATH/port_proton.png" --title "${portname}-${install_ver} (${scripts_install_ver})" --separator=";" \
......
#!/bin/bash
#Author: Castro-Fidel (PortWINE-Linux.ru)
#SCRIPTS_NEXT_VERSION=2021
#SCRIPTS_NEXT_VERSION=2022
#PORT_NEXT_VERSION=97
########################################################################
export PW_MANGOHUD=1
......@@ -29,14 +29,18 @@ export PW_LIBS_VER="_v18"
export PORTWINE_URL="http://portwine-linux.ru/"
export GDK_BACKEND="x11"
export PW_USE_GSTREAMER="1"
export PW_PROTON_STEAM_VER="PROTON_STEAM_6.3-7"
export WINEPREFIX="${PORT_WINE_PATH}/data/pfx"
export WINE_WIN_START="start.exe /i /unix"
###WINE_PROTON_STEAM###
export PW_STEAM_VER="6.3-7"
export PW_PROTON_STEAM_VER="PROTON_STEAM_${PW_STEAM_VER}"
export PW_MONO_VER="6.3.0"
export PW_GECKO_VER="2.47.2"
export PW_PROTON_GE_VER="PROTON_GE_6.19-2"
###WINE_PROTON_GE###
export PW_GE_VER="6.19-2"
export PW_PROTON_GE_VER="PROTON_GE_${PW_GE_VER}"
export PW_MONO_GE_VER="6.4.0"
export PW_GECKO_GE_VER="2.47.2"
export WINEPREFIX="${PORT_WINE_PATH}/data/pfx"
export WINE_WIN_START="start.exe /i /unix"
export WINE_FULLSCREEN_FSR="1"
export WINE_FULLSCREEN_FSR_STRENGTH="2"
#################################################################
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment