about summary refs log tree commit diff
path: root/third_party
diff options
context:
space:
mode:
Diffstat (limited to 'third_party')
-rw-r--r--third_party/rust-crates/default.nix201
1 files changed, 172 insertions, 29 deletions
diff --git a/third_party/rust-crates/default.nix b/third_party/rust-crates/default.nix
index da8347bb1333..b912a9bde3d4 100644
--- a/third_party/rust-crates/default.nix
+++ b/third_party/rust-crates/default.nix
@@ -15,11 +15,9 @@ let
       edition
       ;
    });
-
-  R = depot.third_party.rust-crates;
 in
 
-{
+rec {
   cfg-if = buildRustCrate {
     pname = "cfg-if";
     version = "1.0.0";
@@ -50,7 +48,7 @@ in
     pname = "regex";
     version = "1.4.3";
     features = [ "std" ];
-    dependencies = [ R.regex-syntax ];
+    dependencies = [ regex-syntax ];
     edition = "2015";
     sha256 = "0w0b4bh0ng20lf5y8raaxmxj46ikjqpgwy1iggzpby9lhv9vydkp";
   };
@@ -58,7 +56,7 @@ in
   libloading = buildRustCrate {
     pname = "libloading";
     version = "0.6.7";
-    dependencies = [ R.cfg-if ];
+    dependencies = [ cfg-if ];
     edition = "2015";
     sha256 = "111d8zsizswnxiqn43vcgnc2ym9spsx1i6pcfp35ca3yw2ixq95j";
   };
@@ -70,8 +68,8 @@ in
     # and the build.rs is also not where buildRustCrate would find it
     build = "binding_rust/build.rs";
     version = "0.17.1";
-    dependencies = [ R.regex ];
-    buildDependencies = [ R.cc ];
+    dependencies = [ regex ];
+    buildDependencies = [ cc ];
     sha256 = "0jwwbvs4icpra7m1ycvnyri5h3sbw4qrfvgnnvnk72h4w93qhzhr";
   };
 
@@ -91,14 +89,14 @@ in
   inotify-sys = buildRustCrate {
     pname = "inotify-sys";
     version = "0.1.5";
-    dependencies = [ R.libc ];
+    dependencies = [ libc ];
     sha256 = "1yiy577xxhi0j90nbg9nkd8cqwc1xix62rz55jjngvxa5jl5613v";
   };
 
   inotify = buildRustCrate {
     pname = "inotify";
     version = "0.9.2";
-    dependencies = [ R.bitflags R.libc R.inotify-sys ];
+    dependencies = [ bitflags libc inotify-sys ];
     sha256 = "0fcknyvknglwwk1pdzdlb4m0ry2dym1yx8r5prf2v00pxnjk0hv2";
   };
 
@@ -126,8 +124,8 @@ in
     pname = "nom";
     version = "5.1.1";
     sha256 = "1gb4r6mjwd645jqh02nhn60i7qkw8cgy3xq1r4clnmvz3cmkv1l0";
-    dependencies = [ R.memchr ];
-    buildDependencies = [ R.version-check ];
+    dependencies = [ memchr ];
+    buildDependencies = [ version-check ];
     features = [ "std" "alloc" ];
   };
 
@@ -155,7 +153,7 @@ in
     pname = "num-traits";
     version = "0.2.14";
     edition = "2015";
-    buildDependencies = [ R.autocfg ];
+    buildDependencies = [ autocfg ];
     sha256 = "09ac9dcp6cr57vjzyiy213y7312jqcy84mkamp99zr40qd1gwnyk";
   };
 
@@ -163,8 +161,8 @@ in
     pname = "num-integer";
     version = "0.1.44";
     edition = "2015";
-    dependencies = [ R.num-traits ];
-    buildDependencies = [ R.autocfg ];
+    dependencies = [ num-traits ];
+    buildDependencies = [ autocfg ];
     sha256 = "1gdbnfgnivp90h644wmqj4a20yfmdga2xxxacx53pjbcazvfvajc";
   };
 
@@ -172,7 +170,7 @@ in
     pname = "chrono";
     version = "0.4.19";
     edition = "2015";
