diff options
author | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2023-01-18 21:29:32 +0100 |
---|---|---|
committer | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2023-01-18 21:29:32 +0100 |
commit | 1c2523b7498556253d65c4684a11bf421a60ae42 (patch) | |
tree | 62cc156d406c2cf2fddf1eef58f0d4c3a253a870 /pkgs/data/fonts/wqy-zenhei | |
parent | 3fd894b06e9a56d155f9faae82b7407addfecce3 (diff) |
treewide: fonts: reduce unneeded fetchzips
Diffstat (limited to 'pkgs/data/fonts/wqy-zenhei')
-rw-r--r-- | pkgs/data/fonts/wqy-zenhei/default.nix | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/pkgs/data/fonts/wqy-zenhei/default.nix b/pkgs/data/fonts/wqy-zenhei/default.nix index 5d461d0f5b008..9b0757128cd0d 100644 --- a/pkgs/data/fonts/wqy-zenhei/default.nix +++ b/pkgs/data/fonts/wqy-zenhei/default.nix @@ -1,19 +1,24 @@ -{ lib, fetchzip }: +{ lib, stdenvNoCC, fetchurl }: -let +stdenvNoCC.mkDerivation rec { + pname = "wqy-zenhei"; version = "0.9.45"; -in fetchzip rec { - name = "wqy-zenhei-${version}"; - url = "mirror://sourceforge/wqy/${name}.tar.gz"; + src = fetchurl { + url = "mirror://sourceforge/wqy/${pname}-${version}.tar.gz"; + hash = "sha256-5LfjBkdb+UJ9F1dXjw5FKJMMhMROqj8WfUxC8RDuddY="; + }; + + dontBuild = true; + + installPhase = '' + runHook preInstall - postFetch = '' - tar -xzf $downloadedFile --strip-components=1 mkdir -p $out/share/fonts install -m644 *.ttc $out/share/fonts/ - ''; - sha256 = "0hbjq6afcd63nsyjzrjf8fmm7pn70jcly7fjzjw23v36ffi0g255"; + runHook postInstall + ''; meta = { description = "A (mainly) Chinese Unicode font"; |