Line 0
Link Here
|
0 |
- |
1 |
# Copyright 1999-2021 Gentoo Authors |
|
|
2 |
# Distributed under the terms of the GNU General Public License v2 |
3 |
|
4 |
EAPI=7 |
5 |
|
6 |
inherit desktop optfeature prefix xdg |
7 |
|
8 |
DESCRIPTION="Feature-rich screenshot program" |
9 |
HOMEPAGE="https://shutter-project.org/" |
10 |
SRC_URI="https://github.com/shutter-project/shutter/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
11 |
|
12 |
LICENSE="GPL-3" |
13 |
SLOT="0" |
14 |
KEYWORDS="~amd64 ~x86" |
15 |
|
16 |
RDEPEND=" |
17 |
dev-lang/perl |
18 |
dev-perl/gnome2-canvas |
19 |
dev-perl/gnome2-wnck |
20 |
dev-perl/libxml-perl |
21 |
dev-perl/libwww-perl |
22 |
dev-perl/Glib-Object-Introspection |
23 |
dev-perl/Gtk2-Unique |
24 |
dev-perl/Gtk2-ImageView |
25 |
dev-perl/File-DesktopEntry |
26 |
dev-perl/File-HomeDir |
27 |
dev-perl/File-Which |
28 |
dev-perl/JSON |
29 |
dev-perl/File-Copy-Recursive |
30 |
dev-perl/File-MimeInfo |
31 |
dev-perl/Locale-gettext |
32 |
dev-perl/Net-DBus |
33 |
dev-perl/Number-Bytes-Human |
34 |
dev-perl/Proc-Simple |
35 |
dev-perl/Proc-ProcessTable |
36 |
dev-perl/Sort-Naturally |
37 |
dev-perl/WWW-Mechanize |
38 |
dev-perl/X11-Protocol |
39 |
dev-perl/XML-Simple |
40 |
virtual/imagemagick-tools[perl] |
41 |
" |
42 |
|
43 |
src_prepare() { |
44 |
hprefixify bin/shutter |
45 |
default |
46 |
} |
47 |
|
48 |
src_install() { |
49 |
dobin bin/shutter |
50 |
dodoc README |
51 |
domenu share/applications/shutter.desktop |
52 |
doicon share/pixmaps/shutter.png |
53 |
doman share/man/man1/shutter.1 |
54 |
|
55 |
insinto /usr/share |
56 |
doins -r share/shutter |
57 |
doins -r share/locale |
58 |
doins -r share/icons |
59 |
|
60 |
insinto /usr/share/metainfo |
61 |
doins share/appdata/shutter.appdata.xml |
62 |
|
63 |
# .po doesn't belong to installed system, only .mo |
64 |
rm -r "${ED}"/usr/share/shutter/resources/po || die |
65 |
|
66 |
# shutter executes perl scripts as standalone scripts, and after that "require"s them. |
67 |
find "${ED}"/usr/share/shutter/resources/system/plugins/ -type f ! -name '*.*' -exec chmod 755 {} \; \ |
68 |
|| die "failed to make plugins executables" |
69 |
find "${ED}"/usr/share/shutter/resources/system/upload_plugins/upload -type f \ |
70 |
-name "*.pm" -exec chmod 755 {} \; || die "failed to make upload plugins executables" |
71 |
} |
72 |
|
73 |
pkg_postinst() { |
74 |
xdg_pkg_postinst |
75 |
|
76 |
elog "To get additional features, optional runtime dependencies may be installed:" |
77 |
optfeature "writing Exif information" media-libs/exiftool |
78 |
optfeature "drawing tool" dev-perl/Goo-Canvas |
79 |
optfeature "image hostings uploading" "dev-perl/JSON-MaybeXS dev-perl/Net-OAuth dev-perl/Path-Class" |
80 |
} |