-    dependencies = [ R.num-traits R.num-integer ];
+    dependencies = [ num-traits num-integer ];
     features = [ "alloc" "std" ];
     sha256 = "0cjf5dnfbk99607vz6n5r6bhwykcypq5psihvk845sxrhnzadsar";
   };
@@ -180,7 +178,7 @@ in
   imap-proto = buildRustCrate {
     pname = "imap-proto";
     version = "0.10.2";
-    dependencies = [ R.nom ];
+    dependencies = [ nom ];
     sha256 = "1bf5r4d0z7c8wxrvr7kjy26500wr7cd4sxz49ix3b3yzc6ayyqv1";
   };
 
@@ -194,13 +192,13 @@ in
     pname = "imap";
     version = "2.4.0";
     dependencies = [
-      R.base64
-      R.bufstream
-      R.chrono
-      R.imap-proto
-      R.lazy_static
-      R.nom
-      R.regex
+      base64
+      bufstream
+      chrono
+      imap-proto
+      lazy_static
+      nom
+      regex
     ];
     sha256 = "1nj6x45qnid98nv637623rrh7imcxk0kad89ry8j5dkkgccvjyc0";
   };
@@ -208,7 +206,7 @@ in
   epoll = buildRustCrate {
     pname = "epoll";
     version = "4.3.1";
-    dependencies = [ R.bitflags R.libc ];
+    dependencies = [ bitflags libc ];
     sha256 = "0dgmgdmrfbjkpxn1w3xmmwsm2a623a9qdwn90s8yl78n4a36kbh9";
   };
 
@@ -236,7 +234,7 @@ in
     pname = "serde_json";
     version = "1.0.62";
     sha256 = "0sgc8dycigq0nxr4j613m4q733alfb2i10s6nz80lsbbqgrka21q";
-    dependencies = [ R.serde R.ryu R.itoa ];
+    dependencies = [ serde ryu itoa ];
     features = [ "std" ];
   };
 
@@ -244,7 +242,7 @@ in
     pname = "log";
     version = "0.4.11";
     sha256 = "0m6xhqxsps5mgd7r91g5mqkndbh8zbjd58p7w75r330zl4n40l07";
