summary refs log tree commit diff
path: root/data_model
diff options
context:
space:
mode:
authorDavid Tolnay <dtolnay@chromium.org>2019-01-09 16:34:33 -0800
committerchrome-bot <chrome-bot@chromium.org>2019-01-18 00:46:02 -0800
commitd5a9552d72f160aa0fef91971c94f3e90a29493f (patch)
tree5ceb969617bdb9945db228066004448e61225660 /data_model
parentc195616e3f288672198961c043ba5a2a71b792b9 (diff)
downloadcrosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar.gz
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar.bz2
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar.lz
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar.xz
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.tar.zst
crosvm-d5a9552d72f160aa0fef91971c94f3e90a29493f.zip
build: Restore ability to compile data_model and sys_util in isolation
CL:1385972 breaks building these crates because they are not in the
workspace of the top level Cargo.toml so the patch.crates-io setting of
the top level Cargo.toml does not take effect. They end up looking for
their dependencies on crates.io rather than in the parent directory.

Being able to build just data_model and sys_util on their own is useful
when iterating on a change in one of them and needing to run `cargo
test` (as I tried to do today). The errors without this CL are like
this:

    error: no matching package named `assertions` found
    location searched: registry `https://github.com/rust-lang/crates.io-index`
    required by package `data_model v0.1.0 (/path/to/crosvm/data_model)`

BUG=chromium:916921
TEST=cargo check in data_model and sys_util
TEST=cargo test as well
TEST=emerge-amd64-generic crosvm
TEST=FEATURES=test emerge-amd64-generic data_model, sys_util
CQ-DEPEND=CL:1409854

Change-Id: I7bd34f38507c1cea72380f515ce2dd0835aec4fa
Reviewed-on: https://chromium-review.googlesource.com/1403887
Commit-Ready: David Tolnay <dtolnay@chromium.org>
Tested-by: David Tolnay <dtolnay@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Chih-Yang Hsia <paulhsia@chromium.org>
Diffstat (limited to 'data_model')
-rw-r--r--data_model/Cargo.toml2
1 files changed, 1 insertions, 1 deletions
diff --git a/data_model/Cargo.toml b/data_model/Cargo.toml
index 1b30aca..595d05c 100644
--- a/data_model/Cargo.toml
+++ b/data_model/Cargo.toml
@@ -5,6 +5,6 @@ authors = ["The Chromium OS Authors"]
 include = ["src/**/*", "Cargo.toml"]
 
 [dependencies]
-assertions = "*"
+assertions = { path = "../assertions" } # provided by ebuild
 
 [workspace]