Commit 57793b8c authored by Yueh-Shun Li's avatar Yueh-Shun Li
Browse files

rustPlatform.buildRustPackage: drop cargoSha256

parent 3ed140c5
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -59,3 +59,5 @@
    - `lib.types.listOf`

- Plasma 5 and Qt 5 based versions of associated software are deprecated in NixOS 25.05, and will be removed in NixOS 25.11. Users are encouraged to upgrade to Plasma 6.

- `rustPlatform.buildRustPackage` stops handling the deprecated argument `cargoSha256`. Out-of-tree packages that haven't migrated from `cargoSha256` to `cargoHash` now receive errors.
+2 −7
Original line number Diff line number Diff line
@@ -83,7 +83,7 @@ lib.extendMkDerivation {
          cargoDeps
        else if cargoLock != null then
          importCargoLock cargoLock
        else if (args.cargoHash or null == null) && (args.cargoSha256 or null == null) then
        else if args.cargoHash or null == null then
          throw "cargoHash, cargoVendorDir, cargoDeps, or cargoLock must be set"
        else if useFetchCargoVendor then
          fetchCargoVendor (
@@ -116,15 +116,10 @@ lib.extendMkDerivation {
                postUnpack
                cargoUpdateHook
                ;
              hash = args.cargoHash;
              name = cargoDepsName;
              patches = cargoPatches;
            }
            // lib.optionalAttrs (args ? cargoHash) {
              hash = args.cargoHash;
            }
            // lib.optionalAttrs (args ? cargoSha256) {
              sha256 = lib.warn "cargoSha256 is deprecated. Please use cargoHash with SRI hash instead" args.cargoSha256;
            }
            // depsExtraArgs
          );