From 4bff6d04e44c0bf19c7a0975f882883ba2212a6a Mon Sep 17 00:00:00 2001 From: Gabriel Ebner Date: Sun, 4 Apr 2021 16:50:17 +0200 Subject: [PATCH] libGL: use headers from glvnd The glvnd library contains a copy of the OpenGL headers. By compiling against the glvnd headers we completely avoid a dependency on Mesa (and LLVM). This reduces rebuild time. It also prevents accidents, such as where some packages kept a reference to the mesa.drivers output and thus had all Mesa drivers in their runtime closure. --- pkgs/development/libraries/mesa/stubs.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/mesa/stubs.nix b/pkgs/development/libraries/mesa/stubs.nix index a53f2dc28e7..753ad1b9196 100644 --- a/pkgs/development/libraries/mesa/stubs.nix +++ b/pkgs/development/libraries/mesa/stubs.nix @@ -52,7 +52,7 @@ stdenv.mkDerivation { mkdir -p $dev/{,lib/pkgconfig,nix-support} echo "$out ${libglvnd} ${libglvnd.dev}" > $dev/nix-support/propagated-build-inputs - ln -s ${mesa.dev}/include $dev/include + ln -s ${libglvnd.dev}/include $dev/include genPkgConfig() { local name="$1" @@ -61,9 +61,9 @@ stdenv.mkDerivation { cat <$dev/lib/pkgconfig/$name.pc Name: $name Description: $lib library - Version: ${mesa.version} + Version: ${libglvnd.version} Libs: -L${libglvnd.out}/lib -l$lib - Cflags: -I${mesa.dev}/include -I${libglvnd.dev}/include + Cflags: -I${libglvnd.dev}/include EOF }