Skip to content

hardware: add enableRedistributalFirmware #25636

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 9, 2017
Merged

Conversation

Mic92
Copy link
Member

@Mic92 Mic92 commented May 9, 2017

Motivation for this change

Due the recent inclusion of broadcom-bt-firmware in enableAllFirmware,
it was required to set nixpkgs.config.allowUnfree to obtain the full
list. To make this dependency more explicit an assertion is added and an
alternative option enableRedistributalFirmware is provided to only
obtain firmware with an license allowing redistribution.

see #25567 for previous discussion.

Things done
  • Tested using sandboxing
    (nix.useSandbox on NixOS,
    or option build-use-sandbox in nix.conf
    on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • Linux
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

Sorry, something went wrong.

@Mic92 Mic92 added the 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS label May 9, 2017
@mention-bot
Copy link

@Mic92, thanks for your PR! By analyzing the history of the files in this pull request, we identified @amiddelk, @viric and @edolstra to be potential reviewers.

assertion = !cfg.enableAllFirmware || (config.nixpkgs.config.allowUnfree or false);
message = ''
the list of hardware.enableAllFirmware contains non-redistributable licensed firmware files.
This requires nixpkgs.config.allowUnfree to be true.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This indentation is intentional for nice multi-line bullet points.

'';
};

hardware.enableAllRedistributalFirmware = mkOption {
Copy link
Member

@Profpatsch Profpatsch May 9, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’d change the name to RedistributableFirmware.

default = false;
type = types.bool;
description = ''
Turn on this option if you want to enable all the firmware with a license allowing redistribution.
Copy link
Member

@Profpatsch Profpatsch May 9, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

… (i.e. free firmware and <literal>firmware-linux-nonfree</literal>)

@Mic92 Mic92 changed the title hardware: add enableAllRedistributalFirmware hardware: add enableRedistributalFirmware May 9, 2017
Due the recent inclusion of broadcom-bt-firmware in enableAllFirmware,
it was required to set `nixpkgs.config.allowUnfree` to obtain the full
list. To make this dependency more explicit an assertion is added and an
alternative option `enableRedistributalFirmware` is provided to only
obtain firmware with an license allowing redistribution.
@Mic92 Mic92 merged commit 5385a8e into NixOS:master May 9, 2017
@Mic92 Mic92 deleted the firmware branch May 9, 2017 14:57
@calvertvl
Copy link
Contributor

Minor gripe: Spelling

I think you meant Redistributable not Redistributal (which AFAICT is not a word)

@Mic92
Copy link
Member Author

Mic92 commented May 9, 2017

fixed in e697585.

@Profpatsch
Copy link
Member

Well, that was one of my two comments, which apparently went unnoticed. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants