summary refs log tree commit diff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-05-17 16:10:48 +0200
committerLudovic Courtès <ludo@gnu.org>2017-05-17 16:20:06 +0200
commit6d35b1c99c15f87a30fdf1a38c88db844b3e8303 (patch)
tree24544a4e76e6ecdc937131d9aa9bc9bec8eda42f /gnu/packages/patches
parentbe62e2224ac292cbefeda8c6e1216c52aaf14808 (diff)
downloadguix-6d35b1c99c15f87a30fdf1a38c88db844b3e8303.tar.gz
gnu: aspell: 'dict-dir' set to ~/.guix-profile/lib/aspell or $ASPELL_DICT_DIR.
See <https://bugs.gnu.org/25836> for background.

* gnu/packages/patches/aspell-default-dict-dir.patch: New file.
* gnu/packages/aspell.scm (aspell)[source](patches): New field.
[native-search-paths]: New field.
* gnu/local.mk (dist_patch_DATA): Add it.
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/aspell-default-dict-dir.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/gnu/packages/patches/aspell-default-dict-dir.patch b/gnu/packages/patches/aspell-default-dict-dir.patch
new file mode 100644
index 0000000000..17a6ff606f
--- /dev/null
+++ b/gnu/packages/patches/aspell-default-dict-dir.patch
@@ -0,0 +1,20 @@
+This patch changes the default value of 'dict-dir' to correspond
+to ~/.guix-profile/lib/aspell rather than $prefix/lib/aspell-X.Y.
+
+This is not strictly necessary for the 'aspell' program itself since
+one can simply set "ASPELL_CONF=dict-dir $HOME/.guix-profile/lib/aspell".
+However it is necessary for applications that use libaspell since
+'ASPELL_CONF' is not honored in this case.  See <https://bugs.gnu.org/25836>.
+
+--- a/common/config.cpp
++++ b/common/config.cpp
+@@ -1349,6 +1349,9 @@ namespace acommon {
+ #  define REPL     ".aspell.<lang>.prepl"
+ #endif
+ 
++#undef DICT_DIR
++#define DICT_DIR "<$ASPELL_DICT_DIR|home-dir/.guix-profile/lib/aspell>"
++
+   static const KeyInfo config_keys[] = {
+     // the description should be under 50 chars
+     {"actual-dict-dir", KeyInfoString, "<dict-dir^master>", 0}