/[gentoo-x86]/net-misc/plowshare/plowshare-0.9.2.ebuild
Gentoo

Contents of /net-misc/plowshare/plowshare-0.9.2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Sun Jul 25 12:13:49 2010 UTC (9 years, 4 months ago) by volkmar
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
Version bump to 0.9.3 and removing old ebuilds.
Fix bug 322997.
(Portage version: 2.1.8.3/cvs/Linux i686)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/plowshare/plowshare-0.9.2.ebuild,v 1.2 2010/06/03 23:26:03 volkmar Exp $
4
5 EAPI="2"
6
7 DESCRIPTION="Command-line downloader and uploader for file-sharing websites"
8 HOMEPAGE="http://code.google.com/p/plowshare/"
9 SRC_URI="http://${PN}.googlecode.com/files/${P}.tgz"
10
11 LICENSE="GPL-3"
12 SLOT="0"
13 KEYWORDS="~amd64 ~ppc ~x86"
14 IUSE="examples +javascript +perl view-captcha"
15
16 RDEPEND="
17 javascript? ( dev-lang/spidermonkey )
18 perl? ( dev-lang/perl
19 media-gfx/imagemagick[perl] )
20 view-captcha? ( || ( media-gfx/aview media-libs/libcaca ) )
21 app-shells/bash
22 app-text/recode
23 app-text/tesseract[tiff]
24 || ( app-text/tesseract[linguas_en] >=app-text/tesseract-2.04-r1 )
25 || ( media-gfx/imagemagick[tiff] media-gfx/graphicsmagick[imagemagick,tiff] )
26 net-misc/curl
27 sys-apps/util-linux"
28 DEPEND=""
29
30 # NOTES:
31 # spidermonkey dep should be any javascript interpreter using /usr/bin/js
32 # linguas_en is a workaround for bug 287373 and bug 297991
33
34 # TODO:
35 # dev-java/rhino could probably be an alternative for spidermonkey
36
37 src_prepare() {
38 if ! use javascript; then
39 sed -i -e 's:^\(MODULES=".*\)mediafire:\1:' \
40 -e 's:^\(MODULES=".*\)zshare:\1:' \
41 src/{delete,download,list,upload}.sh || die "sed failed"
42 rm src/modules/{mediafire,zshare}.sh || die "rm failed"
43 fi
44 if ! use perl; then
45 sed -i -e 's:^\(MODULES=\".*\)netload_in:\1:' \
46 -e 's:^\(MODULES=\".*\)loadfiles:\1:' \
47 src/{delete,download,list,upload}.sh || die "sed failed"
48 rm src/modules/netload_in.sh || die "rm failed"
49 fi
50 }
51
52 src_test() {
53 # don't use test_modules.sh because it needs a working internet connection
54 if ! use perl; then
55 sed -i -e "s:\(.*\.pl\):#\1:" test/test_lib.sh || die "sed failed"
56 fi
57 ./test/test_lib.sh || die "test failed"
58 }
59
60 src_install() {
61 insinto /usr/share/${PN}
62 doins src/lib.sh || die "doins failed"
63
64 if use perl; then
65 doins src/strip_single_color.pl || die "doins failed"
66 fi
67
68 insinto /usr/share/${PN}/modules
69 doins -r src/modules/* || die "doins failed"
70
71 insinto /usr/share/${PN}/tesseract
72 doins -r src/tesseract/* || die "doins failed"
73
74 exeinto /usr/share/${PN}
75 doexe src/{delete,download,list,upload}.sh || die "doexe failed"
76
77 dosym /usr/share/${PN}/delete.sh /usr/bin/plowdel
78 dosym /usr/share/${PN}/download.sh /usr/bin/plowdown
79 dosym /usr/share/${PN}/list.sh /usr/bin/plowlist
80 dosym /usr/share/${PN}/upload.sh /usr/bin/plowup
81
82 dodoc CHANGELOG README || die "dodoc failed"
83
84 doman docs/plow{del,down,list,up}.1 || die "doman failed"
85
86 if use examples; then
87 insinto /usr/share/doc/${PF}/examples
88 doins examples/plowdown_{add_remote_loop,loop,parallel}.sh \
89 || die "doins failed"
90 fi
91 }
92
93 pkg_postinst() {
94 if ! use javascript; then
95 ewarn "Without javascript you will not be able to use zshare and mediafire"
96 fi
97 if ! use perl; then
98 ewarn "Without perl you will not be able to use netload.in"
99 fi
100 }

  ViewVC Help
Powered by ViewVC 1.1.20