fix: Fix compilation from outside
Change-Id: I63a331b8e7e46e248811ab074f778f8467329911
This commit is contained in:
parent
e8c8164d78
commit
920b7118d5
13 changed files with 16 additions and 31 deletions
|
@ -31,6 +31,3 @@ tonic-reflection = ["dep:tonic-reflection", "tvix-castore/tonic-reflection"]
|
|||
|
||||
[dev-dependencies]
|
||||
rstest = "0.19.0"
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
|
|
@ -20,15 +20,15 @@ fn main() -> Result<()> {
|
|||
.extern_path(".tvix.castore.v1", "::tvix_castore::proto")
|
||||
.compile(
|
||||
&[
|
||||
"tvix/build/protos/build.proto",
|
||||
"tvix/build/protos/rpc_build.proto",
|
||||
"build/protos/build.proto",
|
||||
"build/protos/rpc_build.proto",
|
||||
],
|
||||
// If we are in running `cargo build` manually, using `../..` works fine,
|
||||
// but in case we run inside a nix build, we need to instead point PROTO_ROOT
|
||||
// to a sparseTree containing that structure.
|
||||
&[match std::env::var_os("PROTO_ROOT") {
|
||||
Some(proto_root) => proto_root.to_str().unwrap().to_owned(),
|
||||
None => "../..".to_string(),
|
||||
None => "..".to_string(),
|
||||
}],
|
||||
)
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@ syntax = "proto3";
|
|||
|
||||
package tvix.build.v1;
|
||||
|
||||
import "tvix/castore/protos/castore.proto";
|
||||
import "castore/protos/castore.proto";
|
||||
|
||||
option go_package = "code.tvl.fyi/tvix/build-go;buildv1";
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ syntax = "proto3";
|
|||
|
||||
package tvix.build.v1;
|
||||
|
||||
import "tvix/build/protos/build.proto";
|
||||
import "build/protos/build.proto";
|
||||
|
||||
option go_package = "code.tvl.fyi/tvix/build-go;buildv1";
|
||||
|
||||
|
|
|
@ -126,6 +126,3 @@ tonic-reflection = ["dep:tonic-reflection"]
|
|||
# Requires the following packages in $PATH:
|
||||
# cbtemulator, google-cloud-bigtable-tool
|
||||
integration = []
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
|
|
@ -20,16 +20,16 @@ fn main() -> Result<()> {
|
|||
.type_attribute(".", "#[derive(Eq, Hash)]")
|
||||
.compile(
|
||||
&[
|
||||
"tvix/castore/protos/castore.proto",
|
||||
"tvix/castore/protos/rpc_blobstore.proto",
|
||||
"tvix/castore/protos/rpc_directory.proto",
|
||||
"castore/protos/castore.proto",
|
||||
"castore/protos/rpc_blobstore.proto",
|
||||
"castore/protos/rpc_directory.proto",
|
||||
],
|
||||
// If we are in running `cargo build` manually, using `../..` works fine,
|
||||
// but in case we run inside a nix build, we need to instead point PROTO_ROOT
|
||||
// to a sparseTree containing that structure.
|
||||
&[match std::env::var_os("PROTO_ROOT") {
|
||||
Some(proto_root) => proto_root.to_str().unwrap().to_owned(),
|
||||
None => "../..".to_string(),
|
||||
None => "..".to_string(),
|
||||
}],
|
||||
)
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ syntax = "proto3";
|
|||
|
||||
package tvix.castore.v1;
|
||||
|
||||
import "tvix/castore/protos/castore.proto";
|
||||
import "castore/protos/castore.proto";
|
||||
|
||||
option go_package = "code.tvl.fyi/tvix/castore-go;castorev1";
|
||||
|
||||
|
|
|
@ -40,6 +40,3 @@ otlp = ["tvix-tracing/otlp"]
|
|||
[dev-dependencies]
|
||||
hex-literal = "0.4.1"
|
||||
rstest = "0.19.0"
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
|
|
@ -83,6 +83,3 @@ xp-store-composition = ["toml"]
|
|||
# Requires the following packages in $PATH:
|
||||
# cbtemulator, google-cloud-bigtable-tool
|
||||
integration = []
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
|
|
@ -20,15 +20,15 @@ fn main() -> Result<()> {
|
|||
.extern_path(".tvix.castore.v1", "::tvix_castore::proto")
|
||||
.compile(
|
||||
&[
|
||||
"tvix/store/protos/pathinfo.proto",
|
||||
"tvix/store/protos/rpc_pathinfo.proto",
|
||||
"store/protos/pathinfo.proto",
|
||||
"store/protos/rpc_pathinfo.proto",
|
||||
],
|
||||
// If we are in running `cargo build` manually, using `../..` works fine,
|
||||
// but in case we run inside a nix build, we need to instead point PROTO_ROOT
|
||||
// to a sparseTree containing that structure.
|
||||
&[match std::env::var_os("PROTO_ROOT") {
|
||||
Some(proto_root) => proto_root.to_str().unwrap().to_owned(),
|
||||
None => "../..".to_string(),
|
||||
None => "..".to_string(),
|
||||
}],
|
||||
)
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ syntax = "proto3";
|
|||
|
||||
package tvix.store.v1;
|
||||
|
||||
import "tvix/castore/protos/castore.proto";
|
||||
import "castore/protos/castore.proto";
|
||||
|
||||
option go_package = "code.tvl.fyi/tvix/store-go;storev1";
|
||||
|
||||
|
|
|
@ -4,8 +4,8 @@ syntax = "proto3";
|
|||
|
||||
package tvix.store.v1;
|
||||
|
||||
import "tvix/castore/protos/castore.proto";
|
||||
import "tvix/store/protos/pathinfo.proto";
|
||||
import "castore/protos/castore.proto";
|
||||
import "store/protos/pathinfo.proto";
|
||||
|
||||
option go_package = "code.tvl.fyi/tvix/store-go;storev1";
|
||||
|
||||
|
|
|
@ -49,6 +49,3 @@ reqwest = [
|
|||
axum = [
|
||||
"dep:axum",
|
||||
]
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
|
Loading…
Reference in a new issue