[Nix-dev] default options not working

Mathijs Kwik mathijs at bluescreen303.nl
Sun Dec 4 15:22:06 CET 2011


Hi all,

In my ~/.nixpkgs/config.nix I put:

{
  packageOverrides = pkgs:
  rec {
    mypkgs = pkgs.buildEnv {
      name = "mypkgs";
      paths = [
               ....
               samba
               ....
      ];
    };
    samba = pkgs.callPackage
../.nix-defexpr/nixpkgs_sys/pkgs/servers/samba {useKerberos = true; };
  };
}

installing with "nix-env -iA nixpkgs_sys.mypkgs" worked fine.
Problem is: it should fail!
The samba package requires a "kerberos" attribute when useKerberos is true.
It asserts on this.
changing the line in my file to

samba = pkgs.callPackage
../.nix-defexpr/nixpkgs_sys/pkgs/servers/samba {useKerberos = true;
kerberos = null;};

successfully hits the assertion and fails. The samba package has
{ kerberos ? null} in its function definition, so it should be null
when not set.
Why doesn't this work?

Thanks,
Mathijs


More information about the nix-dev mailing list