Skip to content
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

top-level: Deprecate top-level {build,host,target}Platform #46059

Conversation

Ericson2314
Copy link
Member

@Ericson2314 Ericson2314 commented Sep 4, 2018

OK @dezgeg, I'm starting with these since these are the ones we agree on. I'll backport to 18.09 too, if you approve of this.

Motivation for this change

I don't know when we can/should remove them, but this at least gets people to stop using them. The preferred alternatives also date back to 17.09 so writing forward-compatable code without extra conditions is easy.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • 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/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Fits CONTRIBUTING.md.

I don't know when we can/should remove them, but this at least gets
people to stop using them. The preferred alternatives also date back to
17.09 so writing forward-compatable code without extra conditions is
easy.

Beginning with these as they are the least controversial.
@Ericson2314 Ericson2314 force-pushed the deprecate-top-level-platform-aliases branch from 3ddf9ed to e51f736 Compare September 5, 2018 15:56
@Ericson2314
Copy link
Member Author

Crickets. I'll presume @dezgeg agrees with the spirit of these deprecations (i.e. stdenv.*Platform is better than *Platform, if not the actual emission of warnings.

Unlike the other ones, I created this interface, so I feel comfortable deprecating this myself. @edolstra mentioned cross compilation still being experimental in #45717 (comment). Well, I no longer wish for these top-level to be a "condoned" part of the experiment. (I will not remove them for 18.09, however.)

@Ericson2314 Ericson2314 merged commit 0af9072 into NixOS:master Sep 6, 2018
@Ericson2314 Ericson2314 deleted the deprecate-top-level-platform-aliases branch September 6, 2018 12:11
@Ericson2314 Ericson2314 added the 8.has: port to stable A PR already has a backport to the stable release. label Sep 6, 2018
@matthewbauer
Copy link
Member

matthewbauer commented Sep 7, 2018

This breaks tarball generation:

https://hydra.nixos.org/build/81023481/

@Ericson2314
Copy link
Member Author

Yeah see #46146 (comment) and following. I'm trying to think of what to do. I recall you once tried to the tarball job turn off alises? Maybe I should use that for this instead?

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

Successfully merging this pull request may close these issues.

None yet

3 participants