diff options
author | Alyssa <hi@alyssa.is> | 2019-04-18 14:25:42 +0200 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2019-04-23 10:04:20 +0000 |
commit | 61b5213c1610ec3a4f0322e61fc6cd4c61807a8d (patch) | |
tree | e3a238290bd1c462dbdaef913861f757ad9053b5 /nixpkgs/pkgs/development/libraries/mesa | |
parent | 38b51d781543ff8ecbf81d4b45320ee1c413f85c (diff) | |
download | nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar.gz nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar.bz2 nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar.lz nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar.xz nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.tar.zst nixlib-61b5213c1610ec3a4f0322e61fc6cd4c61807a8d.zip |
mesa: make libglvnd support optional
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/mesa')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/mesa/default.nix | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/nixpkgs/pkgs/development/libraries/mesa/default.nix b/nixpkgs/pkgs/development/libraries/mesa/default.nix index 5c17901faaed..6c11a0c3ab1c 100644 --- a/nixpkgs/pkgs/development/libraries/mesa/default.nix +++ b/nixpkgs/pkgs/development/libraries/mesa/default.nix @@ -3,7 +3,6 @@ , file, expat, zlib, xorg, wayland, wayland-protocols, openssl , libffi , valgrind-light, python2, python2Packages -, libglvnd , enableRadv ? stdenv.isLinux , galliumDrivers ? null , driDrivers ? null @@ -17,6 +16,7 @@ , libdrmSupport ? stdenv.isLinux, libdrm , libelfSupport ? stdenv.isLinux, libelf , llvmSupport ? true, llvmPackages +, libglvndSupport ? true, libglvnd , OpenGL, Xplugin }: @@ -161,7 +161,7 @@ let self = stdenv.mkDerivation { # Direct3D in Wine (enableFeature (any (d: d != "swrast") galliumDrivers) "nine") - "--enable-libglvnd" + (enableFeature libglvndSupport "libglvnd") "--enable-dri" "--enable-driglx-direct" "--enable-gles1" @@ -202,7 +202,8 @@ let self = stdenv.mkDerivation { ++ optional libdrmSupport libdrm ++ optionals stdenv.isDarwin [ OpenGL Xplugin ]; - buildInputs = [ expat zlib libglvnd ] + buildInputs = [ expat zlib ] + ++ optional libglvndSupport libglvnd ++ optional llvmSupport llvmPackages.llvm ++ optional libelfSupport libelf ++ optionals (elem "wayland" eglPlatforms) [ wayland wayland-protocols ] @@ -233,9 +234,6 @@ let self = stdenv.mkDerivation { # Some installs don't have any drivers so this directory is never created. mkdir -p $drivers '' + optionalString (galliumDrivers != []) '' - # Move other drivers to a separate output - mv $out/lib/lib*_mesa* $drivers/lib - # move libOSMesa to $osmesa, as it's relatively big mkdir -p {$osmesa,$drivers}/lib/ mv -t $osmesa/lib/ $out/lib/libOSMesa* @@ -278,6 +276,9 @@ let self = stdenv.mkDerivation { '' + optionalString (vulkanDrivers != []) '' # move gallium-related stuff to $drivers, so $out doesn't depend on LLVM mv $out/lib/libvulkan_* $drivers/lib + '' + optionalString libglvndSupport '' + # Move other drivers to a separate output + mv $out/lib/lib*_mesa* $drivers/lib ''; # TODO: |