gnome-base/gnome-light-3.26.2: restore ~alpha keyword
[gentoo.git] / gnome-base / nautilus / nautilus-3.34.2.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 inherit gnome.org gnome2-utils meson readme.gentoo-r1 virtualx xdg
7
8 DESCRIPTION="Default file manager for the GNOME desktop"
9 HOMEPAGE="https://wiki.gnome.org/Apps/Nautilus"
10
11 LICENSE="GPL-3+ LGPL-2.1+"
12 SLOT="0"
13 IUSE="gnome +gstreamer gtk-doc +introspection packagekit +previewer selinux sendto"
14
15 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
16
17 DEPEND="
18         >=dev-libs/glib-2.58.1:2
19         >=media-libs/gexiv2-0.10.0
20         gstreamer? ( media-libs/gstreamer:1.0
21                 media-libs/gst-plugins-base:1.0 )
22         >=app-arch/gnome-autoar-0.2.1
23         >=gnome-base/gnome-desktop-3.0.0:3=
24         >=x11-libs/gtk+-3.22.27:3[X,introspection?]
25         >=x11-libs/pango-1.28.3
26         selinux? ( >=sys-libs/libselinux-2.0 )
27         >=app-misc/tracker-2.0:=
28         x11-libs/libX11
29         >=dev-libs/libxml2-2.7.8:2
30         introspection? ( >=dev-libs/gobject-introspection-1.54:= )
31 "
32 RDEPEND="${DEPEND}
33         packagekit? ( app-admin/packagekit-base )
34         sendto? ( !<gnome-extra/nautilus-sendto-3.0.1 )
35         gstreamer? ( !<media-video/totem-3.31.91[nautilus] )
36         >=app-misc/tracker-miners-2.0:=
37 " # uses org.freedesktop.Tracker.Miner.Files gsettings schema from tracker-miners
38 BDEPEND="
39         >=dev-util/gdbus-codegen-2.51.2
40         dev-util/glib-utils
41         gtk-doc? (
42                 >=dev-util/gtk-doc-1.10
43                 app-text/docbook-xml-dtd:4.1.2 )
44         >=sys-devel/gettext-0.19.8
45         virtual/pkgconfig
46         x11-base/xorg-proto
47 "
48 PDEPEND="
49         gnome? ( x11-themes/adwaita-icon-theme )
50         previewer? ( >=gnome-extra/sushi-0.1.9 )
51         sendto? ( >=gnome-extra/nautilus-sendto-3.0.1 )
52         >=gnome-base/gvfs-1.14[gtk(+)]
53 " # Need gvfs[gtk] for recent:/// support; always built (without USE=gtk) since gvfs-1.34
54
55 PATCHES=(
56         "${FILESDIR}"/3.30.5-docs-build.patch # Always install pregenerated manpage, keeping docs option for gtk-doc
57         "${FILESDIR}"/3.32.3-optional-gstreamer.patch # Allow controlling audio-video-properties build
58         "${FILESDIR}"/${PV}-pango-1.42-compat.patch
59 )
60
61 src_prepare() {
62         if use previewer; then
63                 DOC_CONTENTS="nautilus uses gnome-extra/sushi to preview media files.
64                         To activate the previewer, select a file and press space; to
65                         close the previewer, press space again."
66         fi
67         xdg_src_prepare
68 }
69
70 src_configure() {
71         local emesonargs=(
72                 $(meson_use gtk-doc docs)
73                 -Dextensions=true # image file properties, sendto support; also required for -Dgstreamer=true
74                 $(meson_use gstreamer) # gstreamer audio-video-properties extension
75                 $(meson_use introspection)
76                 $(meson_use packagekit)
77                 $(meson_use selinux)
78                 -Dprofiling=false
79                 -Dtests=$(usex test all none)
80         )
81         meson_src_configure
82 }
83
84 src_install() {
85         use previewer && readme.gentoo_create_doc
86         meson_src_install
87 }
88
89 src_test() {
90         virtx meson_src_test
91 }
92
93 pkg_postinst() {
94         xdg_pkg_postinst
95         gnome2_schemas_update
96
97         if use previewer; then
98                 readme.gentoo_print_elog
99         else
100                 elog "To preview media files, emerge nautilus with USE=previewer"
101         fi
102 }
103
104 pkg_postrm() {
105         xdg_pkg_postrm
106         gnome2_schemas_update
107 }