Gentoo Archives: gentoo-commits

From: Michael Orlitzky <mjo@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-dicts/duali-data/, app-text/duali/
Date: Thu, 25 Aug 2016 21:33:03
Message-Id: 1472160680.866c7c17834da734f7f1abf8fa366dc247bac059.mjo@gentoo
1 commit: 866c7c17834da734f7f1abf8fa366dc247bac059
2 Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
3 AuthorDate: Thu Aug 25 21:26:32 2016 +0000
4 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
5 CommitDate: Thu Aug 25 21:31:20 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=866c7c17
7
8 app-text/duali, app-dicts/duali-data: new revisions with EAPI=6.
9
10 These two packages needed simultaneous revisions to fix dictionary
11 database compilation. The app-text/duali package provides a script
12 (dict2db) that builds dictionary databases, and a module that uses
13 them. Both use the "anydbm" python module, and should not care about
14 the dbm backend, but the implementation details do -- they try to
15 guess a filename, and each dbm backend outputs a different file name.
16
17 In the new revision of duali, we require python[gdbm] to ensure that
18 we get at least one of the file names that we expect. The new
19 duali-data requires the new duali so that the databases get the
20 correct name, and everything is happy.
21
22 Minimal changes were needed for the duali-data ebuild, but the duali
23 ebuild needed to be updated to use python-single-r1 and was rewritten.
24
25 Gentoo-Bug: 380857
26
27 Package-Manager: portage-2.2.28
28
29 app-dicts/duali-data/duali-data-0.1b-r1.ebuild | 39 ++++++++++++++++++++++++
30 app-text/duali/duali-0.2.0-r1.ebuild | 41 ++++++++++++++++++++++++++
31 2 files changed, 80 insertions(+)
32
33 diff --git a/app-dicts/duali-data/duali-data-0.1b-r1.ebuild b/app-dicts/duali-data/duali-data-0.1b-r1.ebuild
34 new file mode 100644
35 index 00000000..28d2b32
36 --- /dev/null
37 +++ b/app-dicts/duali-data/duali-data-0.1b-r1.ebuild
38 @@ -0,0 +1,39 @@
39 +# Copyright 1999-2016 Gentoo Foundation
40 +# Distributed under the terms of the GNU General Public License v2
41 +# $Id$
42 +
43 +EAPI=6
44 +
45 +DESCRIPTION="Dictionary data for the Arab dictionary project duali"
46 +HOMEPAGE="http://www.arabeyes.org/project.php?proj=Duali"
47 +SRC_URI="mirror://sourceforge/arabeyes/${P}.tar.gz"
48 +
49 +SLOT="0"
50 +LICENSE="GPL-2"
51 +KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~sparc ~x86"
52 +IUSE=""
53 +
54 +DEPEND=">=app-text/duali-0.2.0-r1"
55 +RDEPEND=""
56 +
57 +src_compile() {
58 + dict2db --path ./ || die 'failed to compile databases'
59 +}
60 +
61 +src_install() {
62 + dodoc README
63 +
64 + insinto /usr/share/duali
65 + doins tableab tableac tablebc
66 +
67 + # The dict2db script (and the spellchecker itself) use the python
68 + # anydbm module, which means we kinda don't know what file suffix is
69 + # going to pop out in src_compile. The fact that app-text/duali
70 + # requires python[gdbm] means that we should at least get the gdbm
71 + # database format (e.g. stemsdb) if not stems.db.
72 + if [[ -e stems.db ]]; then
73 + doins stems.db prefixes.db suffixes.db
74 + else
75 + doins stemsdb prefixesdb suffixesdb
76 + fi
77 +}
78
79 diff --git a/app-text/duali/duali-0.2.0-r1.ebuild b/app-text/duali/duali-0.2.0-r1.ebuild
80 new file mode 100644
81 index 00000000..a29db3f
82 --- /dev/null
83 +++ b/app-text/duali/duali-0.2.0-r1.ebuild
84 @@ -0,0 +1,41 @@
85 +# Copyright 1999-2016 Gentoo Foundation
86 +# Distributed under the terms of the GNU General Public License v2
87 +# $Id$
88 +
89 +EAPI=6
90 +
91 +PYTHON_COMPAT=( python2_7 )
92 +
93 +# Duali uses "anydbm" which should even support a slow fallback;
94 +# however, due to implementation details it fails when the databases
95 +# aren't gdbm.
96 +PYTHON_REQ_USE="gdbm"
97 +
98 +inherit python-single-r1
99 +
100 +DESCRIPTION="Arabic dictionary based on the DICT protocol"
101 +HOMEPAGE="http://www.arabeyes.org/project.php?proj=Duali"
102 +SRC_URI="mirror://sourceforge/arabeyes/${P}.tar.bz2"
103 +
104 +LICENSE="BSD"
105 +SLOT="0"
106 +KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~sparc ~x86"
107 +IUSE=""
108 +
109 +DEPEND="${PYTHON_DEPS}"
110 +RDEPEND="${DEPEND}"
111 +PDEPEND=">=app-dicts/duali-data-0.1b-r1"
112 +REQUIRED_USE="${PYTHON_REQUIRED_USE}"
113 +
114 +src_install() {
115 + python_fix_shebang duali dict2db trans2arabic arabic2trans
116 + python_doexe duali dict2db trans2arabic arabic2trans
117 +
118 + insinto /etc
119 + doins duali.conf
120 +
121 + doman doc/man/*.1
122 + dodoc README ChangeLog
123 +
124 + python_domodule pyduali
125 +}