Arch linux mesa libgl

Arch Linux

I have a computer which has nvidia card, I was using the proprietary driver .

I sometimes to need to switch my hard drive to a computer which has intel graphics integrated, I only managed to make sddm work when I replaced nvidia-340xx with xf86-video-intel and replace nvidia-340xx-libgl with mesa-libgl.

Unfortunately mesa-libgl and nvidia-340xx-libgl can’t coexist.

So is there some way to install xf86-video-intel and nvidia and nvidia-340xx-libgl and mesa-libgl together and configure X to use what’s proper ?

Last edited by niceman (2015-09-24 17:49:46)

#2 2015-09-23 21:15:24

Re: how to have both mesa-libgl and nvidia-libgl packages installed

You can have both packages in the cache and run a script to toggle (install) them.

#3 2015-09-23 22:02:28

Re: how to have both mesa-libgl and nvidia-libgl packages installed

Moving from Kernel & Hardware to Applications & Desktop Environments.

#4 2015-09-23 22:29:35

Re: how to have both mesa-libgl and nvidia-libgl packages installed

You might want to revise the title as this doesn’t seem to be about getting X to use whatever card it finds — it will do that by default. Your only problem is that you need to have conflicting packages installed in order to use the proprietary drivers.

Unless you follow Karol’s suggestion, you might need to settle for open source drivers for nvidia, or a fallback for intel (like fbdev).

«UNIX is simple and coherent. » — Dennis Ritchie, «GNU’s Not UNIX» — Richard Stallman

#5 2015-09-24 17:51:54

Re: how to have both mesa-libgl and nvidia-libgl packages installed

You might want to revise the title as this doesn’t seem to be about getting X to use whatever card it finds — it will do that by default. Your only problem is that you need to have conflicting packages installed in order to use the proprietary drivers.

Unless you follow Karol’s suggestion, you might need to settle for open source drivers for nvidia, or a fallback for intel (like fbdev).

I’ll try Karol’s suggestion later, but how would fbdev(framebuffer video driver) solve the problem ?

#6 2015-09-24 18:46:34

Re: how to have both mesa-libgl and nvidia-libgl packages installed

What do you mean? You can use fbdev and not install the intel driver. There would then be no problem to solve.

Читайте также:  Логотип операционной системы линукс

«UNIX is simple and coherent. » — Dennis Ritchie, «GNU’s Not UNIX» — Richard Stallman

#7 2015-09-24 19:10:32

Re: how to have both mesa-libgl and nvidia-libgl packages installed

What do you mean? You can use fbdev and not install the intel driver. There would then be no problem to solve.

But you would also be without any kind of acceleration. Not a good trade-off. Though when it comes to X drivers, there’s no problem whatsoever anyway — the nvidia and intel X drivers can co-exist just fine and neither rely on opengl for acceleration (nvidia has it’s own built-in render accel, intel has SNA and UXA).

The problem is opengl. You can only have one set of gl libs, that’s why the nvidia-libgl and mesa-libgl packages that can’t coexist. There is no solution here, just the workaround karol mentions. There is something in the works by Nvidia which allows multiple gl libs to coexist — libglvnd. But who knows when, if ever, it’ll get adopted.

#8 2015-09-27 10:18:35

Re: how to have both mesa-libgl and nvidia-libgl packages installed

What do you mean? You can use fbdev and not install the intel driver. There would then be no problem to solve.

But you would also be without any kind of acceleration. Not a good trade-off. Though when it comes to X drivers, there’s no problem whatsoever anyway — the nvidia and intel X drivers can co-exist just fine and neither rely on opengl for acceleration (nvidia has it’s own built-in render accel, intel has SNA and UXA).

The problem is opengl. You can only have one set of gl libs, that’s why the nvidia-libgl and mesa-libgl packages that can’t coexist. There is no solution here, just the workaround karol mentions. There is something in the works by Nvidia which allows multiple gl libs to coexist — libglvnd. But who knows when, if ever, it’ll get adopted.

Well I’m using KDE which needs opengl I suppose.

I think I’ll go with the manual uninstall and install, thanks anyway.

