Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Conflict of version for DRI driver #20

Open
NicsTr opened this issue Apr 28, 2024 · 3 comments
Open

[BUG] Conflict of version for DRI driver #20

NicsTr opened this issue Apr 28, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@NicsTr
Copy link

NicsTr commented Apr 28, 2024

Describe the bug

When launching any application using mesa from alacritty, I get the following error message: DRI driver not from this Mesa build ('23.2.1-1ubuntu3.1~22.04.2' vs '24.0.5-1ubuntu1').

When I install alacritty through cargo install alacritty everything works as expected.

To Reproduce

Steps to reproduce the behavior:

  1. Install alacritty from snap (snap install alacritty --classic)
  2. Launch an alacritty terminal
  3. Run glxinfo from this terminal
  4. See error

Expected behavior

No error should occur.

Environment (please complete the following information):

  • OS: Ubuntu 24.04
  • Alacritty Version: 0.13.2
  • Graphics Cards: AMD Ryzen 7 7840U w/ Radeon 780M Graphics

Additional context

Shell output:

$ glxinfo
name of display: :0
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
using driver amdgpu for 4
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
pci id for fd 4: 1002:15bf, driver radeonsi
MESA-LOADER: dlopen(/snap/alacritty/125/usr/lib/x86_64-linux-gnu/dri/radeonsi_dri.so)
DRI driver not from this Mesa build ('23.2.1-1ubuntu3.1~22.04.2' vs '24.0.5-1ubuntu1')
failed to load driver: radeonsi
using driver amdgpu for 4
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
pci id for fd 4: 1002:15bf, driver radeonsi
MESA-LOADER: dlopen(/snap/alacritty/125/usr/lib/x86_64-linux-gnu/dri/radeonsi_dri.so)
DRI driver not from this Mesa build ('23.2.1-1ubuntu3.1~22.04.2' vs '24.0.5-1ubuntu1')
failed to load driver: radeonsi
MESA-LOADER: dlopen(/snap/alacritty/125/usr/lib/x86_64-linux-gnu/dri/swrast_dri.so)
did not find extension DRI_Kopper version 1
DRI driver not from this Mesa build ('23.2.1-1ubuntu3.1~22.04.2' vs '24.0.5-1ubuntu1')
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  152 (GLX)
  Minor opcode of failed request:  24 (X_GLXCreateNewContext)
  Value in failed request:  0x0
  Serial number of failed request:  54
  Current serial number in output stream:  55

LIBGL_DEBUG output (only if you have graphics related issue):

$ LIBGL_DEBUG=verbose alacritty
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
libGL: using driver amdgpu for 21
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
libGL: pci id for fd 21: 1002:15bf, driver radeonsi
libGL: MESA-LOADER: dlopen(/snap/alacritty/125/usr/lib/x86_64-linux-gnu/dri/radeonsi_dri.so)
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
libGL: Can't open configuration file /etc/drirc: No such file or directory.
libGL: Can't open configuration file /home/username/.drirc: No such file or directory.
/usr/share/libdrm/amdgpu.ids version: 1.0.0
libGL: Using DRI3 for screen 0
@NicsTr NicsTr added the bug Something isn't working label Apr 28, 2024
@VasilisManol
Copy link

The same error comes in Ubuntu 23.10 with output:
libGL error: DRI driver not from this Mesa build ('23.2.1-1ubuntu3.1~22.04.2' vs '23.2.1-1ubuntu3.1')

@georgeyk
Copy link

Also reported in #27
I've found by accident that the command would run with sudo, and normally in the "system" terminal.
After digging a bit, I found that LIBGL_DRIVERS_PATH and LIBVA_DRIVERS_PATH was set to the "snap" path (/snap/alacritty/ ...), so I just reset it inline when running glxgears (or any app that needs it).
I'm largely unfamiliar to snap packaging, but I hope it helps to fix this.

@Gooygeek
Copy link

I can confirm these environment variables are to blame.
By unsetting them or by setting them to the system installation, gui apps (e.g. glxgears) can be launched.

I've added the following to my .zshrc:

export LIBGL_DRIVERS_PATH="/usr/lib/x86_64-linux-gnu/dri"
export LIBVA_DRIVERS_PATH="/usr/lib/x86_64-linux-gnu/dri"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants