Update to rust master
auto merge of #776 : alexcrichton/cargo/issue-488, r=alexcrichton

This helps us not unwrap() and rather propagate the error upwards.

Closes #488
Extract custom build tests and prefix with "old_"
Deprecate old build system and add rust build script as target
Custom build commands are now being run
Build command output now being checked and written to filesystem
Flags from custom build script are now used
Jobs now send back their own description when they start
Add draft for passing metadata to dependencies
Deprecated a few more things
Address minor issues
Move custom-build-related code in its own module
Tweak tests that check whether the build script is being run
Implement the `links` manifest key

This commit adds the `links` manifest key as a string of a C library which is
being linked to. This is passed as an argument to the build command when not
overridden. The implementation of overrides will come soon!
Fix lines_match test for matching process output
Implement overrides via local cargo configuration

This is an implementation of overriding native dependencies and passing
aribtrary metadata and such.
Refine the dependency graph for build scripts

Build scripts can immediately start building as soon as all build dependencies
are available and not need to wait for normal dependencies. This commit also
includes a number of refactorings and reorganizations to tidy up how build
scripts are processed.

One primary piece of state introduced in this commit is a shared Arc<Mutex<T>>
which contains information about the processed build scripts as compilation
continues. Compilation commands will draw information from this state and build
scripts will feed information back into this state to ensure it's up to date.
Ensure fresh build commands populate build info

Whenever a build command is fresh, we need to be sure to propagate its build
information upwards from the cache stored on disk.
Add tests for other cargo cmds + -L propagation
Implement build-dependencies

This adds a flavor of Dependency for build dependencies. Build dependencies are
only ever used when building build commands themselves.