Skip to content

Using self prevent aliasing overriden packages#18483

Merged
domenkozar merged 1 commit intoNixOS:masterfrom
nbp:revert-14398
Sep 12, 2016
Merged

Using self prevent aliasing overriden packages#18483
domenkozar merged 1 commit intoNixOS:masterfrom
nbp:revert-14398

Conversation

@nbp
Copy link
Member

@nbp nbp commented Sep 10, 2016

This changes are reverting #14398 as self. refers to the all-packages.nix set instead of the fix-point including the overriden packages.

Apparently, it seems that people used to rely on aliases as dependencies, and expected that overriding a package (which never got specified) should override all aliases of it. (#18316)

This implies that we would have to find another solution for aliases (#10851) , such that we can do a fix-point on aliases before we use the aliases as dependencies. Note, aliases are supposed to be at the same evaluation depth as the package that they alias, otherwise the security model would leak unpatched versions of the packages.

I will note, that this revert include additional removal of self. from the derivations/arguments of a few packages which are embedded in all-packages.nix. Using self. is similar to hard-linking and should be avoided as this would cause extra recompilations.

@domenkozar @edolstra

@domenkozar domenkozar merged commit 5ecb8b0 into NixOS:master Sep 12, 2016
@domenkozar
Copy link
Member

We should do the same for 16.09

@domenkozar
Copy link
Member

@nbp do I understand correctly, all self references should be removed for now?

@nbp
Copy link
Member Author

nbp commented Sep 12, 2016

@domenkozar

do I understand correctly, all self references should be removed for now?

As long as they don't change the hashes, yes. Using self by-pass the fix-point by doing a fix-point within the all-packages.nix file.

Unfortunately, this is not something as trivial as a sed, as this is an highly overloaded name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants