fetchDebianPatch: init
This commit is contained in:
parent
e2b42410ec
commit
741ed30e77
2 changed files with 15 additions and 0 deletions
pkgs
13
pkgs/build-support/fetchdebianpatch/default.nix
Normal file
13
pkgs/build-support/fetchdebianpatch/default.nix
Normal file
|
@ -0,0 +1,13 @@
|
|||
{ lib, fetchpatch }:
|
||||
|
||||
lib.makeOverridable (
|
||||
{ pname, version, debianRevision ? null, name, hash, area ? "main" }:
|
||||
let versionString =
|
||||
if debianRevision == null then version else "${version}-${debianRevision}";
|
||||
in fetchpatch {
|
||||
url =
|
||||
"https://sources.debian.org/data/${area}/${builtins.substring 0 1 pname}/"
|
||||
+ "${pname}/${versionString}/debian/patches/${name}.patch";
|
||||
inherit hash;
|
||||
}
|
||||
)
|
|
@ -1173,6 +1173,8 @@ with pkgs;
|
|||
tests = pkgs.tests.fetchzip;
|
||||
};
|
||||
|
||||
fetchDebianPatch = callPackage ../build-support/fetchdebianpatch { };
|
||||
|
||||
fetchCrate = callPackage ../build-support/rust/fetchcrate.nix { };
|
||||
|
||||
fetchFromGitea = callPackage ../build-support/fetchgitea { };
|
||||
|
|
Loading…
Reference in a new issue