(zilch lang rust registry): don't substitute cargo tarballs

This commit is contained in:
puck 2025-03-02 14:10:32 +00:00
parent 5721c8263b
commit 8a4cfe91fa

View file

@ -140,10 +140,11 @@
(define url (string-append "https://static.crates.io/crates/" (lockfile-entry-name lockfile-entry) "/" (lockfile-entry-version lockfile-entry) "/download")) (define url (string-append "https://static.crates.io/crates/" (lockfile-entry-name lockfile-entry) "/" (lockfile-entry-version lockfile-entry) "/download"))
(define crate-name (string-append (lockfile-entry-name lockfile-entry) "-" (lockfile-entry-version lockfile-entry) ".crate")) (define crate-name (string-append (lockfile-entry-name lockfile-entry) "-" (lockfile-entry-version lockfile-entry) ".crate"))
(define crate-name-path (string-append (lockfile-entry-name lockfile-entry) "-" (lockfile-entry-version lockfile-entry))) (define crate-name-path (string-append (lockfile-entry-name lockfile-entry) "-" (lockfile-entry-version lockfile-entry)))
(define fetched-tarball (store-path-for-fod crate-name "builtin" '("builtin:fetchurl") `(("url" . ,url)) "sha256" (lockfile-entry-checksum lockfile-entry) #f)) (define fetched-tarball (store-path-for-fod crate-name "builtin" '("builtin:fetchurl") `(("url" . ,url) ("allowSubstitutes" . "")) "sha256" (lockfile-entry-checksum lockfile-entry) #f))
(define unpacked-tarball (define unpacked-tarball
(cdar (store-path-for-drv crate-name "builtin" '("builtin:unpack-channel") (cdar (store-path-for-drv crate-name "builtin" '("builtin:unpack-channel")
#~(("src" . #$fetched-tarball) #~(("src" . #$fetched-tarball)
("allowSubstitutes" . "")
("channelName" . #$crate-name-path)) '("out")))) ("channelName" . #$crate-name-path)) '("out"))))
#~,(string-append #$unpacked-tarball "/" #$crate-name-path)) #~,(string-append #$unpacked-tarball "/" #$crate-name-path))