But I’m interested in libglvnd , it says that EGL and opengl ES is not implemented but I don’t need them as I use GLX(right?), So install it and that will be it ?

EDIT: seeing that the library won’t deallocate means I can’t use it yet in production, I think I’m going manually until the work on libglvnd finishes

Last edited by niceman (2015-09-27 10:24:54)

Источник

mesa on Arch Linux

This tutorial shows how to install mesa package:

2. Uninstall / Remove mesa package

Here is a brief guide to show you how to uninstall mesa package:

3. Details of mesa package

Repository : extra
Name : mesa
Version : 22.1.7-1
Description : An open-source implementation of the OpenGL specification
Architecture : x86_64
URL : https://www.mesa3d.org/
Licenses : custom
Groups : None
Provides : mesa-libgl opengl-driver
Depends On : libdrm wayland libxxf86vm libxdamage libxshmfence libelf
libomxil-bellagio libunwind llvm-libs lm_sensors libglvnd
zstd vulkan-icd-loader libsensors.so=5-64 libexpat.so=1-64
libvulkan.so=1-64
Optional Deps : opengl-man-pages: for the OpenGL API man pages
mesa-vdpau: for accelerated video playback
libva-mesa-driver: for accelerated video playback
Conflicts With : mesa-libgl
Replaces : mesa-libgl
Download Size : 12.60 MiB
Installed Size : 72.32 MiB
Packager : Laurent Carlier
Build Date : Thu Aug 18 11:43:52 2022
Validated By : MD5 Sum SHA-256 Sum Signature

Читайте также:  Linux mounting read write and

4. References on Arch Linux

5. The same packages on other Linux Distributions

Mesa (20.2.4-57.13) openSUSE Leap

Mesa (21.3.1-295.1) openSuSE Tumbleweed

Источник

OpenGL

OpenGL (Open Graphics Library) is a cross-language, cross-platform application programming interface (API) for rendering 2D and 3D vector graphics.

Development of OpenGL ceased in 2017 in favour of Vulkan, the «next generation» API which offers higher performance on newer hardware.

Installation

To run applications that use OpenGL, you will need to install the correct driver(s) for your hardware (either GPUs or CPUs).

  • For AMD (and ATI) it is recommended to use the open-source drivers unless you have a strong reason to use the proprietary ones.
  • For NVIDIA, the proprietary driver is recommended for cards newer than the Kepler (NVE0/GKXXX) series, and/or better performance in general.
  • Intel’s GenN hardware does not refer to the generation of the CPU, it refers to the generation of the GPU, which is different from the generation of the CPU.
  • To find the family of an AMD (and ATI) GPU, check Wikipedia:List of AMD graphics processing units#Features overview
  • To find the code-name of an NVIDIA GPU, check the code-name list from the Nouveau project

Mesa is an open-source OpenGL implementation, continually updated to support the latest OpenGL specification. It has a collection of open-source drivers for Intel graphics, AMD (formerly ATI) and NVIDIA GPUs. Mesa also provides software rasterizers, such as llvmpipe.

