Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
PortWINE
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav
PortWINE
Commits
4cf95548
Commit
4cf95548
authored
Apr 04, 2024
by
Mikhail Tergoev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
move runlib to start.sh
parent
bfeb559a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
164 additions
and
15 deletions
+164
-15
functions_helper
data_from_portwine/scripts/functions_helper
+0
-0
runlib
data_from_portwine/scripts/runlib
+0
-0
setup.sh
data_from_portwine/scripts/setup.sh
+6
-8
start.sh
data_from_portwine/scripts/start.sh
+157
-6
yad_gui
data_from_portwine/scripts/yad_gui
+1
-1
No files found.
data_from_portwine/scripts/functions_helper
View file @
4cf95548
This diff is collapsed.
Click to expand it.
data_from_portwine/scripts/runlib
deleted
100755 → 0
View file @
bfeb559a
This diff is collapsed.
Click to expand it.
data_from_portwine/scripts/setup.sh
View file @
4cf95548
#!/usr/bin/env bash
# Author: linux-gaming.ru
.
"
$(
dirname
$(
readlink
-f
"
$0
"
))
/
runlib
"
.
"
$(
dirname
$(
readlink
-f
"
$0
"
))
/
start.sh
"
name_desktop
=
"PortProton"
if
check_flatpak
;
then
...
...
@@ -31,8 +31,7 @@ else
chmod
u+x
"
${
PORT_WINE_PATH
}
/
${
name_desktop
}
.desktop"
fi
if
[[
!
-f
/usr/bin/portproton
]]
&&
!
check_flatpak
then
if
[[
!
-f
/usr/bin/portproton
]]
&&
!
check_flatpak
;
then
cp
-f
"
${
PORT_WINE_PATH
}
/
${
name_desktop
}
.desktop"
${
HOME
}
/.local/share/applications/
fi
...
...
@@ -55,17 +54,16 @@ echo "Icon="${PORT_WINE_PATH}/data/img/readme.png"" >> "${PORT_WINE_PATH}/${nam
echo
"URL=
${
urlg
}
"
>>
"
${
PORT_WINE_PATH
}
/
${
name_desktop
}
.desktop"
chmod
u+x
"
${
PORT_WINE_PATH
}
/
${
name_desktop
}
.desktop"
if
[
"
${
PW_SILENT_INSTALL
}
"
=
"1"
]
;
then
if
[
"
${
PW_AUTOPLAY
}
"
=
"1"
]
;
then
unset
INSTALLING_PORT
unset
INSTALLING_PORT
if
[[
"
${
PW_SILENT_INSTALL
}
"
==
1
]
]
;
then
if
[[
"
${
PW_AUTOPLAY
}
"
==
1
]]
;
then
if
[[
-f
"
${
HOME
}
/.local/share/applications/PortProton.desktop"
]]
&&
[[
-f
/usr/bin/portproton
]]
;
then
try_remove_file
"
${
HOME
}
/.local/share/applications/PortProton.desktop"
fi
echo
"Restarting PP after installing..."
/usr/bin/env bash
-c
"
${
PORT_WINE_PATH
}
/data/scripts/start.sh"
$@
&
/usr/bin/env bash
-c
"
${
PORT_WINE_PATH
}
/data/scripts/start.sh"
$@
&
exit
0
else
echo
"Installation completed successfully."
fi
fi
unset
INSTALLING_PORT
data_from_portwine/scripts/start.sh
View file @
4cf95548
#!/usr/bin/env bash
# Author: linux-gaming.ru
# Author: Castro-Fidel (linux-gaming.ru)
# Development assistants: Cefeiko; Dezert1r; Taz_mania; Anton_Famillianov; gavr; RidBowt; chal55rus; UserDiscord; Boria138; Vano; Akai
########################################################################
echo
'
█░░ █ █▄░█ █░█ ▀▄▀ ▄▄ █▀▀ ▄▀█ █▀▄▀█ █ █▄░█ █▀▀ ░ █▀█ █░█
█▄▄ █ █░▀█ █▄█ █░█ ░░ █▄█ █▀█ █░▀░█ █ █░▀█ █▄█ ▄ █▀▄ █▄█
██████╗░░█████╗░██████╗░████████╗██████╗░██████╗░░█████╗░████████╗░█████╗░███╗░░██╗
██╔══██╗██╔══██╗██╔══██╗╚══██╔══╝██╔══██╗██╔══██╗██╔══██╗╚══██╔══╝██╔══██╗████╗░██║
██████╔╝██║░░██║██████╔╝░░░██║░░░██████╔╝██████╔╝██║░░██║░░░██║░░░██║░░██║██╔██╗██║
██╔═══╝░██║░░██║██╔══██╗░░░██║░░░██╔═══╝░██╔══██╗██║░░██║░░░██║░░░██║░░██║██║╚████║
██║░░░░░╚█████╔╝██║░░██║░░░██║░░░██║░░░░░██║░░██║╚█████╔╝░░░██║░░░╚█████╔╝██║░╚███║
╚═╝░░░░░░╚════╝░╚═╝░░╚═╝░░░╚═╝░░░╚═╝░░░░░╚═╝░░╚═╝░╚════╝░░░░╚═╝░░░░╚════╝░╚═╝░░╚══╝
'
if
[[
$(
id
-u
)
=
0
]]
;
then
echo
"Do not run this script as root!"
exit
1
fi
export
PW_START_PID
=
"
$$
"
export
NO_AT_BRIDGE
=
1
...
...
@@ -22,7 +40,140 @@ then
MISSING_DESKTOP_FILE
=
0
fi
.
"
$(
dirname
$(
readlink
-f
"
$0
"
))
/runlib"
.
"
$(
dirname
$(
readlink
-f
"
$0
"
))
/functions_helper"
if
[[
-z
"
${
LANG
}
"
]]
;
then
export
LANG
=
C
export
FORCE_ENG_LANG
=
1
elif
[[
"
${
START_FROM_STEAM
}
"
==
1
]]
;
then
export
FORCE_ENG_LANG
=
1
else
unset
FORCE_ENG_LANG
fi
create_new_dir
"
${
HOME
}
/.local/share/applications"
if
[[
"
${
PW_SILENT_RESTART
}
"
==
1
]]
||
[[
"
${
START_FROM_STEAM
}
"
==
1
]]
;
then
export
PW_GUI_DISABLED_CS
=
1
unset
PW_SILENT_RESTART
else
unset
PW_GUI_DISABLED_CS
fi
unset
MANGOHUD MANGOHUD_DLSYM PW_NO_ESYNC PW_NO_FSYNC PW_VULKAN_USE WINEDLLOVERRIDES PW_NO_WRITE_WATCH PW_YAD_SET PW_ICON_FOR_YAD
unset
PW_CHECK_AUTOINSTAL PW_VKBASALT_EFFECTS PW_VKBASALT_FFX_CAS PORTWINE_DB PORTWINE_DB_FILE PW_DISABLED_CREATE_DB RADV_PERFTEST
unset
CHK_SYMLINK_FILE MESA_GL_VERSION_OVERRIDE PATH_TO_GAME PW_START_DEBUG PORTPROTON_NAME PORTWINE_CREATE_SHORTCUT_NAME FLATPAK_IN_USE
unset
PW_PREFIX_NAME WINEPREFIX VULKAN_MOD PW_WINE_VER PW_ADD_TO_ARGS_IN_RUNTIME PW_GAMEMODERUN_SLR AMD_VULKAN_ICD PW_WINE_CPU_TOPOLOGY
unset
PW_NAME_D_NAME PW_NAME_D_ICON PW_NAME_D_EXEC PW_EXEC_FROM_DESKTOP PW_ALL_DF PW_GENERATE_BUTTONS PW_NAME_D_ICON PW_NAME_D_ICON_48
unset
MANGOHUD_CONFIG PW_WINE_USE WINEDLLPATH WINE WINEDIR WINELOADER WINESERVER PW_USE_RUNTIME
export
portname
=
PortProton
cd
"
$(
dirname
"
`
readlink
-f
"
$0
"
`
"
)
"
&&
export
PORT_SCRIPTS_PATH
=
"
$(
pwd
)
"
cd
"
${
PORT_SCRIPTS_PATH
}
/../../"
&&
export
PORT_WINE_PATH
=
"
$(
pwd
)
"
export
PORT_WINE_TMP_PATH
=
"
${
PORT_WINE_PATH
}
/data/tmp"
rm
-f
$PORT_WINE_TMP_PATH
/
*
{
exe,msi,tar
}
*
echo
""
>
"
${
PORT_WINE_TMP_PATH
}
/tmp_yad_form"
if
[[
-d
"
${
PORT_WINE_PATH
}
/data/dist"
]]
;
then
try_remove_file
"
${
PORT_WINE_PATH
}
/data/dist/VERSION"
orig_IFS
=
"
$IFS
"
IFS
=
$'
\n
'
for
dist_dir
in
$(
ls
-1
"
${
PORT_WINE_PATH
}
/data/dist/"
)
;
do
dist_dir_new
=
`
echo
"
${
dist_dir
}
"
|
awk
'$1=$1'
|
sed
-e
s/[[:blank:]]/_/g
`
if
[[
!
-d
"
${
PORT_WINE_PATH
}
/data/dist/
${
dist_dir_new
^^
}
"
]]
;
then
mv
--
"
${
PORT_WINE_PATH
}
/data/dist/
$dist_dir
"
"
${
PORT_WINE_PATH
}
/data/dist/
${
dist_dir_new
^^
}
"
fi
done
IFS
=
"
$orig_IFS
"
else
create_new_dir
"
${
PORT_WINE_PATH
}
/data/dist"
fi
create_new_dir
"
${
PORT_WINE_PATH
}
/data/prefixes/DEFAULT"
create_new_dir
"
${
PORT_WINE_PATH
}
/data/prefixes/DOTNET"
create_new_dir
"
${
PORT_WINE_PATH
}
/data/prefixes/PROGRAMS"
try_force_link_dir
"
${
PORT_WINE_PATH
}
/data/prefixes"
"
${
PORT_WINE_PATH
}
"
orig_IFS
=
"
$IFS
"
IFS
=
$'
\n
'
for
pfx_dir
in
$(
ls
-1
"
${
PORT_WINE_PATH
}
/data/prefixes/"
)
;
do
pfx_dir_new
=
`
echo
"
${
pfx_dir
}
"
|
awk
'$1=$1'
|
sed
-e
s/[[:blank:]]/_/g
`
if
[[
!
-d
"
${
PORT_WINE_PATH
}
/data/prefixes/
${
pfx_dir_new
^^
}
"
]]
;
then
mv
--
"
${
PORT_WINE_PATH
}
/data/prefixes/
$pfx_dir
"
"
${
PORT_WINE_PATH
}
/data/prefixes/
${
pfx_dir_new
^^
}
"
fi
done
IFS
=
"
$orig_IFS
"
create_new_dir
"
${
PORT_WINE_TMP_PATH
}
"
/gecko
create_new_dir
"
${
PORT_WINE_TMP_PATH
}
"
/mono
export
PW_VULKAN_DIR
=
"
${
PORT_WINE_TMP_PATH
}
/VULKAN"
create_new_dir
"
${
PW_VULKAN_DIR
}
"
export
LSPCI_VGA
=
"
$(
lspci
-k
|
grep
-E
'VGA|3D'
|
tr
-d
'\n'
)
"
if
command
-v
xrandr &>/dev/null
;
then
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_screen_configuration"
export
PW_SCREEN_RESOLUTION
=
"
$(
xrandr |
sed
-rn
's/^.*primary.* ([0-9]+x[0-9]+).*$/\1/p'
)
"
export
PW_SCREEN_PRIMARY
=
"
$(
xrandr |
grep
"primary"
|
awk
'{print $1}'
)
"
print_var PW_SCREEN_RESOLUTION PW_SCREEN_PRIMARY
else
print_error
"xrandr - not found!"
fi
cd
"
${
PORT_SCRIPTS_PATH
}
"
.
"
${
PORT_SCRIPTS_PATH
}
/var"
export
STEAM_SCRIPTS
=
"
${
PORT_WINE_PATH
}
/steam_scripts"
export
PW_PLUGINS_PATH
=
"
${
PORT_WINE_TMP_PATH
}
/plugins
${
PW_PLUGINS_VER
}
"
export
PW_GUI_ICON_PATH
=
"
${
PORT_WINE_PATH
}
/data/img/gui"
.
"
${
PORT_SCRIPTS_PATH
}
"
/lang
.
"
${
PORT_SCRIPTS_PATH
}
"
/yad_gui
export
urlg
=
"https://linux-gaming.ru/portproton/"
export
PW_WINELIB
=
"
${
PORT_WINE_TMP_PATH
}
/libs
${
PW_LIBS_VER
}
"
try_remove_dir
"
${
PW_WINELIB
}
/var"
export
install_ver
=
`
cat
"
${
PORT_WINE_TMP_PATH
}
/
${
portname
}
_ver"
|
head
-n
1
`
export
WINETRICKS_DOWNLOADER
=
"curl"
export
USER_CONF
=
"
${
PORT_WINE_PATH
}
/data/user.conf"
check_user_conf
check_variables PW_LOG
"0"
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/update_pfx_log"
[[
"
${
PW_SILENT_INSTALL
}
"
==
1
]]
&&
return
0
.
"
${
USER_CONF
}
"
if
[[
"
${
SKIP_CHECK_UPDATES
}
"
!=
1
]]
\
&&
[[
!
-f
"/tmp/portproton.lock"
]]
then
pw_port_update
fi
unset
SKIP_CHECK_UPDATES
pw_check_and_download_plugins
if
[[
-f
"/tmp/portproton.lock"
]]
;
then
print_warning
"Found lock file: /tmp/portproton.lock"
yad_question
"
$loc_gui_portproton_lock
"
||
exit
0
fi
touch
"/tmp/portproton.lock"
rm_lock_file
()
{
echo
"Removing the lock file..."
rm
-fv
"/tmp/portproton.lock"
&&
echo
"OK"
}
trap
"rm_lock_file"
EXIT
pw_download_libs
export
PW_VULKANINFO_PORTABLE
=
"
$PW_PLUGINS_PATH
/portable/bin/x86_64-linux-gnu-vulkaninfo"
export
VULKAN_API_DRIVER_VERSION
=
"
$(
"
$PW_VULKANINFO_PORTABLE
"
2>/dev/null |
grep
"api"
|
head
-n
1 |
awk
'{print $3}'
)
"
export
VULKAN_DRIVER_NAME
=
"
$(
"
$PW_VULKANINFO_PORTABLE
"
2>/dev/null |
grep
driverName |
awk
'{print$3}'
|
head
-1
)
"
pw_init_db
.
"
${
PORT_SCRIPTS_PATH
}
"
/lang
pw_check_and_download_dxvk_and_vkd3d
.
"
${
USER_CONF
}
"
kill_portwine
killall
-15
yad_v12_3 2>/dev/null
kill
-TERM
`
pgrep
-a
yad |
grep
${
portname
}
|
head
-n
1 |
awk
'{print $1}'
`
2>/dev/null
...
...
@@ -576,9 +727,9 @@ if [[ ! -z "${PORTWINE_DB_FILE}" ]] ; then
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_LG_VER
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
else
if
[[
"
${
PW_WINE_USE
}
"
==
"
${
PW_PROTON_LG_VER
}
"
]]
;
then
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_WINE_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_WINE_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
elif
[[
"
${
PW_WINE_USE
}
"
==
"
${
PW_WINE_LG_VER
}
"
]]
;
then
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
else
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
}
!
${
PW_WINE_LG_VER
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
...
...
@@ -591,9 +742,9 @@ else
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_LG_VER
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
else
if
[[
"
${
PW_WINE_USE
}
"
==
"
${
PW_PROTON_LG_VER
}
"
]]
;
then
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_WINE_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_WINE_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
elif
[[
"
${
PW_WINE_USE
}
"
==
"
${
PW_WINE_LG_VER
}
"
]]
;
then
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
export
PW_DEFAULT_WINE_USE
=
"
${
PW_WINE_USE
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
else
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
}
!
${
PW_WINE_LG_VER
}
!
${
PW_PROTON_LG_VER
}${
DIST_ADD_TO_GUI
}
!GET-OTHER-WINE"
...
...
data_from_portwine/scripts/yad_gui
View file @
4cf95548
...
...
@@ -460,7 +460,7 @@ gui_proton_downloader () {
fi
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_proton_pw_git"
#
try_remove_file "${PORT_WINE_TMP_PATH}/tmp_wine_kron4ek_git"
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_wine_kron4ek_git"
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_proton_ge_git"
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_wine_ge_custom_git"
try_remove_file
"
${
PORT_WINE_TMP_PATH
}
/tmp_installed_wine"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment