gnome-base/gnome-control-center: x86 stable wrt bug #717144
[gentoo.git] / gnome-base / gnome-vfs / gnome-vfs-2.24.4-r5.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5 GCONF_DEBUG="no"
6 GNOME_TARBALL_SUFFIX="bz2"
7 GNOME2_LA_PUNT="yes"
8
9 inherit autotools eutils gnome2 multilib-minimal virtualx
10
11 DESCRIPTION="Gnome Virtual Filesystem"
12 HOMEPAGE="https://www.gnome.org/"
13
14 LICENSE="GPL-2 LGPL-2"
15 SLOT="2"
16 KEYWORDS="~alpha amd64 arm ~arm64 ~ia64 ~mips ppc ppc64 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris ~x86-solaris"
17 IUSE="acl gnutls ipv6 kerberos libressl samba ssl zeroconf"
18
19 RDEPEND="
20         >=gnome-base/gconf-2.32.4-r1[${MULTILIB_USEDEP}]
21         >=dev-libs/glib-2.34.3[${MULTILIB_USEDEP}]
22         >=dev-libs/libxml2-2.9.1-r4[${MULTILIB_USEDEP}]
23         >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}]
24         gnome-base/gnome-mime-data
25         >=x11-misc/shared-mime-info-0.14
26         >=dev-libs/dbus-glib-0.100.2[${MULTILIB_USEDEP}]
27         acl? (
28                 >=sys-apps/acl-2.2.52-r1[${MULTILIB_USEDEP}]
29                 >=sys-apps/attr-2.4.47-r1[${MULTILIB_USEDEP}] )
30         kerberos? ( >=virtual/krb5-0-r1[${MULTILIB_USEDEP}] )
31         samba? ( >=net-fs/samba-3.6.23-r1[${MULTILIB_USEDEP}] )
32         ssl? (
33                 gnutls? (
34                         >=net-libs/gnutls-2.12.23-r6[${MULTILIB_USEDEP}]
35                         !gnome-extra/gnome-vfs-sftp )
36                 !gnutls? (
37                         !libressl? ( >=dev-libs/openssl-1.0.1h-r2:0=[${MULTILIB_USEDEP}] )
38                         libressl? ( dev-libs/libressl:=[${MULTILIB_USEDEP}] )
39                         !gnome-extra/gnome-vfs-sftp ) )
40         zeroconf? ( >=net-dns/avahi-0.6.31-r2[dbus,${MULTILIB_USEDEP}] )
41 "
42 DEPEND="${RDEPEND}
43         dev-util/glib-utils
44         sys-devel/gettext
45         gnome-base/gnome-common
46         >=dev-util/intltool-0.40
47         >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
48         >=dev-util/gtk-doc-am-1.13
49 "
50
51 PATCHES=(
52         # Allow the Trash on afs filesystems (#106118)
53         "${FILESDIR}"/${PN}-2.12.0-afs.patch
54
55         # Fix compiling with headers missing
56         "${FILESDIR}"/${PN}-2.15.2-headers-define.patch
57
58         # Fix for crashes running programs via sudo
59         "${FILESDIR}"/${PN}-2.16.0-no-dbus-crash.patch
60
61         # Fix automagic dependencies, upstream bug #493475
62         "${FILESDIR}"/${PN}-2.20.0-automagic-deps.patch
63         "${FILESDIR}"/${PN}-2.20.1-automagic-deps.patch
64
65         # Fix to identify ${HOME} (#200897)
66         # thanks to debian folks
67         "${FILESDIR}"/${PN}-2.24.4-home_dir_fakeroot.patch
68
69         # Configure with gnutls-2.7, bug #253729
70         # Fix building with gnutls-2.12, bug #388895
71         "${FILESDIR}"/${PN}-2.24.4-gnutls27.patch
72
73         # Prevent duplicated volumes, bug #193083
74         "${FILESDIR}"/${PN}-2.24.0-uuid-mount.patch
75
76         # Do not build tests with FEATURES="-test", bug #226221
77         "${FILESDIR}"/${PN}-2.24.4-build-tests-asneeded.patch
78
79         # Disable broken test, bug #285706
80         "${FILESDIR}"/${PN}-2.24.4-disable-test-async-cancel.patch
81
82         # Fix for automake-1.13 compatibility, #466944
83         "${FILESDIR}"/${P}-automake-1.13.patch
84
85         # Fix gnutls-3.4+ compatibility, #560084
86         # always use system defaults (patch from Arch Linux)
87         "${FILESDIR}"/${P}-gnutls34.patch
88
89         # Fix build with openssl-1.1 #592540
90         "${FILESDIR}"/${PN}-2.24.4-openssl-1.1.patch
91 )
92
93 src_prepare() {
94         epatch "${PATCHES[@]}"
95
96         sed -e "s/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/" -i configure.in || die
97
98         eautoreconf
99         gnome2_src_prepare
100 }
101
102 multilib_src_configure() {
103         local myconf=(
104                 --disable-schemas-install
105                 --disable-static
106                 --disable-cdda
107                 --disable-fam
108                 --disable-hal
109                 --disable-howl
110                 $(use_enable acl)
111                 $(use_enable gnutls)
112                 $(use_enable ipv6)
113                 $(use_enable kerberos krb5)
114                 $(use_enable samba)
115                 $(use_enable ssl openssl)
116                 $(use_enable zeroconf avahi)
117                 # Useless ? --enable-http-neon
118
119                 # fix path to krb5-config
120                 KRB5_CONFIG=/usr/bin/${CHOST}-krb5-config
121         )
122
123         # this works because of the order of configure parsing
124         # so should always be behind the use_enable options
125         # foser <foser@gentoo.org 19 Apr 2004
126         use gnutls && use ssl && myconf+=( --disable-openssl )
127
128         #bug #519060
129         #configure script is so messed up on res_init on Darwin
130         [[ ${CHOST} == *-darwin* ]] && export LIBS="${LIBS} -lresolv"
131
132         ECONF_SOURCE=${S} \
133         gnome2_src_configure "${myconf[@]}"
134
135         if multilib_is_native_abi; then
136                 ln -s "${S}"/doc/html doc/html || die
137         fi
138 }
139
140 multilib_src_test() {
141         unset DISPLAY
142         # Fix bug #285706
143         unset XAUTHORITY
144         Xemake check
145 }
146
147 multilib_src_install() {
148         gnome2_src_install
149 }
150
151 multilib_src_install_all() {
152         DOCS="AUTHORS ChangeLog HACKING NEWS README TODO"
153         einstalldocs
154 }