Author: amiddelk
Date: Thu Jan 12 17:17:01 2012
New Revision: 31502
URL: https://nixos.org/websvn/nix/?rev=31502&sc=1
Log:
Added an option to enable the firmware from 'firmware-linux-nonfree' and
'firmware-linux-free'.
Added:
nixos/trunk/modules/hardware/firmware-free.nix
nixos/trunk/modules/hardware/firmware-nonfree.nix
Modified:
nixos/trunk/modules/module-list.nix
Added: nixos/trunk/modules/hardware/firmware-free.nix
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ nixos/trunk/modules/hardware/firmware-free.nix Thu Jan 12 17:17:01
2012 (r31502)
@@ -0,0 +1,26 @@
+{pkgs, config, ...}:
+
+{
+
+ ###### interface
+
+ options = {
+
+ hardware.enableFirmwareLinuxFree = pkgs.lib.mkOption {
+ default = false;
+ type = pkgs.lib.types.bool;
+ description = ''
+ Turn on this option if you want the set of firmware of the
linux-firmware-free package.
+ '';
+ };
+
+ };
+
+
+ ###### implementation
+
+ config = pkgs.lib.mkIf config.hardware.enableFirmwareLinuxFree {
+ hardware.firmware = [ pkgs.firmwareLinuxFree ];
+ };
+
+}
Added: nixos/trunk/modules/hardware/firmware-nonfree.nix
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ nixos/trunk/modules/hardware/firmware-nonfree.nix Thu Jan 12 17:17:01
2012 (r31502)
@@ -0,0 +1,26 @@
+{pkgs, config, ...}:
+
+{
+
+ ###### interface
+
+ options = {
+
+ hardware.enableFirmwareLinuxNonfree = pkgs.lib.mkOption {
+ default = false;
+ type = pkgs.lib.types.bool;
+ description = ''
+ Turn on this option if you want the set of firmware of the non-free
package.
+ '';
+ };
+
+ };
+
+
+ ###### implementation
+
+ config = pkgs.lib.mkIf config.hardware.enableFirmwareLinuxNonfree {
+ hardware.firmware = [ pkgs.firmwareLinuxNonfree ];
+ };
+
+}
Modified: nixos/trunk/modules/module-list.nix
==============================================================================
--- nixos/trunk/modules/module-list.nix Thu Jan 12 17:16:11 2012 (r31501)
+++ nixos/trunk/modules/module-list.nix Thu Jan 12 17:17:01 2012 (r31502)
@@ -20,6 +20,8 @@
./hardware/network/rt73.nix
./hardware/network/rtl8192c.nix
./hardware/pcmcia.nix
+ ./hardware/firmware-nonfree.nix
+ ./hardware/firmware-free.nix
./installer/generations-dir/generations-dir.nix
./installer/grub/grub.nix
./installer/init-script/init-script.nix
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits