Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
PortWINE-old
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-old
Commits
11979dae
Commit
11979dae
authored
Jul 13, 2024
by
Vladislav
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added timeout for gamescope,vulkaninfo,xrandr,lspci,locale. (If suddenly they do…
Added timeout for gamescope,vulkaninfo,xrandr,lspci,locale. (If suddenly they do not work correctly)
parent
445fd7a5
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
44 additions
and
9 deletions
+44
-9
start.sh
data_from_portwine/scripts/start.sh
+44
-9
No files found.
data_from_portwine/scripts/start.sh
View file @
11979dae
...
...
@@ -203,27 +203,56 @@ pw_check_and_download_plugins
# check skip update
if
[[
"
${
SKIP_CHECK_UPDATES
}
"
!=
1
]]
;
then
pw_port_update
if
command
gamescope
--help
2>
"
${
PW_TMPFS_PATH
}
/gamescope-help.tmp"
;
then
if
timeout
5 gamescope
--help
2>
"
${
PW_TMPFS_PATH
}
/gamescope-help.tmp"
;
then
export
GAMESCOPE_INSTALLED
=
"1"
else
if
!
command
-v
gamescope &>/dev/null
;
then
print_error
"gamescope - not found!"
else
print_error
"gamescope - broken!"
fi
if
command
-v
vulkaninfo &>/dev/null
;
then
vulkaninfo
--summary
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
fi
if
timeout
5 vulkaninfo
--summary
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
;
then
VULKAN_DRIVER_NAME
=
"
$(
grep
-e
'driverName'
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
|
awk
'{print$3}'
|
head
-1
)
"
GET_GPU_NAMES
=
$(
awk
-F
'='
'/deviceName/{print $2}'
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
|
sed
'/llvm/d'
|
sort
-u
|
sed
's/^ //'
|
paste
-sd
'!'
)
export
VULKAN_DRIVER_NAME GET_GPU_NAMES
else
if
!
command
-v
vulkaninfo &>/dev/null
;
then
$PW_PLUGINS_PATH
/portable/bin/x86_64-linux-gnu-vulkaninfo 2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
fi
VULKAN_DRIVER_NAME
=
"
$(
grep
-e
'driverName'
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
|
awk
'{print$3}'
|
head
-1
)
"
GET_GPU_NAMES
=
$(
awk
-F
'='
'/deviceName/{print $2}'
"
${
PW_TMPFS_PATH
}
/vulkaninfo.tmp"
|
sed
'/llvm/d'
|
sort
-u
|
sed
's/^ //'
|
paste
-sd
'!'
)
LSPCI_VGA
=
"
$(
lspci
-k
2>/dev/null |
grep
-E
'VGA|3D'
|
tr
-d
'\n'
)
"
export
VULKAN_DRIVER_NAME GET_GPU_NAMES LSPCI_VGA
export
VULKAN_DRIVER_NAME GET_GPU_NAMES
print_warning
"use portable vulkaninfo"
else
print_error
"vulkaninfo - broken!"
fi
fi
if
command
xrandr
--current
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/xrandr.tmp"
;
then
if
timeout
5 lspci
-k
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/lspci.tmp"
;
then
LSPCI_VGA
=
"
$(
grep
-e
'VGA|3D'
"
${
PW_TMPFS_PATH
}
/lspci.tmp"
|
tr
-d
'\n'
)
"
export
LSPCI_VGA
else
if
!
command
-v
lspci &>/dev/null
;
then
print_error
"lspci - not found!"
else
print_error
"lspci - broken!"
fi
fi
if
timeout
5 xrandr
--current
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/xrandr.tmp"
;
then
PW_SCREEN_RESOLUTION
=
"
$(
cat
"
${
PW_TMPFS_PATH
}
/xrandr.tmp"
|
sed
-rn
's/^.*primary.* ([0-9]+x[0-9]+).*$/\1/p'
)
"
PW_SCREEN_PRIMARY
=
"
$(
grep
-e
'primary'
"
${
PW_TMPFS_PATH
}
/xrandr.tmp"
|
awk
'{print $1}'
)
"
export
PW_SCREEN_PRIMARY PW_SCREEN_RESOLUTION
echo
""
print_var PW_SCREEN_RESOLUTION PW_SCREEN_PRIMARY
else
if
!
command
-v
xrandr &>/dev/null
;
then
print_error
"xrandr - not found!"
else
print_error
"xrandr - broken!"
fi
fi
echo
""
...
...
@@ -235,9 +264,9 @@ if [[ "${SKIP_CHECK_UPDATES}" != 1 ]] ; then
fi
export
GET_LOGICAL_CORE
if
timeout
5 locale
-a
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/locale.tmp"
;
then
GET_LOCALE_LIST
=
"ru_RU.utf en_US.utf zh_CN.utf ja_JP.utf ko_KR.utf"
unset
LOCALE_LIST
locale
-a
2>/dev/null
>
"
${
PW_TMPFS_PATH
}
/locale.tmp"
for
LOCALE
in
$GET_LOCALE_LIST
;
do
if
grep
-e
$LOCALE
"
${
PW_TMPFS_PATH
}
/locale.tmp"
&>/dev/null
;
then
if
[[
!
-z
"
$LOCALE_LIST
"
]]
...
...
@@ -247,12 +276,18 @@ if [[ "${SKIP_CHECK_UPDATES}" != 1 ]] ; then
fi
done
export
LOCALE_LIST
else
if
!
command
-v
locale &>/dev/null
;
then
print_error
"locale - not found!"
else
print_error
"locale - broken!"
fi
fi
else
scripts_install_ver
=
$(
head
-n
1
"
${
PORT_WINE_TMP_PATH
}
/scripts_ver"
)
export
scripts_install_ver
fi
# create lock file
if
!
check_flatpak
;
then
if
[[
-f
"
${
PW_TMPFS_PATH
}
/portproton.lock"
]]
;
then
...
...
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