about summary refs log tree commit diff
path: root/tvix
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2023-03-14T21·36+0100
committerflokli <flokli@flokli.de>2023-03-14T22·23+0000
commit36bed4ce57c4af353b4ae8533bb97574bf3004e8 (patch)
treeaaf151ce9a78229bee82f96fc100d93958d3e6eb /tvix
parent0094a1442a2c6baed558fd9dedeb778c2129ce6a (diff)
chore(tvix/store): drop separate bin package r/6007
Apparently, having multiple packages with the same path is a bad thing:

```
The bin target `tvix-store` in package `tvix-store-bin v0.1.0 (/home/flokli/tvl/tvix/store)` has the same output filename as the lib target `tvix_store` in package `tvix-store-bin v0.1.0 (/home/flokli/tvl/tvix/store)`.
Colliding filename is: /home/flokli/tvl/tvix/target/doc/tvix_store/index.html
The output filenames should be unique.
This is a known bug where multiple crates with the same name use
the same path; see <https://github.com/rust-lang/cargo/issues/6313>.
```

Change-Id: Ic785c0349070783baf5e8fd23f5fb60603a3c995
Reviewed-on: https://cl.tvl.fyi/c/depot/+/8308
Tested-by: BuildkiteCI
Reviewed-by: tazjin <tazjin@tvl.su>
Diffstat (limited to 'tvix')
-rw-r--r--tvix/Cargo.lock2
-rw-r--r--tvix/Cargo.nix23
-rw-r--r--tvix/default.nix5
-rw-r--r--tvix/store/Cargo.toml5
-rw-r--r--tvix/store/default.nix2
5 files changed, 8 insertions, 29 deletions
diff --git a/tvix/Cargo.lock b/tvix/Cargo.lock
index 278f811ecfa5..8b80c392c06f 100644
--- a/tvix/Cargo.lock
+++ b/tvix/Cargo.lock
@@ -2640,7 +2640,7 @@ dependencies = [
 ]
 
 [[package]]
-name = "tvix-store-bin"
+name = "tvix-store"
 version = "0.1.0"
 dependencies = [
  "anyhow",
diff --git a/tvix/Cargo.nix b/tvix/Cargo.nix
index 3dcb716d890c..7dcd3cef5347 100644
--- a/tvix/Cargo.nix
+++ b/tvix/Cargo.nix
@@ -93,10 +93,10 @@ rec {
       # File a bug if you depend on any for non-debug work!
       debug = internal.debugCrate { inherit packageId; };
     };
-    "tvix-store-bin" = rec {
-      packageId = "tvix-store-bin";
+    "tvix-store" = rec {
+      packageId = "tvix-store";
       build = internal.buildRustCrateWithFeatures {
-        packageId = "tvix-store-bin";
+        packageId = "tvix-store";
       };
 
       # Debug support which might change between releases.
@@ -7626,10 +7626,6 @@ rec {
             packageId = "dirs";
           }
           {
-            name = "lazy_static";
-            packageId = "lazy_static";
-          }
-          {
             name = "nix-compat";
             packageId = "nix-compat";
           }
@@ -7638,10 +7634,6 @@ rec {
             packageId = "rustyline";
           }
           {
-            name = "serde_json";
-            packageId = "serde_json";
-          }
-          {
             name = "smol_str";
             packageId = "smol_str";
           }
@@ -7650,10 +7642,6 @@ rec {
             packageId = "ssri";
           }
           {
-            name = "tempfile";
-            packageId = "tempfile";
-          }
-          {
             name = "thiserror";
             packageId = "thiserror";
           }
@@ -7860,8 +7848,8 @@ rec {
         ];
 
       };
-      "tvix-store-bin" = rec {
-        crateName = "tvix-store-bin";
+      "tvix-store" = rec {
+        crateName = "tvix-store";
         version = "0.1.0";
         edition = "2021";
         crateBin = [
@@ -7877,7 +7865,6 @@ rec {
           if (lib.versionOlder builtins.nixVersion "2.4pre20211007")
           then lib.cleanSourceWith { filter = sourceFilter; src = ./store; }
           else ./store;
-        libName = "tvix_store";
         dependencies = [
           {
             name = "anyhow";
diff --git a/tvix/default.nix b/tvix/default.nix
index 1b18b7b3fdf2..f88a7bccd595 100644
--- a/tvix/default.nix
+++ b/tvix/default.nix
@@ -34,11 +34,6 @@ in
         PROTO_ROOT = depot.tvix.store.protos;
         nativeBuildInputs = protobufDep prev;
       };
-
-      tvix-store-bin = prev: {
-        PROTO_ROOT = depot.tvix.store.protos;
-        nativeBuildInputs = protobufDep prev;
-      };
     };
   };
 
diff --git a/tvix/store/Cargo.toml b/tvix/store/Cargo.toml
index 793c75a9d84e..569b78076ae1 100644
--- a/tvix/store/Cargo.toml
+++ b/tvix/store/Cargo.toml
@@ -1,11 +1,8 @@
 [package]
-name = "tvix-store-bin"
+name = "tvix-store"
 version = "0.1.0"
 edition = "2021"
 
-[lib]
-name = "tvix_store"
-
 [dependencies]
 anyhow = "1.0.68"
 blake3 = { version = "1.3.1", features = ["rayon", "std"] }
diff --git a/tvix/store/default.nix b/tvix/store/default.nix
index 3d873a097ec4..ec04629ab24b 100644
--- a/tvix/store/default.nix
+++ b/tvix/store/default.nix
@@ -1,5 +1,5 @@
 { depot, ... }:
 
-depot.tvix.crates.workspaceMembers.tvix-store-bin.build.override {
+depot.tvix.crates.workspaceMembers.tvix-store.build.override {
   runTests = true;
 }