diff options
Diffstat (limited to 'pkgs/development/libraries/mesa')
-rw-r--r-- | pkgs/development/libraries/mesa/generic.nix | 9 | ||||
-rw-r--r-- | pkgs/development/libraries/mesa/stubs.nix | 12 |
2 files changed, 17 insertions, 4 deletions
diff --git a/pkgs/development/libraries/mesa/generic.nix b/pkgs/development/libraries/mesa/generic.nix index 0217391fe02..82055ecd342 100644 --- a/pkgs/development/libraries/mesa/generic.nix +++ b/pkgs/development/libraries/mesa/generic.nix @@ -1,6 +1,6 @@ { version, hash }: -{ stdenv, lib, fetchurl +{ stdenv, lib, fetchurl, fetchpatch , meson, pkg-config, ninja , intltool, bison, flex, file, python3Packages, wayland-scanner , expat, libdrm, xorg, wayland, wayland-protocols, openssl @@ -133,6 +133,13 @@ self = stdenv.mkDerivation { ./opencl.patch ./disk_cache-include-dri-driver-path-in-cache-key.patch + + # FIXME: submitted upstream at https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22133 + # Remove when no longer applicable + (fetchpatch { + url = "https://gitlab.freedesktop.org/mesa/mesa/-/commit/1457f1b752f59258c0b33558619b0063b4ce6280.diff"; + hash = "sha256-WFemyfmCWY4rJMfGxVZdYeGQvGcOTEDMrRt5OIWp348="; + }) ]; postPatch = '' diff --git a/pkgs/development/libraries/mesa/stubs.nix b/pkgs/development/libraries/mesa/stubs.nix index f3ea263cc9f..773897548a4 100644 --- a/pkgs/development/libraries/mesa/stubs.nix +++ b/pkgs/development/libraries/mesa/stubs.nix @@ -1,12 +1,13 @@ { stdenv -, libglvnd, mesa +, libglvnd +, mesa , OpenGL , testers }: stdenv.mkDerivation (finalAttrs: { - inherit (libglvnd) version; pname = "libGL"; + inherit (if stdenv.hostPlatform.isDarwin then mesa else libglvnd) version; outputs = [ "out" "dev" ]; # On macOS, libglvnd is not supported, so we just use what mesa @@ -77,5 +78,10 @@ stdenv.mkDerivation (finalAttrs: { passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; - meta.pkgConfigModules = [ "gl" "egl" "glesv1_cm" "glesv2" ]; + meta = { + description = "Stub bindings using " + (if stdenv.hostPlatform.isDarwin then "mesa" else "libglvnd"); + pkgConfigModules = [ "gl" "egl" "glesv1_cm" "glesv2" ]; + } // { + inherit (if stdenv.hostPlatform.isDarwin then mesa.meta else libglvnd.meta) homepage license platforms; + }; }) |