summary refs log blame commit diff
path: root/pkgs/development/libraries/hspell/dicts.nix
blob: 83942c2c1dde2e1f3269e3f907627102e9a6aeb9 (plain) (tree)
1
2
3
4
5
6
7
8
9


                   
                                           
                                                      

                             
                           
                    
                                                   

                                           



                               
                          

                                              




                                                 
                            

                                               




                                             
                              

                                                




                                 
{ stdenv, hspell }:

let
  dict = variant: a: stdenv.mkDerivation ({
    inherit (hspell) src patchPhase nativeBuildInputs;
    buildFlags = [ variant ];

    meta = hspell.meta // {
      broken = true;
      description = "${variant} Hebrew dictionary";
    } // (if a ? meta then a.meta else {});
  } // (removeAttrs a ["meta"]));
in
{
  recurseForDerivations = true;

  aspell = dict "aspell" {
    name = "aspell-dict-he-${hspell.version}";

    installPhase = ''
      mkdir -p $out/lib/aspell
      cp -v he_affix.dat he.wl $out/lib/aspell'';
  };

  myspell = dict "myspell" {
    name = "myspell-dict-he-${hspell.version}";

    installPhase = ''
      mkdir -p $out/lib/myspell
      cp -v he.dic he.aff $out/lib/myspell'';
  };

  hunspell = dict "hunspell" {
    name = "hunspell-dict-he-${hspell.version}";

    installPhase = ''
      mkdir -p $out/lib
      cp -rv hunspell $out/lib'';
  };
}