git.iko.soy/typeable/nixpkgs
on master help sign in
Hunspell: add wrapper to include dictionaries

use like this: (hunspellWithDicts (with hunspellDicts; [en-us en-gb-ise]))

commitb34b05b3b8ca274da28184371382d683100a806c authorSimon Vandel Sillesen <simon.vandel@gmail.com> dateMon 1 Feb 2016, 18:44 (11 years ago) parent77f8f35
2 files changed+15
pkgs/development/libraries/hunspell/wrapper.nix+13 pkgs/top-level/all-packages.nix+2
pkgs/development/libraries/hunspell/wrapper.nixnew file+13
@@ -0,0 +1,13 @@
1+{ stdenv, lib, hunspell, makeWrapper, dicts ? [] }:
2+with lib;
3+let
4+ searchPath = makeSearchPath "share/hunspell" dicts;
5+in
6+stdenv.mkDerivation {
7+ name = (appendToName "with-dicts" hunspell).name;
8+ buildInputs = [ makeWrapper ];
9+ buildCommand = ''
10+ makeWrapper ${hunspell}/bin/hunspell $out/bin/hunspell --prefix DICPATH : ${searchPath}
11+ '';
12+ inherit (hunspell) meta;
13+}
pkgs/top-level/all-packages.nix+2
@@ -6856,6 +6856,8 @@ let
68566856
68576857 hunspellDicts = recurseIntoAttrs (callPackages ../development/libraries/hunspell/dictionaries.nix {});
68586858
6859+ hunspellWithDicts = dicts: callPackage ../development/libraries/hunspell/wrapper.nix { inherit dicts; };
6860+
68596861 hwloc = callPackage ../development/libraries/hwloc {};
68606862
68616863 hydraAntLogger = callPackage ../development/libraries/java/hydra-ant-logger { };