There are two Mesa packages, each with a distinct set of drivers:

  • mesa is the up-to-date Mesa package which includes most of the modern drivers for newer hardware:
    • r300 : for AMD’s Radeon R300, R400, and R500 GPUs.
    • r600 : for AMD’s Radeon R600 GPUs up to Northern Islands. Officially supported by AMD.
    • radeonsi : for AMD’s Southern Island GPUs and later. Officially supported by AMD.
    • nouveau : Nouveau is the open-source driver for NVIDIA GPUs.
    • virtio_gpu : a virtual GPU driver for virtio, can be used with QEMU based VMMs (like KVM or Xen).
    • vmwgfx : for VMware virtual GPUs.
    • i915 : for Intel’s Gen 3 hardware.
    • crocus : for Intel’s Gen 4 to Gen 7 hardware.
    • iris : for Intel’s Gen 8 hardware and later. Officially supported by Intel.
    • zink : a Gallium driver used to run OpenGL on top of Vulkan.
    • d3d12 : for OpenGL 3.3 support on devices that only support D3D12 (i.e. WSL).
    • swrast : a legacy software rasterizer.
    • softpipe : a software rasterizer and a reference Gallium driver.
    • llvmpipe : a software rasterizer which uses LLVM for x86 JIT code generation and is multi-threaded.
    • mesa-amber is the legacy Mesa package which includes the classic (non-Gallium3D) drivers for older hardware:
      • i830 : for Intel’s Gen 2 hardware. Same binary as i965 .
      • i915 : for Intel’s Gen 3 hardware. Same binary as i965 .
      • i965 : for Intel’s Gen 4 hardware and later. Officially supported by Intel.
      • radeon : for AMD’s Radeon R100 GPUs. Same binary as r200 .
      • r200 : for AMD’s Radeon R200 GPUs.
      • nouveau_vieux : for NVIDIA NV04 (Fahrenheit) to NV20 (Kelvin) GPUs.
      • swrast : a legacy software rasterizer.

      Note: When using Mesa, the correct driver should be selected automatically, thus no configuration is needed once the package is installed.

      • nvidia-utils is the proprietary driver for NVIDIA GPUs, which includes an OpenGL implementation.
      • amdgpu-pro-oglpAUR is the proprietary driver for AMD GPUs.

      Verification

      To verify your OpenGL installation, you can use mesa-utils glxinfo , which should display output like this (with different values depending on your setup, of course):

      OpenGL vendor string: X.Org OpenGL renderer string: AMD RV620 (DRM 2.50.0 / 5.10.12-arch1-1, LLVM 11.0.1) OpenGL core profile version string: 3.3 (Core Profile) Mesa 20.3.4 OpenGL core profile shading language version string: 3.30 OpenGL core profile context flags: (none) OpenGL core profile profile mask: core profile OpenGL core profile extensions: OpenGL version string: 3.0 Mesa 20.3.4 OpenGL shading language version string: 1.30 OpenGL context flags: (none) OpenGL extensions: OpenGL ES profile version string: OpenGL ES 3.0 Mesa 20.3.4 OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.00 OpenGL ES profile extensions:

      From the same package, you can also use glxgears as a basic OpenGL test. You should see 3 rotating gears when running the program.

      Switching between drivers

      Note: According to this Reddit post, you can use 2 GPUs from different vendors working at the same time using PRIME without any problems.

      Mesa

      You can override the driver used for an application with the following environment variable:

      MESA_LOADER_DRIVER_OVERRIDE=driver 

      By default, Mesa searches for drivers in /lib/dri/ . You can view the list of installed drivers with

      driver in driver_dri.so is the actual name of the driver. If Mesa failed to find the specified driver, it will fall back to llvmpipe .

      You can also use an OpenGL software rasterizer by setting the following environment variables:

      LIBGL_ALWAYS_SOFTWARE=true GALLIUM_DRIVER=driver 

      driver can be either softpipe , llvmpipe , or swr .

      OpenGL over Vulkan (Zink)

      The Zink driver is a Gallium driver that emits Vulkan API calls instead of targeting a specific GPU architecture. This can be used to get full desktop OpenGL support on devices that only support Vulkan.

      If you are experiencing issues in your default OpenGL drivers (a bug in RadeonSI, Iris, etc.), you could try using the Zink driver.

      According to this Phoronix benchmark, the average FPS might be lower in some applications compared to RadeonSI.

      To use Zink on NVIDIA drivers, use this command or similar:

      $ env __GLX_VENDOR_LIBRARY_NAME=mesa MESA_LOADER_DRIVER_OVERRIDE=zink GALLIUM_DRIVER=zink application 

      Development

      Note: This section is for developers who want to use OpenGL in projects. End users should not need anything from this section.

      Using OpenGL in code requires functions loader, read more at Khronos.

      This article or section needs expansion.

      OpenGL Hardware Database

      GPUInfo provides user reported GPU/driver combinations, supported extensions, capabilities, etc. This information is useful for verifying compatibility / compliance of particular hardware under both OpenGL and Vulkan.

      Источник

Оцените статью
Adblock
detector