liberastika: make the font derivation fixed-output

- [x] make the font derivation fixed-output (https://github.com/NixOS/nixpkgs/issues/27754)
This commit is contained in:
volth 2017-08-11 03:49:27 +00:00 committed by Franz Pletz
parent 793523d7bc
commit 7e2b15f08b

View File

@ -1,26 +1,20 @@
{stdenv, fetchurl, unzip}:
{stdenv, fetchzip}:
stdenv.mkDerivation rec {
name = "liberastika-${version}";
let
version = "1.1.5";
in fetchzip rec {
name = "liberastika-${version}";
src = fetchurl {
url = "mirror://sourceforge/project/lib-ka/liberastika-ttf-${version}.zip";
sha256 = "0vg5ki120lb577ihvq8w0nxs8yacqzcvsmnsygksmn6281hyj0xj";
};
buildInputs = [ unzip ];
sourceRoot = ".";
installPhase = ''
mkdir -p $out/share/fonts/truetype
cp -v $(find . -name '*.ttf') $out/share/fonts/truetype
mkdir -p "$out/doc/${name}"
cp -v AUTHORS ChangeLog COPYING README "$out/doc/${name}" || true
postFetch = ''
mkdir -p $out/share/{doc,fonts}
unzip -j $downloadedFile \*.ttf -d $out/share/fonts/truetype
unzip -j $downloadedFile AUTHORS ChangeLog COPYING README -d "$out/share/doc/${name}"
'';
sha256 = "1a9dvl1pzch2vh8sqyyn1d1wz4n624ffazl6hzlc3s5k5lzrb6jp";
meta = with stdenv.lib; {
description = "Liberation Sans fork with improved cyrillic support";
homepage = https://sourceforge.net/projects/lib-ka/;