vistafonts-chs: fix build
Fix the broken download link and the install script.
This commit is contained in:
parent
b12d559675
commit
4ee2a19bb6
1 changed files with 15 additions and 9 deletions
|
@ -1,15 +1,23 @@
|
||||||
{ lib, fetchzip, buildPackages }:
|
{ lib, stdenvNoCC, fetchurl, cabextract }:
|
||||||
|
|
||||||
# Modified from vista-fonts
|
stdenvNoCC.mkDerivation {
|
||||||
|
pname = "vista-fonts-chs";
|
||||||
|
version = "1";
|
||||||
|
|
||||||
fetchzip {
|
src = fetchurl {
|
||||||
name = "vista-fonts-chs-1";
|
url = "http://web.archive.org/web/20161221192937if_/http://download.microsoft.com/download/d/6/e/d6e2ff26-5821-4f35-a18b-78c963b1535d/VistaFont_CHS.EXE";
|
||||||
|
# Alternative mirror:
|
||||||
|
# http://www.eeo.cn/download/font/VistaFont_CHS.EXE
|
||||||
|
sha256 = "1qwm30b8aq9piyqv07hv8b5bac9ms40rsdf8pwix5dyk8020i8xi";
|
||||||
|
};
|
||||||
|
|
||||||
url = "http://download.microsoft.com/download/d/6/e/d6e2ff26-5821-4f35-a18b-78c963b1535d/VistaFont_CHS.EXE";
|
nativeBuildInputs = [ cabextract ];
|
||||||
|
|
||||||
postFetch = ''
|
unpackPhase = ''
|
||||||
${buildPackages.cabextract}/bin/cabextract --lowercase --filter '*.TTF' $downloadedFile
|
cabextract --lowercase --filter '*.TTF' $src
|
||||||
|
'';
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
mkdir -p $out/share/fonts/truetype
|
mkdir -p $out/share/fonts/truetype
|
||||||
cp *.ttf $out/share/fonts/truetype
|
cp *.ttf $out/share/fonts/truetype
|
||||||
|
|
||||||
|
@ -20,8 +28,6 @@ fetchzip {
|
||||||
--subst-var-by fontname "Microsoft YaHei"
|
--subst-var-by fontname "Microsoft YaHei"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
sha256 = "1zwrgck84k80gpg7493jdnxnv9ajxk5c7qndinnmqydnrw239zbw";
|
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "TrueType fonts from Microsoft Windows Vista For Simplified Chinese (Microsoft YaHei)";
|
description = "TrueType fonts from Microsoft Windows Vista For Simplified Chinese (Microsoft YaHei)";
|
||||||
homepage = "https://www.microsoft.com/typography/fonts/family.aspx?FID=350";
|
homepage = "https://www.microsoft.com/typography/fonts/family.aspx?FID=350";
|
||||||
|
|
Loading…
Reference in a new issue