nixpkgs/pkgs/by-name/li/libkkc-data/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

33 lines
944 B
Nix

{ lib, stdenv, fetchurl, fetchpatch, python3, libkkc }:
stdenv.mkDerivation rec {
pname = "libkkc-data";
version = "0.2.7";
src = fetchurl {
url = "${meta.homepage}/releases/download/v${libkkc.version}/${pname}-${version}.tar.xz";
sha256 = "16avb50jasq2f1n9xyziky39dhlnlad0991pisk3s11hl1aqfrwy";
};
patches = [
(fetchpatch {
name = "build-python3.patch";
url = "https://github.com/ueno/libkkc/commit/ba1c1bd3eb86d887fc3689c3142732658071b5f7.patch";
relative = "data/templates/libkkc-data";
hash = "sha256-q4zUclJtDQ1E5v2PW00zRZz6GXllLUcp2h3tugufrRU=";
})
];
nativeBuildInputs = [ python3.pkgs.marisa ];
strictDeps = true;
meta = with lib; {
description = "Language model data package for libkkc";
homepage = "https://github.com/ueno/libkkc";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ vanzef ];
platforms = platforms.linux;
};
}