1 |
commit: cef3d321ee72f7b3b32f05c2b73921588659749d |
2 |
Author: Pacho Ramos <pacho <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Nov 27 10:08:00 2016 +0000 |
4 |
Commit: Pacho Ramos <pacho <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Nov 27 10:08:32 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cef3d321 |
7 |
|
8 |
app-text/enchant: Fix hunspell 1.5 support (#600952 by Lars Wendler) |
9 |
|
10 |
Package-Manager: portage-2.3.2 |
11 |
|
12 |
app-text/enchant/enchant-1.6.0.ebuild | 22 ++++++++++++---------- |
13 |
.../files/enchant-1.6.0-hunspell150_fix.patch | 12 ++++++++++++ |
14 |
2 files changed, 24 insertions(+), 10 deletions(-) |
15 |
|
16 |
diff --git a/app-text/enchant/enchant-1.6.0.ebuild b/app-text/enchant/enchant-1.6.0.ebuild |
17 |
index 181d389..765719f 100644 |
18 |
--- a/app-text/enchant/enchant-1.6.0.ebuild |
19 |
+++ b/app-text/enchant/enchant-1.6.0.ebuild |
20 |
@@ -3,7 +3,6 @@ |
21 |
# $Id$ |
22 |
|
23 |
EAPI=6 |
24 |
- |
25 |
inherit eutils autotools |
26 |
|
27 |
DESCRIPTION="Spellchecker wrapping library" |
28 |
@@ -13,26 +12,29 @@ SRC_URI="http://www.abisource.com/downloads/${PN}/${PV}/${P}.tar.gz" |
29 |
LICENSE="LGPL-2.1" |
30 |
SLOT="0" |
31 |
KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 sh sparc x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris" |
32 |
+ |
33 |
IUSE="aspell +hunspell static-libs zemberek" |
34 |
+REQUIRED_USE="|| ( hunspell aspell zemberek )" |
35 |
|
36 |
COMMON_DEPENDS=" |
37 |
dev-libs/glib:2 |
38 |
aspell? ( app-text/aspell ) |
39 |
hunspell? ( >=app-text/hunspell-1.2.1:0= ) |
40 |
- zemberek? ( dev-libs/dbus-glib )" |
41 |
- |
42 |
+ zemberek? ( dev-libs/dbus-glib ) |
43 |
+" |
44 |
RDEPEND="${COMMON_DEPENDS} |
45 |
- zemberek? ( app-text/zemberek-server )" |
46 |
- |
47 |
+ zemberek? ( app-text/zemberek-server ) |
48 |
+" |
49 |
DEPEND="${COMMON_DEPENDS} |
50 |
- virtual/pkgconfig" |
51 |
- |
52 |
-REQUIRED_USE="|| ( hunspell aspell zemberek )" |
53 |
+ virtual/pkgconfig |
54 |
+" |
55 |
|
56 |
DOCS="AUTHORS BUGS ChangeLog HACKING MAINTAINERS NEWS README TODO" |
57 |
|
58 |
PATCHES=( |
59 |
+ # http://bugzilla.abisource.com/show_bug.cgi?id=13772 |
60 |
"${FILESDIR}/${P}-hunspell140_fix.patch" |
61 |
+ "${FILESDIR}/${P}-hunspell150_fix.patch" |
62 |
) |
63 |
|
64 |
src_prepare() { |
65 |
@@ -40,6 +42,7 @@ src_prepare() { |
66 |
sed -i \ |
67 |
-e 's:noinst_PROGRAMS:check_PROGRAMS:' \ |
68 |
tests/Makefile.am || die |
69 |
+ mv configure.in configure.ac || die |
70 |
AT_M4DIR=ac-helpers eautoreconf |
71 |
} |
72 |
|
73 |
@@ -56,6 +59,5 @@ src_configure() { |
74 |
|
75 |
src_install() { |
76 |
default |
77 |
- |
78 |
- prune_libtool_files --all |
79 |
+ prune_libtool_files --modules |
80 |
} |
81 |
|
82 |
diff --git a/app-text/enchant/files/enchant-1.6.0-hunspell150_fix.patch b/app-text/enchant/files/enchant-1.6.0-hunspell150_fix.patch |
83 |
new file mode 100644 |
84 |
index 00000000..bd40c81 |
85 |
--- /dev/null |
86 |
+++ b/app-text/enchant/files/enchant-1.6.0-hunspell150_fix.patch |
87 |
@@ -0,0 +1,12 @@ |
88 |
+diff -upr enchant-1.6.0.orig/src/myspell/myspell_checker.cpp enchant-1.6.0/src/myspell/myspell_checker.cpp |
89 |
+--- enchant-1.6.0.orig/src/myspell/myspell_checker.cpp 2016-11-26 16:04:05.689051339 +0200 |
90 |
++++ enchant-1.6.0/src/myspell/myspell_checker.cpp 2016-11-26 16:05:11.380014568 +0200 |
91 |
+@@ -431,7 +431,7 @@ MySpellChecker::requestDictionary(const |
92 |
+ if(myspell == NULL){ |
93 |
+ return false; |
94 |
+ } |
95 |
+- char *enc = myspell->get_dic_encoding(); |
96 |
++ const char *enc = myspell->get_dic_encoding(); |
97 |
+ |
98 |
+ m_translate_in = g_iconv_open(enc, "UTF-8"); |
99 |
+ m_translate_out = g_iconv_open("UTF-8", enc); |