bumblebee: backport critical libkmod.patch

This commit is contained in:
Alex Ivanov 2016-10-30 20:47:13 +03:00
parent b65c443276
commit 1cb54a7dd0

View file

@ -20,6 +20,7 @@
, glib, libbsd
, libX11, libXext, xorgserver, xkbcomp, kmod, xkeyboard_config, xf86videonouveau
, nvidia_x11, virtualgl, primusLib
, automake111x, autoconf
# The below should only be non-null in a x86_64 system. On a i686
# system the above nvidia_x11 and virtualgl will be the i686 packages.
# TODO: Confusing. Perhaps use "SubArch" instead of i686?
@ -48,6 +49,15 @@ let
xmodules = lib.concatStringsSep "," (map (x: "${x.out or x}/lib/xorg/modules") ([ xorgserver ] ++ lib.optional (!useNvidia) xf86videonouveau));
modprobePatch = fetchurl {
url = "https://github.com/Bumblebee-Project/Bumblebee/commit/1ada79fe5916961fc4e4917f8c63bb184908d986.patch";
sha256 = "0x9qvhw6sn606dqcp3394irj6jjhw3h75k3lpbys6gha1yshgjps";
};
libkmodPatch = fetchurl {
url = "https://github.com/Bumblebee-Project/Bumblebee/commit/deceb14cdf2c90ff64ebd1010a674305464587da.patch";
sha256 = "0j2v0lncjfn2nw3324q3n69lw3yz3hah6bscc8xn9a2df2dcawj1";
};
in stdenv.mkDerivation rec {
name = "bumblebee-${version}";
@ -56,7 +66,12 @@ in stdenv.mkDerivation rec {
sha256 = "03p3gvx99lwlavznrpg9l7jnl1yfg2adcj8jcjj0gxp20wxp060h";
};
patches = [ ./nixos.patch ];
patches = [
./nixos.patch
modprobePatch
libkmodPatch
];
# By default we don't want to use a display device
nvidiaDeviceOptions = lib.optionalString (!useDisplayDevice) ''
@ -96,7 +111,8 @@ in stdenv.mkDerivation rec {
# Build-time dependencies of bumblebeed and optirun.
# Note that it has several runtime dependencies.
buildInputs = [ libX11 glib libbsd ];
buildInputs = [ libX11 glib libbsd ]
++ [ kmod automake111x autoconf ];
nativeBuildInputs = [ makeWrapper pkgconfig help2man ];
# The order of LDPATH is very specific: First X11 then the host