nixpkgs/pkgs/build-support
Ricardo M. Correia 2b694c237b cargo, cargoSnapshot: add rustc runtime dependency
It turns out that cargo implicitly depends on rustc at runtime: even
`cargo help` will fail if rustc is not in the PATH.

This means that we need to wrap the cargo binary to add rustc to PATH.
However, I have opted into doing something slightly unusual: instead of
tying down a specific cargo to use a specific rustc (i.e., wrap cargo so
that "${rustc}/bin" is prefixed into PATH), instead I'm adding the rustc
used to build cargo as a fallback rust compiler (i.e., wrap cargo so
that "${rustc}/bin" is suffixed into PATH). This means that cargo will
prefer to use a rust compiler that is in the default path, but fallback
into the one used to build cargo only if there wasn't any rust compiler
in the default path.

The reason I'm doing this is that otherwise it could cause unexpected
effects. For example, if you had a build environment with the
rustcMaster and cargo derivations, you would expect cargo to use
rustcMaster to compile your project (since rustcMaster would be the only
compiler available in $PATH), but this wouldn't happen if we tied down
cargo to use the rustc that was used to compile it (because the default
cargo derivation gets compiled with the stable rust compiler).

That said, I have slightly modified makeRustPlatform so that a rust
platform will always use the rust compiler that was used to build cargo,
because this prevents mistakenly depending on two different versions of
the rust compiler (stable and unstable) in the same rust platform,
something which is usually undesirable.

Fixes #11053
2015-11-18 02:41:45 +01:00
..
agda agda: Remove unused/uneeded abstractions, including postprocess 2015-05-31 01:55:10 +00:00
autonix autonix: JSON manifest format 2015-06-25 09:03:40 -05:00
build-dotnet-package build-dotnet-package: add optional makeWrapperArgs argument 2015-10-29 06:02:18 +03:00
build-fhs-chrootenv Revert "Revert "Merge pull request #9543 from NixOS/staging.post-15.06"" 2015-11-14 12:32:51 -08:00
build-fhs-userenv build-fhs-userenv: fix extraBindMounts 2015-10-07 14:58:37 +03:00
buildenv Fix buildenv 2015-10-30 18:09:45 -07:00
builder-defs Don't fail if env-vars cannot be written to 2015-11-04 16:32:59 +01:00
cc-wrapper darwin: use system dyld 2015-08-25 11:12:09 -07:00
dotnetbuildhelpers Lay down the foundation for packaging the .NET echosystem 2015-06-06 09:06:22 -04:00
dotnetenv
emacs all-packages: Use callPackage where possible 2015-09-14 22:27:19 -06:00
fetchadc
fetchbower Make fetchBower a bit more like a normal mkDerivation, which is easier to test. 2015-07-16 14:42:16 +00:00
fetchbzr
fetchcvs
fetchdarcs
fetchegg
fetchfile
fetchgit nix-prefetch-git: pull all tags from remote when checkouting by revision 2015-09-20 18:24:34 +02:00
fetchgitlocal Rewrite fetchgitLocal 2015-10-01 22:00:44 -07:00
fetchgitrevision
fetchhg fetchhg: fixed nix-prefetch-hg interpreter 2015-10-06 22:41:46 +03:00
fetchmtn
fetchnuget fetchnuget: run fixupPhase to honor propagatedBuildInputs 2015-06-12 17:13:21 +02:00
fetchpatch fetchpatch: Allow to pass a postFetch attribute. 2015-06-23 03:35:30 +02:00
fetchsvn
fetchsvnrevision
fetchsvnssh
fetchurl fetchurl/builder.sh: style fix, close #10260 2015-10-07 09:48:58 +02:00
fetchzip
gcc-cross-wrapper
gcc-wrapper-old
grsecurity kernel: Remove unsupported 3.10, 3.12, 3.14 2015-11-09 11:10:42 -08:00
kdewrapper
kernel
libredirect citrix-receiver: init at 13.2.1, fixes #8458 2015-11-11 22:27:15 +01:00
make-desktopitem makeDesktopItem: don't generated a deprecated key 2015-06-18 10:31:48 +02:00
make-startupitem
make-symlinks
mono-dll-fixer
native-darwin-cctools-wrapper
nuke-references nuke-references: support -e option 2015-10-18 18:41:11 +03:00
ocaml add an ocaml specific builder to the system 2015-05-22 10:12:21 -07:00
release
rust cargo, cargoSnapshot: add rustc runtime dependency 2015-11-18 02:41:45 +01:00
setup-hooks wrapGAppsHook: fix $gappsWrapperArgs as intended 2015-11-09 15:40:20 +01:00
src-only
substitute
substitute-files
templaterpm
upstream-updater
vm vmTools.commonDebPackages: Add "mawk". 2015-10-26 20:56:42 +01:00
vsenv
build-maven.nix build-maven: Add handling for snapshot version resolution 2015-07-20 09:19:12 -04:00
build-pecl.nix
replace-dependency.nix replace-dependency.nix: Remove unnecessary carriage return. 2015-11-16 17:52:12 -05:00
source-from-head-fun.nix
trivial-builders.nix Set ‘allowSubstitutes = false’ on various derivations 2015-07-09 15:10:37 +02:00