-    dependencies = [ R.cfg-if ];
+    dependencies = [ cfg-if ];
   };
 
   mustache = buildRustCrate {
@@ -252,7 +250,7 @@ in
     version = "0.9.0";
     edition = "2015";
     sha256 = "1zgl8l15i19lzp90icgwyi6zqdd31b9vm8w129f41d1zd0hs7ayq";
-    dependencies = [ R.log R.serde ];
+    dependencies = [ log serde ];
   };
 
   semver-parser = buildRustCrate {
@@ -267,7 +265,7 @@ in
     version = "0.10.0";
     edition = "2015";
     sha256 = "0pbkdwlpq4d0hgdrymm2rcw31plni2siwd882gbcbscjvyvrrrqa";
-    dependencies = [ R.semver-parser ];
+    dependencies = [ semver-parser ];
   };
 
   toml = buildRustCrate {
@@ -275,6 +273,151 @@ in
     version = "0.5.8";
     sha256 = "1vwjwmwsy83pbgvvm11a6grbhb09zkcrv9v95wfwv48wjm01wdj4";
     edition = "2018";
-    dependencies = [ R.serde ];
+    dependencies = [ serde ];
+  };
+
+  pkg-config = buildRustCrate {
+    pname = "pkg-config";
+    version = "0.3.19";
+    crateName = "pkg_config";
+    sha256 = "1kd047p8jv6mhmfzddjvfa2nwkfrb3l1wml6lfm51n1cr06cc9lz";
+  };
+
+  libz-sys = buildRustCrate {
+    pname = "libz-sys";
+    version = "1.1.2";
+    crateName = "libz-sys";
+    sha256 = "1y7v6bkwr4b6yaf951p1ns7mx47b29ziwdd5wziaic14gs1gwq30";
+    buildDependencies = [
+      cc
+      pkg-config
+    ];
+  };
+
+  libgit2-sys = buildRustCrate {
+    pname = "libgit2-sys";
+    version = "0.12.26+1.3.0";
+    crateName = "libgit2_sys";
+    sha256 = "15zg0yy7lk7464yf9i1kxh4gaxdyb8m96ayb7vkjgmz1s2rgq7s2";
+    dependencies = [
+      libc
+      libz-sys
+    ];
+    libPath = "lib.rs";
+    libName = "libgit2_sys";
+    # TODO: this should be available via `pkgs.defaultCrateOverrides`,
+    # I thought that was included by default?
+    nativeBuildInputs = [ pkg-config ];
+    buildInputs = [ pkgs.zlib pkgs.libgit2 ];
+    buildDependencies = [
+      cc
+      pkg-config
+    ];
+  };
+
+  matches = buildRustCrate {
+    pname = "matches";
+    version = "0.1.8";
+    crateName = "matches";
+    sha256 = "03hl636fg6xggy0a26200xs74amk3k9n0908rga2szn68agyz3cv";
+    libPath = "lib.rs";
+  };
+
+  percent-encoding = buildRustCrate {
+    pname = "percent_encoding";
+    version = "2.1.0";
+    crateName = "percent_encoding";
+    sha256 = "0i838f2nr81585ckmfymf8l1x1vdmx6n8xqvli0lgcy60yl2axy3";
+    libPath = "lib.rs";
+  };
+
+  form_urlencoded = buildRustCrate {
+    pname = "form_urlencoded";
+    version = "1.0.1";
+    crateName = "form_urlencoded";
+    sha256 = "0rhv2hfrzk2smdh27walkm66zlvccnnwrbd47fmf8jh6m420dhj8";
+    dependencies = [
+      matches
+      percent-encoding
+    ];
+  };
+
+  tinyvec_macros = buildRustCrate {
+    pname = "tinyvec_macros";
+    version = "0.1.0";
+    crateName = "tinyvec-macros";
+    sha256 = "0aim73hyq5g8b2hs9gjq2sv0xm4xzfbwp5fdyg1frljqzkapq682";
+  };
+
+  tinyvec = buildRustCrate {
+    pname = "tinyvec";
+    version = "1.2.0";
+    crateName = "tinyvec";
+    sha256 = "1c95nma20kiyrjwfsk7hzd5ir6yy4bm63fmfbfb4dm9ahnlvdp3y";
+    features = [ "alloc" ];
+    dependencies = [
+      tinyvec_macros
+    ];
+  };
+
+  unicode-normalization = buildRustCrate {
+    pname = "unicode-normalization";
+    version = "0.1.17";
+    crateName = "unicode_normalization";
+    sha256 = "0w4s0avzlf7pzcclhhih93aap613398sshm6jrxcwq0f9lhis11c";
+    dependencies = [
+      tinyvec
+    ];
+  };
+
+  unicode-bidi = buildRustCrate {
+    pname = "unicode-bidi";
+    version = "0.3.5";
+    crateName = "unicode_bidi";
+    sha256 = "193jzlxj1dfcms2381lyd45zh4ywlicj9lzcfpid1zbkmfarymkz";
+    dependencies = [
+      matches
+    ];
+  };
+
+  idna = buildRustCrate {
+    pname = "idna";
+    version = "0.2.3";
+    crateName = "idna";
+    sha256 = "0hwypd0fpym9lmd4bbqpwyr5lhrlvmvzhi1vy9asc5wxwkzrh299";
+    dependencies = [
+      matches
+      unicode-normalization
+      unicode-bidi
+    ];
+  };
+
+  url = buildRustCrate {
+    pname = "url";
+    version = "2.2.1";
+    crateName = "url";
+    sha256 = "1ci1djafh83qhpzbmxnr9w5gcrjs3ghf8rrxdy4vklqyji6fvn5v";
+    dependencies = [
+      form_urlencoded
+      idna
+      matches
+      percent-encoding
+    ];
+  };
+
+
+  git2 = buildRustCrate {
+    pname = "git2";
+    edition = "2018";
+    version = "0.13.25";
+    crateName = "git2";
+    sha256 = "181mw4kxsqrwpib9kf25fykc48wxhjla37vzis4j0b0w0yhyaqi3";
+    dependencies = [
+      bitflags
+      libc
+      libgit2-sys
+      log
+      url
+    ];
   };
 }