{"action":"created","issue":{"url":"https://api.github.com/repos/NixOS/nixpkgs/issues/16052","repository_url":"https://api.github.com/repos/NixOS/nixpkgs","labels_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/16052/labels{/name}","comments_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/16052/comments","events_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/16052/events","html_url":"https://github.com/NixOS/nixpkgs/pull/16052","id":159001215,"number":16052,"title":"Rust and cargo improvements","user":{"login":"dvc94ch","id":741807,"avatar_url":"https://avatars.githubusercontent.com/u/741807?v=3","gravatar_id":"","url":"https://api.github.com/users/dvc94ch","html_url":"https://github.com/dvc94ch","followers_url":"https://api.github.com/users/dvc94ch/followers","following_url":"https://api.github.com/users/dvc94ch/following{/other_user}","gists_url":"https://api.github.com/users/dvc94ch/gists{/gist_id}","starred_url":"https://api.github.com/users/dvc94ch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dvc94ch/subscriptions","organizations_url":"https://api.github.com/users/dvc94ch/orgs","repos_url":"https://api.github.com/users/dvc94ch/repos","events_url":"https://api.github.com/users/dvc94ch/events{/privacy}","received_events_url":"https://api.github.com/users/dvc94ch/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/NixOS/nixpkgs/labels/2.status:%20work-in-progress","name":"2.status: work-in-progress","color":"e6e6e6"},{"url":"https://api.github.com/repos/NixOS/nixpkgs/labels/6.topic:%20rust","name":"6.topic: rust","color":"fef2c0"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":14,"created_at":"2016-06-07T19:11:40Z","updated_at":"2016-06-15T11:13:18Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/NixOS/nixpkgs/pulls/16052","html_url":"https://github.com/NixOS/nixpkgs/pull/16052","diff_url":"https://github.com/NixOS/nixpkgs/pull/16052.diff","patch_url":"https://github.com/NixOS/nixpkgs/pull/16052.patch"},"body":"###### Motivation for this change\r\n- Enable cross-compiling std crates\r\n- Prepare for the 1.10.0 release when we can bootstrap from release tarball\r\n- Update cargo and use release tarball\r\n- Add scripts to fetch release tarball hashes for supported platforms\r\n\r\nTo try out rust on arm (depends on https://github.com/NixOS/nixpkgs/pull/15867):\r\n```nix\r\nwith import <nixpkgs> {};\r\n\r\nlet\r\n  pkgs = import ../../../nixpkgs;\r\n  pkgsNative = pkgs {};\r\n  pkgsCross = pkgs {\r\n    inherit system;\r\n    inherit crossSystem;\r\n  };\r\n  crossSystem = rec {\r\n    config = \"arm-linux-gnueabihf\";\r\n    bigEndian = false;\r\n    arch = \"arm\";\r\n    float = \"hard\";\r\n    fpu = \"vfpv3-d16\";\r\n    withTLS = true;\r\n    libc = \"glibc\";\r\n    platform = platforms.armv7l-hf-multiplatform;\r\n    openssl.system = \"linux-generic32\";\r\n    inherit (platform) gcc;\r\n  };\r\n  rustc = pkgsNative.rustc.override {\r\n    targets = [\"armv7-unknown-linux-gnueabihf\"];\r\n    targetToolchains = [pkgsCross.gccCrossStageFinal];\r\n  };\r\n  cargo = pkgsNative.cargo.override {\r\n    inherit rustc;\r\n  };\r\nin\r\nstdenv.mkDerivation rec {\r\n    name = \"arm-hello\";\r\n\r\n    buildInputs = [ cargo pkgsCross.gccCrossStageFinal qemu ];\r\n\r\n    shellHook = ''\r\n        PS1=\"rust-arm> \"\r\n        alias build=\"cargo build --target=${rustc.target}\"\r\n        alias run-debug=\"qemu-arm target/${rustc.target}/debug/${name}\"\r\n        alias run-release=\"qemu-arm target/${rustc.target}/release/${name}\"\r\n    '';\r\n}\r\n```\r\n###### Things done\r\n\r\n- [ ] Tested using sandboxing\r\n  ([nix.useSandbox](http://nixos.org/nixos/manual/options.html#opt-nix.useSandbox) on NixOS,\r\n    or option `build-use-sandbox` in [`nix.conf`](http://nixos.org/nix/manual/#sec-conf-file)\r\n    on non-NixOS)\r\n- Built on platform(s)\r\n   - [x] NixOS\r\n   - [ ] OS X\r\n   - [ ] Linux\r\n- [x] Tested compilation of all pkgs that depend on this change using `nix-shell -p nox --run \"nox-review wip\"`\r\n- [x] Tested execution of all binary files (usually in `./result/bin/`)\r\n- [x] Fits [CONTRIBUTING.md](https://github.com/NixOS/nixpkgs/blob/master/.github/CONTRIBUTING.md).\r\n\r\n---\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/NixOS/nixpkgs/issues/comments/226157733","html_url":"https://github.com/NixOS/nixpkgs/pull/16052#issuecomment-226157733","issue_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/16052","id":226157733,"user":{"login":"the-kenny","id":31167,"avatar_url":"https://avatars.githubusercontent.com/u/31167?v=3","gravatar_id":"","url":"https://api.github.com/users/the-kenny","html_url":"https://github.com/the-kenny","followers_url":"https://api.github.com/users/the-kenny/followers","following_url":"https://api.github.com/users/the-kenny/following{/other_user}","gists_url":"https://api.github.com/users/the-kenny/gists{/gist_id}","starred_url":"https://api.github.com/users/the-kenny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/the-kenny/subscriptions","organizations_url":"https://api.github.com/users/the-kenny/orgs","repos_url":"https://api.github.com/users/the-kenny/repos","events_url":"https://api.github.com/users/the-kenny/events{/privacy}","received_events_url":"https://api.github.com/users/the-kenny/received_events","type":"User","site_admin":false},"created_at":"2016-06-15T11:13:18Z","updated_at":"2016-06-15T11:13:18Z","body":"Ugh, non-determinism in `fetchgit` isn't good. It pulls quite a bunch of submodules (I think), maybe it's related to that?"}}
{"actor":{"display_login":"the-kenny"}}