nixpkgs/pkgs/development/libraries/libpinyin/default.nix

34 lines
951 B
Nix
Raw Normal View History

2016-10-01 04:52:01 +03:00
{ stdenv, fetchurl, fetchFromGitHub, autoreconfHook, glib, db, pkgconfig }:
2016-03-26 20:08:53 +03:00
2016-10-01 04:52:01 +03:00
let
modelData = fetchurl {
url = "mirror://sourceforge/libpinyin/models/model14.text.tar.gz";
sha256 = "0qqk30nflj07zjhs231c95ln4yj4ipzwxxiwrxazrg4hb8bhypqq";
2016-10-01 04:52:01 +03:00
};
in
stdenv.mkDerivation rec {
name = "libpinyin-${version}";
version = "2.1.91";
2016-10-01 04:52:01 +03:00
nativeBuildInputs = [ autoreconfHook glib db pkgconfig ];
postUnpack = ''
tar -xzf ${modelData} -C $sourceRoot/data
'';
src = fetchFromGitHub {
owner = "libpinyin";
repo = "libpinyin";
rev = version;
sha256 = "0jbvn65p3zh0573hh27aasd3qly5anyfi8jnps2dxi0my09wbrq3";
2016-10-01 04:52:01 +03:00
};
2016-03-26 20:08:53 +03:00
meta = with stdenv.lib; {
description = "Library for intelligent sentence-based Chinese pinyin input method";
2016-04-15 04:22:35 +03:00
homepage = https://sourceforge.net/projects/libpinyin;
2016-03-26 20:08:53 +03:00
license = licenses.gpl2;
2016-10-01 04:52:01 +03:00
maintainers = with maintainers; [ ericsagnes ];
2016-03-26 20:08:53 +03:00
platforms = platforms.linux;
};
}