mirror of
https://codeberg.org/smxi/pinxi.git
synced 2024-09-28 15:20:29 +02:00
made possible different combos for mesa version detections more
robust and future proof
This commit is contained in:
parent
75a1a6fdbf
commit
1f50f2e487
1 changed files with 9 additions and 8 deletions
17
pinxi
17
pinxi
|
@ -50,8 +50,8 @@ use POSIX qw(ceil uname strftime ttyname);
|
|||
## INXI INFO ##
|
||||
my $self_name='pinxi';
|
||||
my $self_version='3.3.34';
|
||||
my $self_date='2024-05-18';
|
||||
my $self_patch='08';
|
||||
my $self_date='2024-05-19';
|
||||
my $self_patch='09';
|
||||
## END INXI INFO ##
|
||||
|
||||
my ($b_pledge,@pledges);
|
||||
|
@ -15890,7 +15890,7 @@ sub gl_data {
|
|||
# $file = "$fake_data_dir/graphics/glxinfo/glxinfo-x11-neomagic-lenny-1.txt";
|
||||
# $file = "$fake_data_dir/graphics/glxinfo/glxinfo-nvidia-gl4.6-chr.txt";
|
||||
# $file = "$fake_data_dir/graphics/glxinfo/glxinfo-intel-atom-dell_studio-bm.txt";
|
||||
# $file = "$fake_data_dir/graphics/glxinfo/glxinfo-asus_1025c-atom-bm.txt";
|
||||
#$file = "$fake_data_dir/graphics/glxinfo/glxinfo-asus_1025c-atom-bm.txt";
|
||||
# $file = "$fake_data_dir/graphics/glxinfo/glxinfo-2011-nvidia-glx1.4.txt";
|
||||
$gl_data= main::reader($file,'','ref');
|
||||
}
|
||||
|
@ -16132,17 +16132,18 @@ sub gl_data {
|
|||
if ($working[1]){
|
||||
# first grab the actual gl version
|
||||
# non free drivers like nvidia may only show their driver version info
|
||||
# $working[1] = '4.6 (Core Profile) Mesa 24.2.0-devel (git-92f0620dae)';
|
||||
# $working[1] = '4.5 (Compatibility Profile) Mesa 22.3.6';
|
||||
if ($working[1] =~ /^(\S+)(\s|$)/){
|
||||
push(@{$gl->{'glx'}{'opengl'}{'versions'}}, $1);
|
||||
}
|
||||
# handle legacy format: 1.2 (1.5 Mesa 6.5.1) as well as more current:
|
||||
# handle legacy format: 1.2 (1.5 Mesa 6.5.1)
|
||||
# as well as more current:
|
||||
# 4.5 (Compatibility Profile) Mesa 22.3.6
|
||||
# Note: legacy: fglrx starting adding compat strings but they don't
|
||||
# change this result:
|
||||
# 4.5 Compatibility Profile Context Mesa 15.3.6
|
||||
# 4.6 (Core Profile) Mesa 24.2.0-devel (git-92f0620dae)
|
||||
if ($working[1] =~ /(Mesa|NVIDIA)\s(\S+?)\)?(\s\([^\)]+\))?$/i){
|
||||
if ($working[1] =~ /(Mesa|NVIDIA)\s(\S+?)\)?(\s.*)?$/i){
|
||||
if ($1 && $2 && !$gl->{'glx'}{'opengl'}{'driver'}){
|
||||
$gl->{'glx'}{'opengl'}{'driver'}{'vendor'} = lc($1);
|
||||
$gl->{'glx'}{'opengl'}{'driver'}{'version'} = $2;
|
||||
|
@ -16161,9 +16162,9 @@ sub gl_data {
|
|||
}
|
||||
# eglinfo/glxinfo share these
|
||||
if ($b_opengl){
|
||||
# $working[0] = '4.6 (Core Profile) Mesa 24.2.0-devel (git-92f0620dae)';
|
||||
if ($working[0] =~ /^OpenGL (compatibility|core) profile version( string)?$/){
|
||||
$value = lc($1);
|
||||
# $working[1] = '4.6 (Core Profile) Mesa 24.2.0-devel (git-92f0620dae)';
|
||||
# note: no need to apply empty message here since we don't have the data
|
||||
# anyway
|
||||
if ($working[1]){
|
||||
|
@ -16175,7 +16176,7 @@ sub gl_data {
|
|||
# to communicate anything of value
|
||||
# 4.6 (Core Profile) Mesa 24.2.0-devel
|
||||
# 4.6 (Core Profile) Mesa 24.2.0-devel (git-92f0620dae)
|
||||
if ($working[1] =~ /\s+(Mesa|NVIDIA)\s+(\S+)(\s\([^\)]+\))?$/){
|
||||
if ($working[1] =~ /\s+(Mesa|NVIDIA)\s+(\S+)(\s.*)?$/){
|
||||
if ($1 && $2 && !$gl->{'glx'}{'opengl'}{$value}{'vendor'}){
|
||||
$gl->{'glx'}{'opengl'}{$value}{'driver'}{'vendor'} = lc($1);
|
||||
$gl->{'glx'}{'opengl'}{$value}{'driver'}{'version'} = $2;
|
||||
|
|
Loading…
Reference in a new issue