From: "Andrew Savchenko" <bircoph@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-text/stardict/
Date: Sat, 3 Dec 2016 16:47:39 +0000 (UTC) [thread overview]
Message-ID: <1480783655.d615f8f9d771a4e52ea5d4a27ec2e0bdd37e0dcb.bircoph@gentoo> (raw)
commit: d615f8f9d771a4e52ea5d4a27ec2e0bdd37e0dcb
Author: Andrew Savchenko <bircoph <AT> gentoo <DOT> org>
AuthorDate: Sat Dec 3 16:47:06 2016 +0000
Commit: Andrew Savchenko <bircoph <AT> gentoo <DOT> org>
CommitDate: Sat Dec 3 16:47:35 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d615f8f9
app-text/stardict: provide python tools as well
Package-Manager: portage-2.3.2
Signed-off-by: Andrew Savchenko <bircoph <AT> gentoo.org>
app-text/stardict/stardict-3.0.6-r3.ebuild | 24 ++++++++++++++++++++----
1 file changed, 20 insertions(+), 4 deletions(-)
diff --git a/app-text/stardict/stardict-3.0.6-r3.ebuild b/app-text/stardict/stardict-3.0.6-r3.ebuild
index e793103..aaf45c1 100644
--- a/app-text/stardict/stardict-3.0.6-r3.ebuild
+++ b/app-text/stardict/stardict-3.0.6-r3.ebuild
@@ -9,8 +9,9 @@ EAPI=6
# seperate for now.
GNOME2_LA_PUNT=yes
+PYTHON_COMPAT=( python2_7 )
-inherit flag-o-matic gnome2
+inherit flag-o-matic gnome2 python-single-r1
DESCRIPTION="A international dictionary supporting fuzzy and glob style matching"
HOMEPAGE="http://stardict-4.sourceforge.net/"
@@ -22,8 +23,8 @@ LICENSE="CPL-1.0 GPL-3 LGPL-2"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~sparc ~x86"
IUSE="advertisement debug dictdotcn espeak examples +gucharmap
-+htmlparse man perl +powerwordparse pronounce qqwry spell tools
-updateinfo +wikiparse +wordnet +xdxfparse"
++htmlparse man perl +powerwordparse pronounce python qqwry spell
+tools updateinfo +wikiparse +wordnet +xdxfparse"
RESTRICT="test"
@@ -41,6 +42,7 @@ COMMON_DEPEND="
dev-libs/libpcre:=
dev-libs/libxml2:=
virtual/mysql
+ python? ( ${PYTHON_DEPS} )
)
"
RDEPEND="${COMMON_DEPEND}
@@ -54,6 +56,7 @@ DEPEND="${COMMON_DEPEND}
sys-devel/gettext
virtual/pkgconfig
"
+REQUIRED_USE="tools? ( python? ( ${PYTHON_REQUIRED_USE} ) )"
# docs are messy, installed manually below
DOCS=""
@@ -68,6 +71,17 @@ src_prepare() {
# libsigc++ started to require c++11 support
append-cxxflags "-std=c++11"
+ if use python; then
+ local f
+ # force python shebangs handlable by python_doscript
+ for f in tools/src/*.py; do
+ [[ $(head -n1 "${f}") =~ ^#! ]] || continue
+ sed -i '1 s|.*|#!/usr/bin/python|' tools/src/*.py || die
+ done
+ # script contains UTF-8 symbols, but has no ecoding set
+ sed -i '1 a # -*- coding: utf-8 -*-' tools/src/uyghur2dict.py || die
+ fi
+
eapply_user
gnome2_src_prepare
}
@@ -147,6 +161,8 @@ src_install() {
${PN}-bin2text ${PN}-repair"
use perl && apps+=" dicts-dump.pl ncce2stardict.pl parse-oxford.perl"
+ use python && apps+=" hanzim2dict.py jm2stardict.py lingea-trd-decoder.py
+ makevietdict.py uyghur2dict.py"
for app in ${apps}; do
if [[ "${app}" =~ ^${PN} ]]; then
@@ -155,12 +171,12 @@ src_install() {
newbin "tools/src/${app}" "${PN}_${app}"
fi
done
+ use python && python_doscript "${ED}"usr/bin/*.py
docinto tools
dodoc tools/{AUTHORS,ChangeLog,README}
if use examples; then
- insinto tools
insinto /usr/share/doc/${PF}/tools
doins tools/src/{dictbuilder.{example,readme},example.ifo,example_treedict.tar.bz2}
fi
next reply other threads:[~2016-12-03 16:47 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-03 16:47 Andrew Savchenko [this message]
-- strict thread matches above, loose matches on Subject: below --
2023-05-06 14:18 [gentoo-commits] repo/gentoo:master commit in: app-text/stardict/ Sam James
2023-04-03 5:54 Sam James
2020-09-19 8:04 Michał Górny
2020-02-02 19:35 Mart Raudsepp
2018-08-25 14:45 Andrew Savchenko
2018-08-25 14:45 Andrew Savchenko
2018-08-25 14:45 Andrew Savchenko
2017-11-25 19:55 David Seifert
2017-01-03 21:22 Andrew Savchenko
2017-01-02 11:09 Andrew Savchenko
2017-01-02 11:09 Andrew Savchenko
2016-12-30 9:39 Agostino Sarubbo
2016-12-26 12:30 Aaron Bauman
2016-12-05 12:06 Andrew Savchenko
2016-12-05 12:06 Andrew Savchenko
2016-12-05 12:06 Andrew Savchenko
2016-12-05 12:06 Andrew Savchenko
2016-12-05 12:06 Andrew Savchenko
2016-12-05 12:06 Andrew Savchenko
2016-12-03 17:11 Andrew Savchenko
2016-12-03 16:47 Andrew Savchenko
2016-12-03 16:47 Andrew Savchenko
2016-12-03 16:47 Andrew Savchenko
2016-12-03 16:47 Andrew Savchenko
2016-12-02 7:14 Andrew Savchenko
2016-03-17 10:59 Michael Palimaka
2016-03-17 10:50 Agostino Sarubbo
2015-12-26 10:36 Agostino Sarubbo
2015-12-25 15:13 Agostino Sarubbo
2015-11-21 12:58 Pacho Ramos
2015-11-21 12:58 Pacho Ramos
2015-11-09 21:51 Pacho Ramos
2015-09-23 12:52 Agostino Sarubbo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1480783655.d615f8f9d771a4e52ea5d4a27ec2e0bdd37e0dcb.bircoph@gentoo \
--to=bircoph@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox