From 97f0c1e215dc5b1b2258dbf9413c8a3e19923539 Mon Sep 17 00:00:00 2001 From: Castro-Fidel Date: Fri, 29 Nov 2019 23:02:35 +0300 Subject: [PATCH] Update debug and vars scripts --- portwine_run_scripts/debug | 21 +- portwine_run_scripts/lang | 2 +- portwine_run_scripts/port_update | 12 +- portwine_run_scripts/remove | 3 +- portwine_run_scripts/runlib | 6 +- portwine_run_scripts/setup | 23 +-- portwine_run_scripts/start | 3 +- portwine_run_scripts/start_settings | 20 +- portwine_run_scripts/stop | 2 +- portwine_run_scripts/vars | 27 ++- portwine_run_scripts/wineboot | 2 +- portwine_run_scripts/winecfg | 2 +- portwine_run_scripts/winecmd | 2 +- portwine_run_scripts/winefile | 2 +- portwine_run_scripts/winereg | 2 +- portwine_run_scripts/winetricks | 245 ++++++++---------------- portwine_run_scripts/winetricks-q-force | 2 +- 17 files changed, 143 insertions(+), 233 deletions(-) diff --git a/portwine_run_scripts/debug b/portwine_run_scripts/debug index d258a0d6..0c9774d3 100755 --- a/portwine_run_scripts/debug +++ b/portwine_run_scripts/debug @@ -1,5 +1,18 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru +. "$(dirname $(readlink -f "$0"))/runlib" + +if [ -e "${config_path}/dxvk" ] +then + START_PORTWINE + WINE_DX_TO_VULKAN + VULKAN_SET +else + START_PORTWINE + WINE_DX_TO_OPENGL + OPENGL_SET +fi + echo "${port_deb1}" > "${PORT_WINE_PATH}/${portname}.log" echo "${port_deb2}" >> "${PORT_WINE_PATH}/${portname}.log" echo "--------------------------------------------" >> "${PORT_WINE_PATH}/${portname}.log" @@ -43,9 +56,11 @@ echo "Version WINE in the Port" >> "${PORT_WINE_PATH}/${portname}.log" echo "--------------------------------------------" >> "${PORT_WINE_PATH}/${portname}.log" echo "log WINE" >> "${PORT_WINE_PATH}/${portname}.log" -export WINEDEBUG="fixme-all,+vulkan,-trace" +export WINEDEBUG="warn+all" export VK_LOADER_DEBUG=-all -export DXVK_LOG_LEVEL=debug +export DXVK_LOG_LEVEL="info" +export VKD3D_DEBUG="warn" +export DXVK_HUD="fps,devinfo" "${optirun_on}" "${WINELOADER}" "${gamestart}" "${launch_parameters}" 2>> "${PORT_WINE_PATH}/${portname}.log" diff --git a/portwine_run_scripts/lang b/portwine_run_scripts/lang index c180abdb..acb5fcce 100755 --- a/portwine_run_scripts/lang +++ b/portwine_run_scripts/lang @@ -1,5 +1,5 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru read "update_loc" < "${config_path}/${portname}_loc" export update_loc=${update_loc} diff --git a/portwine_run_scripts/port_update b/portwine_run_scripts/port_update index 8cb66ed3..872dadf0 100755 --- a/portwine_run_scripts/port_update +++ b/portwine_run_scripts/port_update @@ -1,5 +1,6 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru + if [ ! -f "${config_path}/${portname}_ver" ] then echo "10" > "${config_path}/${portname}_ver" @@ -61,11 +62,6 @@ else else case $xsd2 in "${port_time4}") - if [ "${update_loc}" = "ENG" ] - then - urlg="https://www.patreon.com/portwinelinux" - fi - if [ ! -z "$(command -v sensible-browser)" ]; then sensible-browser "$urlg" & elif [ ! -z "$(command -v xdg-open)" ]; then @@ -75,12 +71,12 @@ else elif [ ! -z "$(command -v python)" ]; then python -m webbrowser "$urlg" fi & - echo "90" > "${HOME}/.config/.PortTime" + echo "150" > "${HOME}/.config/.PortTime" sleep 5 ;; "${port_time5}") echo "30" > "${HOME}/.config/.PortTime" ;; "${port_time6}") - echo "60" > "${HOME}/.config/.PortTime" ;; + echo "80" > "${HOME}/.config/.PortTime" ;; esac fi fi diff --git a/portwine_run_scripts/remove b/portwine_run_scripts/remove index d38378b7..5338dd67 100755 --- a/portwine_run_scripts/remove +++ b/portwine_run_scripts/remove @@ -1,5 +1,6 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru + . "$(dirname $(readlink -f "$0"))/runlib" xsd=`zenity --title "${port_del1}" --text "${port_del2}" \ diff --git a/portwine_run_scripts/runlib b/portwine_run_scripts/runlib index fcd16fa7..bd8931ce 100644 --- a/portwine_run_scripts/runlib +++ b/portwine_run_scripts/runlib @@ -1,5 +1,5 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru [ $(id -u) -eq 0 ] && echo "Do not run the script from the superuser!" && zenity --error --text "Do not run the script from the superuser!" && exit 1 @@ -63,7 +63,7 @@ then export WINEDLLPATH="${PORT_WINE_PATH}"/data/wine/lib/wine if [ "$runtime_libs" -eq "1" ] then - export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/runtime-lib:"${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} + export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/runtime-lib_i386:"${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} else export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} fi @@ -73,7 +73,7 @@ else export WINEDLLPATH="${PORT_WINE_PATH}"/data/wine/lib64/wine if [ "$runtime_libs" -eq "1" ] then - export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/runtime-lib_64:"${PORT_WINE_PATH}"/data/wine/runtime-lib:"${PORT_WINE_PATH}"/data/wine/lib64:"${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} + export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/runtime-lib_x86_64:"${PORT_WINE_PATH}"/data/wine/runtime-lib_i386:"${PORT_WINE_PATH}"/data/wine/lib64:"${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} else export LD_LIBRARY_PATH="${PORT_WINE_PATH}"/data/wine/lib64:"${PORT_WINE_PATH}"/data/wine/lib:${LD_LIBRARY_PATH} fi diff --git a/portwine_run_scripts/setup b/portwine_run_scripts/setup index 26cd62c5..1faaba51 100755 --- a/portwine_run_scripts/setup +++ b/portwine_run_scripts/setup @@ -1,5 +1,6 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru + . "$(dirname $(readlink -f "$0"))/runlib" rm -fR "${PORT_WINE_PATH}/Games" @@ -41,7 +42,7 @@ chmod u+x "${PORT_WINE_PATH}/${name_desktop}.desktop" rm -fR "${PORT_WINE_PATH}/Settings" mkdir -p "${PORT_WINE_PATH}/Settings" -for name_desktop in "winecfg" "winereg" "winefile" "wineboot" "stop" "winecmd" +for name_desktop in "winecfg" "winereg" "winefile" "wineboot" "stop" "winecmd" "start_settings" do echo ""[Desktop Entry]" "Name=${name_desktop}" @@ -77,24 +78,16 @@ echo ""[Desktop Entry]" "Icon="${PORT_WINE_PATH}/data/img/s.png""" > "${PORT_WINE_PATH}/Settings/winetricks.desktop" chmod u+x "${PORT_WINE_PATH}/Settings/winetricks.desktop" -echo ""[Desktop Entry]" -"Name=start_settings" -"Exec="${PORT_WINE_PATH}/data/scripts/start_settings"" -"Type=Application" -"Categories=Game" -"StartupNotify=true" -"Path="${PORT_WINE_PATH}/data/scripts/"" -"Icon="${PORT_WINE_PATH}/data/img/s.png""" > "${PORT_WINE_PATH}/Settings/start_settings.desktop" -chmod u+x "${PORT_WINE_PATH}/Settings/start_settings.desktop" - cp -f "${PORT_WINE_PATH}/data/prefix/reg.xuser/"* "${PORT_WINE_PATH}/data/prefix/" -sed -i "s/crossover/$us_dir/g" "${PORT_WINE_PATH}/data/prefix/"*.reg sed -i "s/xuser/${USER}/g" "${PORT_WINE_PATH}/data/prefix/"*.reg -cp -fR "${PORT_WINE_PATH}/data/prefix/drive_c/users/Public/" "${PORT_WINE_PATH}/data/prefix/drive_c/users/$us_dir/" +if [ ! -d "${PORT_WINE_PATH}/data/prefix/drive_c/users/steamuser/" ] +then + cp -fR "${PORT_WINE_PATH}/data/prefix/drive_c/users/Public/" "${PORT_WINE_PATH}/data/prefix/drive_c/users/$us_dir/" +fi -ln -sf "${PORT_WINE_PATH}/data/prefix/drive_c/" "${PORT_WINE_PATH}/drive_c" +ln -s "${PORT_WINE_PATH}/data/prefix/drive_c/" "${PORT_WINE_PATH}/drive_c" ADD_IN_POST_INSTALL sh "${link}/start_settings" diff --git a/portwine_run_scripts/start b/portwine_run_scripts/start index be335128..f6f6ceea 100755 --- a/portwine_run_scripts/start +++ b/portwine_run_scripts/start @@ -1,4 +1,5 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru + . "$(dirname $(readlink -f "$0"))/runlib" sh "${link}"/start_settings diff --git a/portwine_run_scripts/start_settings b/portwine_run_scripts/start_settings index 4eca93ad..ffbd0c7f 100755 --- a/portwine_run_scripts/start_settings +++ b/portwine_run_scripts/start_settings @@ -1,5 +1,5 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru ######################################################################## sszen() { zenity --progress --title="Settings..." --text="Updating start parameters" --pulsate --auto-close --auto-kill --width=450 @@ -42,10 +42,8 @@ cat > "${link}/start" < +# Copyright (C) 2011 Matthew Bauer # Copyright (C) 2011 Giuseppe Dia # Copyright (C) 2011 Łukasz Wojniłowicz # Copyright (C) 2011 Matthew Bozarth @@ -1581,8 +1581,7 @@ w_steam_install_game() winwaitclose " -if [ "$STEAM_DVD" = "TRUE" ] -then +if [ "$STEAM_DVD" = "TRUE" ]; then w_ahk_do " ; Run a fourth time, have it install the app. run steam.exe -install ${W_ISO_MOUNT_LETTER}:\\ @@ -1626,11 +1625,9 @@ fi } " -if [ "$STEAM_DVD" = "TRUE" ] -then +if [ "$STEAM_DVD" = "TRUE" ]; then # Wait for install to finish - while true - do + while true; do grep "SetHasAllLocalContent(true) called for $_W_steamid" "$W_PROGRAMS_X86_UNIX/Steam/logs/download_log.txt" && break sleep 5 done @@ -1674,8 +1671,7 @@ w_mount() winetricks_mount_cached_iso else if test "$WINETRICKS_OPT_KEEPISOS" = 0 || test "$2"; then - while true - do + while true; do winetricks_mount_real_volume "$1" if test "$2" = "" || test -f "$W_ISO_MOUNT_ROOT/$2"; then break @@ -1860,8 +1856,7 @@ REGEDIT4 [HKEY_CURRENT_USER\\Software\\Wine\\DllOverrides] _EOF_ - while test "$1" != "" - do + while test "$1" != ""; do w_common_override_dll "$_W_mode" "$1" shift done @@ -2283,8 +2278,7 @@ Usage: 'w_override_app_dlls app mode dll ...'." ;; echo "[HKEY_CURRENT_USER\\Software\\Wine\\AppDefaults\\$_W_app\\DllOverrides]" ) > "$W_TMP"/override-dll.reg - while test "$1" != "" - do + while test "$1" != ""; do w_common_override_dll "$_W_mode" "$1" shift done @@ -2549,8 +2543,7 @@ w_compare_wine_version() # val1,val2 (for >= val1 && <= val2) w_wine_version_in() { - for _W_range - do + for _W_range; do _W_val1=$(echo "$_W_range" | sed 's/,.*//') _W_val2=$(echo "$_W_range" | sed 's/.*,//') # If in this range, return true @@ -2639,8 +2632,7 @@ w_metadata() shift # Echo arguments to file, with double quotes around the values. # Used to use Perl here, but that was too slow on Cygwin. - for arg - do + for arg; do # If _W_wine_not_needed is set, we're a list command that isn't list-installed, and can ignore the installed_* errors: case "$arg" in installed_exe1=/*) @@ -2708,8 +2700,7 @@ w_conflicts() verb="$1" conflicting_verbs="$2" - for x in $conflicting_verbs - do + for x in $conflicting_verbs; do if grep -qw "$x" "$WINEPREFIX/winetricks.log" 2>/dev/null; then w_die "error: $verb conflicts with $x, which is already installed. You can run \`$0 --force $verb\` to ignore this check and attempt installation." fi @@ -2789,8 +2780,7 @@ w_do_call() # Don't install if a conflicting verb is already installed: # shellcheck disable=SC2154 if test "$WINETRICKS_FORCE" != 1 && test "$conflicts" && test -f "$WINEPREFIX/winetricks.log"; then - for x in $conflicts - do + for x in $conflicts; do w_conflicts "$1" "$x" done fi @@ -3367,8 +3357,7 @@ winetricks_prefixmenu() > "$WINETRICKS_WORKDIR"/zenity.sh if ls -d "$W_PREFIXES_ROOT"/*/dosdevices > /dev/null 2>&1; then - for prefix in "$W_PREFIXES_ROOT"/*/dosdevices - do + for prefix in "$W_PREFIXES_ROOT"/*/dosdevices; do q="${prefix%%/dosdevices}" p="${q##*/}" if test -f "$W_PREFIXES_ROOT/$p/wrapper.cfg"; then @@ -3405,8 +3394,7 @@ winetricks_prefixmenu() mkprefix '$_W_msg_mkprefix' off \ " if ls -d "$W_PREFIXES_ROOT"/*/dosdevices > /dev/null 2>&1; then - for prefix in "$W_PREFIXES_ROOT"/*/dosdevices - do + for prefix in "$W_PREFIXES_ROOT"/*/dosdevices; do q="${prefix%%/dosdevices}" p="${q##*/}" if test -f "$W_PREFIXES_ROOT/$p/wrapper.cfg"; then @@ -3764,8 +3752,7 @@ winetricks_settings_menu() ;; esac > "$WINETRICKS_WORKDIR"/zenity.sh - for metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars - do + for metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars; do code=$(winetricks_metadata_basename "$metadatafile") ( title='?' @@ -3979,8 +3966,7 @@ winetricks_showmenu() true > "$WINETRICKS_WORKDIR"/installed.txt - for metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars - do + for metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars; do code=$(winetricks_metadata_basename "$metadatafile") ( title='?' @@ -4112,8 +4098,7 @@ winetricks_is_installed() # so let it specify multiple, separated by | _W_IFS="$IFS" IFS='|' - for _W_file_ in $_W_file - do + for _W_file_ in $_W_file; do _W_file_unix="$(WINEPREFIX="$_W_prefix" w_pathconv -u "$_W_file_")" if test -f "$_W_file_unix" && ! grep -q "Wine placeholder DLL" "$_W_file_unix"; then IFS="$_W_IFS" @@ -4132,8 +4117,7 @@ winetricks_is_installed() # List verbs which are already fully cached locally winetricks_list_cached() { - for _W_metadatafile in "$WINETRICKS_METADATA"/*/*.vars - do + for _W_metadatafile in "$WINETRICKS_METADATA"/*/*.vars; do # Use a subshell to avoid putting metadata in global space # If this is too slow, we can unset known metadata by hand ( @@ -4204,8 +4188,7 @@ winetricks_list_all() *) _W_cached="cached" ; _W_download="downloadable" ;; esac - for _W_metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars - do + for _W_metadatafile in "$WINETRICKS_METADATA/$WINETRICKS_CURMENU"/*.vars; do # Use a subshell to avoid putting metadata in global space # If this is too slow, we can unset known metadata by hand ( @@ -4385,8 +4368,7 @@ winetricks_detect_optical_drive() *) return ;; esac - for WINETRICKS_DEV in /dev/cdrom /dev/dvd /dev/sr0 - do + for WINETRICKS_DEV in /dev/cdrom /dev/dvd /dev/sr0; do test -b $WINETRICKS_DEV && break done @@ -4412,12 +4394,10 @@ winetricks_cache_iso() esac fi - while true - do + while true; do # Wait for user to insert disc. # Sleep long to make it less likely to close the drive during insertion. - while ! dd if=$WINETRICKS_DEV of=/dev/null count=1 - do + while ! dd if=$WINETRICKS_DEV of=/dev/null count=1; do sleep 5 done @@ -4467,15 +4447,13 @@ winetricks_cache_iso() # FIXME: add progress bar for kde, too case $WINETRICKS_GUI in none|kdialog) - while ps -p "$WINETRICKS_DD_PID" > /dev/null 2>&1 - do + while ps -p "$WINETRICKS_DD_PID" > /dev/null 2>&1; do sleep 5 ls -l "$W_CACHE"/temp.iso done ;; zenity) - while ps -p "$WINETRICKS_DD_PID" > /dev/null 2>&1 - do + while ps -p "$WINETRICKS_DD_PID" > /dev/null 2>&1; do echo 1 sleep 2 done | $WINETRICKS_GUI --title "Copying to $_W_expected_volname.iso" --progress --pulsate --auto-kill @@ -4536,10 +4514,8 @@ winetricks_mount_cached_iso() w_try vcdmount.exe /l="$letter" "$my_img_win" tries=0 - while test $tries -lt 20 - do - for W_ISO_MOUNT_LETTER in e f g h i j k - do + while test $tries -lt 20; do + for W_ISO_MOUNT_LETTER in e f g h i j k; do # let user blacklist drive letters echo "$WINETRICKS_MOUNT_LETTER_IGNORE" | grep -q "$W_ISO_MOUNT_LETTER" && continue W_ISO_MOUNT_ROOT=/cygdrive/$W_ISO_MOUNT_LETTER @@ -4674,8 +4650,7 @@ winetricks_is_mounted() # If that fails, read volume name the hard way for each volume # Have to use file to return results from implicit subshell rm -f "$W_TMP_EARLY/_W_tmp.$LOGNAME" - winetricks_list_mounts . | while true - do + winetricks_list_mounts . | while true; do IFS= read -r _W_tmp _W_dev=$(echo "$_W_tmp" | sed 's/ .*//') @@ -4724,8 +4699,7 @@ winetricks_mount_real_volume() W_ISO_MOUNT_LETTER=$(awk '/iso/ {print $1}' < /proc/mounts | tr -d :) W_ISO_MOUNT_ROOT=$(awk '/iso/ {print $2}' < /proc/mounts) else - while ! winetricks_is_mounted "$_W_expected_volname" - do + while ! winetricks_is_mounted "$_W_expected_volname"; do w_try w_warn_cancel "$_W_mountmsg" # In non-gui case, give user two seconds to futz with disc drive before spamming him again sleep 2 @@ -4873,10 +4847,9 @@ winetricks_set_wineprefix() "windows_cmd|wine_cmd") W_CACHE_WIN="$(w_pathconv -w "$W_CACHE")" ;; *) # For case where Z: doesn't exist or / is writable (!), - # make a drive letter for W_CACHE. Clean it up on exit. + # make a drive letter for W_CACHE. Clean it up on exit. test "$WINETRICKS_CACHE_SYMLINK" && rm -f "$WINETRICKS_CACHE_SYMLINK" - for letter in y x w v u t s r q p o n m - do + for letter in y x w v u t s r q p o n m; do if ! test -d "$WINEPREFIX"/dosdevices/${letter}:; then mkdir -p "$WINEPREFIX"/dosdevices WINETRICKS_CACHE_SYMLINK="$WINEPREFIX"/dosdevices/${letter}: @@ -5051,8 +5024,7 @@ winetricks_init() # The list of categories is also hardcoded in winetricks_mainmenu() :-( WINETRICKS_CATEGORIES="apps benchmarks dlls fonts games settings mkprefix" - for _W_cat in $WINETRICKS_CATEGORIES - do + for _W_cat in $WINETRICKS_CATEGORIES; do mkdir -p "$WINETRICKS_METADATA/$_W_cat" done @@ -5184,8 +5156,8 @@ winetricks_wine_setup() /usr/lib/i386-linux-gnu/wine-development/wineserver \ /usr/lib/powerpc-linux-gnu/wine-development/wineserver \ /usr/lib/x86_64-linux-gnu/wine-development/wineserver \ - file-not-found - do + file-not-found; do + if test -x "$x"; then case "$x" in /usr/lib/*/wine-development/wineserver|/usr/bin/wineserver-development) @@ -5381,8 +5353,7 @@ winetricks_handle_option() [ -w "$W_TMP_EARLY" ] || w_die "temporary directory: '$W_TMP_EARLY' ; is not user writeable" # Must initialize variables before calling w_metadata -if ! test "$WINETRICKS_LIB" -then +if ! test "$WINETRICKS_LIB"; then WINETRICKS_SRCDIR=$(dirname "$0") WINETRICKS_SRCDIR=$(w_try_cd "$WINETRICKS_SRCDIR"; pwd) @@ -5392,8 +5363,7 @@ then WINETRICKS_OPT_SHAREDPREFIX=${WINETRICKS_OPT_SHAREDPREFIX:-1} # Handle options before init, to avoid starting wine for --help or --version - while winetricks_handle_option "$1" - do + while winetricks_handle_option "$1"; do shift done @@ -5473,16 +5443,14 @@ helper_d3dx9_xx() # Even kinder, less invasive directx - only extract and override d3dx9_xx.dll w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -5884,14 +5852,12 @@ load_d3dcompiler_42() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -5920,14 +5886,12 @@ load_d3dcompiler_43() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -5998,14 +5962,12 @@ load_d3dx9() # Kinder, less invasive directx - only extract and override d3dx9_??.dll w_try_cabextract -d "$W_TMP" -L -F '*d3dx9*x86*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'd3dx9*.dll' "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F '*d3dx9*x64*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F 'd3dx9*.dll' "$x" done fi @@ -6333,14 +6295,12 @@ load_d3dx11_42() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -6365,14 +6325,12 @@ load_d3dx11_43() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -6396,14 +6354,12 @@ load_d3dx10() # Kinder, less invasive directx10 - only extract and override d3dx10_??.dll w_try_cabextract -d "$W_TMP" -L -F '*d3dx10*x86*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'd3dx10*.dll' "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F '*d3dx10*x64*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F 'd3dx10*.dll' "$x" done fi @@ -6430,14 +6386,12 @@ load_d3dx10_43() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x86*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F "$dllname.dll" "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F "*$dllname*x64*" "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F "$dllname.dll" "$x" done fi @@ -6661,8 +6615,7 @@ load_dpvoice() helper_directx_dl w_try_cabextract -d "$W_TMP" -L -F 'dxnt.cab' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'dpvoice.dll' "$x" w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'dpvvox.dll' "$x" w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'dpvacm.dll' "$x" @@ -8458,9 +8411,7 @@ load_dotnet30() LANGPACKS_BASE_PATH="${W_WINDIR_UNIX}/SYSMSICache/Framework/v3.0" test -d "${LANGPACKS_BASE_PATH}" || mkdir -p "${LANGPACKS_BASE_PATH}" # shellcheck disable=SC1010 - for lang in ar cs da de el es fi fr he it jp ko nb nl pl pt-BR pt-PT ru \ - sv tr zh-CHS zh-CHT - do + for lang in ar cs da de el es fi fr he it jp ko nb nl pl pt-BR pt-PT ru sv tr zh-CHS zh-CHT; do ln -sf "${W_SYSTEM32_DLLS}/spupdsvc.exe" "${LANGPACKS_BASE_PATH}/dotnetfx3langpack${lang}.exe" done @@ -9973,8 +9924,7 @@ _EOF_ # Note, this leaves a dangling explorer window. # Wait for it to appear and kill it - while ! inode_pid=$(pgrep -f "explorer.exe.*Indeo") - do + while ! inode_pid=$(pgrep -f "explorer.exe.*Indeo"); do sleep 1 done kill -HUP "$inode_pid" @@ -10241,8 +10191,7 @@ load_mdx() # Install assemblies w_try_cabextract -d "$W_WINDIR_UNIX/Microsoft.NET/DirectX for Managed Code/1.0.2902.0" -F "microsoft.directx*" ./*MDX1_x86.cab - for file in mdx_*.cab - do + for file in mdx_*.cab; do ver="${file%%_x86.cab}" ver="${ver##mdx_}" w_try_cabextract -d "$W_WINDIR_UNIX/Microsoft.NET/DirectX for Managed Code/$ver" -F "microsoft.directx*" "$file" @@ -10251,12 +10200,10 @@ load_mdx() # Add them to GAC w_try_cd "$W_WINDIR_UNIX/Microsoft.NET/DirectX for Managed Code" - for ver in * - do + for ver in *; do ( w_try_cd "$ver" - for asm in *.dll - do + for asm in *.dll; do name="${asm%%.dll}" w_try mkdir -p "$W_WINDIR_UNIX/assembly/GAC/$name/${ver}__31bf3856ad364e35" w_try cp "$asm" "$W_WINDIR_UNIX/assembly/GAC/$name/${ver}__31bf3856ad364e35" @@ -11710,27 +11657,8 @@ load_vcrun2005() w_try "$WINE" "$file1" $W_UNATTENDED_SLASH_Q if [ $W_ARCH = win64 ] ;then - w_download https://download.microsoft.com/download/9/1/4/914851c6-9141-443b-bdb4-8bad3a57bea9/vcredist_x64.exe bb9e8606e26c2b76984252182f7db0d6e9108b204b81d2a7b036c9b618c1f9f1 - - if w_workaround_wine_bug 30713 "Manually extracting the 64-bit dlls" ,3.8; then - rm -f "$W_TMP"/* # Avoid permission error - w_try_cabextract --directory="$W_TMP" vcredist_x64.exe - w_try_cabextract --directory="$W_TMP" "$W_TMP/VCREDI~2.EXE" - w_try_cabextract --directory="$W_TMP" "$W_TMP/vcredist.msi" - - w_try cp "$W_TMP/ATL80.dll.837BF1EB_D770_94EB_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/atl80.dll" - w_try cp "$W_TMP/mfc80.dll.8731EA9C_B0D8_8F16_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/mfc80.dll" - w_try cp "$W_TMP/mfc80u.dll.8731EA9C_B0D8_8F16_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/mfc80u.dll" - w_try cp "$W_TMP/mfcm80.dll.8731EA9C_B0D8_8F16_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/mfcm80.dll" - w_try cp "$W_TMP/mfcm80u.dll.8731EA9C_B0D8_8F16_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/mfcm80u.dll" - - w_try cp "$W_TMP/msvcm80.dll.844EFBA7_1C24_93B2_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/msvcm80.dll" - w_try cp "$W_TMP/msvcp80.dll.844EFBA7_1C24_93B2_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/msvcp80.dll" - w_try cp "$W_TMP/msvcr80.dll.844EFBA7_1C24_93B2_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/msvcr80.dll" - w_try cp "$W_TMP/vcomp.dll.09D44781_D142_FE32_FF1F_C8B3B9A1E18E" "$W_SYSTEM64_DLLS/vcomp80.dll" - else - w_try "$WINE" vcredist_x64.exe $W_UNATTENDED_SLASH_Q - fi + w_download https://download.microsoft.com/download/8/B/4/8B42259F-5D70-43F4-AC2E-4B208FD8D66A/vcredist_x64.EXE 0551a61c85b718e1fa015b0c3e3f4c4eea0637055536c00e7969286b4fa663e0 + w_try "$WINE" vcredist_x64.exe $W_UNATTENDED_SLASH_Q fi } @@ -12451,14 +12379,12 @@ load_xinput() helper_directx_Jun2010 w_try_cabextract -d "$W_TMP" -L -F '*_xinput_*x86*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*.cab - do + for x in "$W_TMP"/*.cab; do w_try_cabextract -d "$W_SYSTEM32_DLLS" -L -F 'xinput*.dll' "$x" done if test "$W_ARCH" = "win64"; then w_try_cabextract -d "$W_TMP" -L -F '*_xinput_*x64*' "$W_CACHE"/directx9/$DIRECTX_NAME - for x in "$W_TMP"/*x64.cab - do + for x in "$W_TMP"/*x64.cab; do w_try_cabextract -d "$W_SYSTEM64_DLLS" -L -F 'xinput*.dll' "$x" done fi @@ -13493,8 +13419,7 @@ w_metadata allfonts fonts \ load_allfonts() { # This verb uses reflection, should probably do it portably instead, but that would require keeping it up to date - for file in "$WINETRICKS_METADATA"/fonts/*.vars - do + for file in "$WINETRICKS_METADATA"/fonts/*.vars; do cmd=$(basename "$file" .vars) case $cmd in # "fake*" verbs need to be skipped because @@ -14055,8 +13980,7 @@ load_ie6() # Remove the fake DLLs, if any mv "$W_PROGRAMS_UNIX/Internet Explorer/iexplore.exe" "$W_PROGRAMS_UNIX/Internet Explorer/iexplore.exe.bak" - for dll in itircl itss jscript mlang mshtml msimtf shdoclc shdocvw shlwapi - do + for dll in itircl itss jscript mlang mshtml msimtf shdoclc shdocvw shlwapi; do test -f "$W_SYSTEM32_DLLS"/$dll.dll && mv "$W_SYSTEM32_DLLS"/$dll.dll "$W_SYSTEM32_DLLS"/$dll.dll.bak done @@ -14103,8 +14027,7 @@ load_ie6() rpcrt4.dll rsabase.dll rsaenh.dll scrobj.dll scrrun.dll \ shdocvw.dll shell32.dll vbscript.dll webcheck.dll \ wshcon.dll wshext.dll asctrls.ocx hhctrl.ocx mscomct2.ocx \ - plugin.ocx proctexe.ocx tdc.ocx webcheck.dll wshom.ocx - do + plugin.ocx proctexe.ocx tdc.ocx webcheck.dll wshom.ocx; do "$WINE" regsvr32 /i $i > /dev/null 2>&1 done @@ -14150,8 +14073,7 @@ load_ie7() if [ -f "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe" ]; then mv "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe" "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe.bak" fi - for dll in itircl itss jscript mshtml msimtf shdoclc shdocvw shlwapi urlmon - do + for dll in itircl itss jscript mshtml msimtf shdoclc shdocvw shlwapi urlmon; do test -f "$W_SYSTEM32_DLLS"/$dll.dll && mv "$W_SYSTEM32_DLLS"/$dll.dll "$W_SYSTEM32_DLLS"/$dll.dll.bak done @@ -14207,8 +14129,7 @@ load_ie7() rpcrt4.dll rsabase.dll rsaenh.dll scrobj.dll scrrun.dll \ shdocvw.dll shell32.dll urlmon.dll vbscript.dll webcheck.dll \ wshcon.dll wshext.dll asctrls.ocx hhctrl.ocx mscomct2.ocx \ - plugin.ocx proctexe.ocx tdc.ocx webcheck.dll wshom.ocx - do + plugin.ocx proctexe.ocx tdc.ocx webcheck.dll wshom.ocx; do "$WINE" regsvr32 /i $i > /dev/null 2>&1 done @@ -14258,7 +14179,7 @@ load_ie8() w_call msls31 # Change the override to the native so we are sure we use and register them - w_override_dlls native,builtin ieproxy itircl itss jscript msctf mshtml shdoclc shdocvw shlwapi urlmon wininet xmllite + w_override_dlls native,builtin ieframe ieproxy itircl itss jscript msctf mshtml shdoclc shdocvw shlwapi urlmon wininet xmllite # IE8 installer will check the version number of iexplore.exe which causes IE8 installer to fail on wine-1.9.0+ w_override_dlls native iexplore.exe @@ -14270,8 +14191,7 @@ load_ie8() if [ -f "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe" ]; then mv "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe" "$W_PROGRAMS_X86_UNIX/Internet Explorer/iexplore.exe.bak" fi - for dll in browseui inseng itircl itss jscript msctf mshtml shdoclc shdocvw shlwapi urlmon - do + for dll in browseui inseng itircl itss jscript msctf mshtml shdoclc shdocvw shlwapi urlmon; do test -f "$W_SYSTEM32_DLLS"/$dll.dll && mv "$W_SYSTEM32_DLLS"/$dll.dll "$W_SYSTEM32_DLLS"/$dll.dll.bak done @@ -14316,8 +14236,7 @@ load_ie8() rpcrt4.dll rsabase.dll rsaenh.dll scrobj.dll scrrun.dll \ shdocvw.dll shell32.dll urlmon.dll vbscript.dll webcheck.dll \ wshcon.dll wshext.dll asctrls.ocx hhctrl.ocx mscomct2.ocx \ - plugin.ocx proctexe.ocx tdc.ocx uxtheme.dll webcheck.dll wshom.ocx - do + plugin.ocx proctexe.ocx tdc.ocx uxtheme.dll webcheck.dll wshom.ocx; do "$WINE" regsvr32 /i $i > /dev/null 2>&1 done @@ -17800,8 +17719,7 @@ load_dragonage() " # Since the installer explodes on exit, just wait for the # last file it's known to create - while ! test -f "$W_PROGRAMS_X86_UNIX/Dragon Age/bin_ship/DAOriginsLauncher-MCE.png" - do + while ! test -f "$W_PROGRAMS_X86_UNIX/Dragon Age/bin_ship/DAOriginsLauncher-MCE.png"; do w_info "Waiting for installer to finish..." sleep 1 done @@ -19752,8 +19670,7 @@ load_spore_cc_demo() send {SPACE}{DOWN}{SPACE}{ENTER} winwaitclose " - while pgrep -f "$file1" > /dev/null - do + while pgrep -f "$file1" > /dev/null; do w_info "Waiting for installer to finish." sleep 2 done @@ -21422,8 +21339,7 @@ load_isolate_home() _olddir="$(pwd)" w_try_cd "$WINEPREFIX/drive_c/users/$USER" - for x in * - do + for x in *; do if test -h "$x" && test -d "$x"; then rm -f "$x" mkdir -p "$x" @@ -21479,8 +21395,8 @@ load_remove_mono() # If wine uninstaller can't find the application it will return 0 anyway. mono_uuid="$("${WINE_ARCH}" uninstaller --list | grep 'Wine Mono' | cut -f1 -d\|)" if test "$mono_uuid"; then - for uuid in $mono_uuid; - do "${WINE_ARCH}" uninstaller --remove "$uuid" + for uuid in $mono_uuid; do + "${WINE_ARCH}" uninstaller --remove "$uuid" done else # Bail out if mono isn't installed, so we don't break .Net setups @@ -21871,8 +21787,7 @@ winetricks_shell() $SHELL ;; *) - for term in gnome-terminal konsole Terminal xterm - do + for term in gnome-terminal konsole Terminal xterm; do if test "$(command -v $term 2>/dev/null)"; then $term break @@ -21915,8 +21830,7 @@ execute_command() list-installed) winetricks_list_installed ;; list-all) old_menu="$WINETRICKS_CURMENU" - for WINETRICKS_CURMENU in apps benchmarks dlls fonts games prefix settings - do + for WINETRICKS_CURMENU in apps benchmarks dlls fonts games prefix settings; do echo "===== $WINETRICKS_CURMENU =====" winetricks_list_all done @@ -22014,8 +21928,7 @@ execute_command() esac } -if ! test "$WINETRICKS_LIB" -then +if ! test "$WINETRICKS_LIB"; then # If user opted out, save that preference now. winetricks_stats_save @@ -22055,8 +21968,7 @@ then winetricks_detect_gui winetricks_detect_sudo test -z "$WINETRICKS_ISO_MOUNT" && winetricks_detect_iso_mount - while true - do + while true; do case $WINETRICKS_CURMENU in main) verbs=$(winetricks_mainmenu) ;; prefix) @@ -22098,8 +22010,7 @@ then # after picking a prefix, want to land in main. WINETRICKS_CURMENU=main ;; *) - for verb in $verbs - do + for verb in $verbs; do execute_command "$verb" done diff --git a/portwine_run_scripts/winetricks-q-force b/portwine_run_scripts/winetricks-q-force index 2be86026..cf0ea658 100755 --- a/portwine_run_scripts/winetricks-q-force +++ b/portwine_run_scripts/winetricks-q-force @@ -1,5 +1,5 @@ #!/bin/bash -# Author: Tergoev M.A. +# Author: PortWINE-Linux.ru . "$(dirname "`readlink -f "$0"`")"/runlib rm -f ${link}/winetricks