printValueAsXML: Handle new-style drvs
Revert "Optimization: We don't need to save derivations whose outputs are all valid in knownDerivations."

We need to keep the derivation around for proper gcRoot link
naming, even if all outpaths are valid. Instead, this optimization
should be moved to RemoteStore::buildPaths.

This reverts commit 646ea9e1ab75f1aeced3165f95a367ac0c65483b.
Optimization: Only send needed derivations to the daemon.
nix-build: Rewrite for new libexpr.

It is now a c++ program that uses libexpr and libstore directly, rather than calling nix-instantiate and nix-store.

Note that, in addition to the normal out-link handling, --add-root and --indirect can now be used for nix-build.
nix-instantiate -> nix-evaluate.

nix-evaluate is nix-instantiate with --eval-only always on.
Update most tests to use nix-evaluate
nix-env: Update to new libexpr
{,un}parseDerivation -> {,un}parseOldDerivation
Add methods to serialize/deserialize Derivations

This will be used for the build hook, among other things.