···
72
-
default = cfg.mesaPackage;
description = lib.mdDoc ''
The package that provides the OpenGL implementation.
76
-
The default is Mesa's drivers which should cover all OpenGL-capable
77
-
hardware. If you want to use another Mesa version, adjust
78
-
{option}`mesaPackage`.
84
-
default = cfg.mesaPackage32;
description = lib.mdDoc ''
86
-
Same as {option}`package` but for the 32-bit OpenGL implementation on
87
-
64-bit systems. Used when {option}`driSupport32Bit` is set.
81
+
The package that provides the 32-bit OpenGL implementation on
82
+
64-bit systems. Used when {option}`driSupport32Bit` is
91
-
mesaPackage = mkOption {
92
-
type = types.package;
93
-
default = pkgs.mesa;
94
-
defaultText = literalExpression "pkgs.mesa";
95
-
example = literalExpression "pkgs.mesa_22";
96
-
description = lib.mdDoc ''
97
-
The Mesa driver package used for rendering support on the system.
99
-
You should only need to adjust this if you require a newer Mesa
100
-
version for your hardware or because you need to patch a bug.
102
-
apply = mesa: mesa.drivers or (throw "`mesa` package must have a `drivers` output.");
104
-
mesaPackage32 = mkOption {
105
-
type = types.package;
106
-
default = pkgs.pkgsi686Linux.mesa;
107
-
defaultText = literalExpression "pkgs.pkgsi686Linux.mesa";
108
-
example = literalExpression "pkgs.pkgsi686Linux.mesa_22";
109
-
description = lib.mdDoc ''
110
-
Same as {option}`mesaPackage` but for the 32-bit Mesa on 64-bit
111
-
systems. Used when {option}`driSupport32Bit` is set.
113
-
apply = mesa: mesa.drivers or (throw "`mesa` package must have a `drivers` output.");
extraPackages = mkOption {
type = types.listOf types.package;
···
extraPackages32 = mkOption {
type = types.listOf types.package;
···
environment.sessionVariables.LD_LIBRARY_PATH = mkIf cfg.setLdLibraryPath
([ "/run/opengl-driver/lib" ] ++ optional cfg.driSupport32Bit "/run/opengl-driver-32/lib");
156
+
hardware.opengl.package = mkDefault pkgs.mesa.drivers;
157
+
hardware.opengl.package32 = mkDefault pkgs.pkgsi686Linux.mesa.drivers;
boot.extraModulePackages = optional (elem "virtualbox" videoDrivers) kernelPackages.virtualboxGuestAdditions;