Gentoo Archives: gentoo-commits

From: Andrey Utkin <andrey_utkin@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-im/swift/
Date: Tue, 27 Nov 2018 19:20:22
Message-Id: 1543346250.6deb11e4f07463dd58a521697b395e5ad5ce2e54.andrey_utkin@gentoo
1 commit: 6deb11e4f07463dd58a521697b395e5ad5ce2e54
2 Author: Conrad Kostecki <conrad <AT> kostecki <DOT> com>
3 AuthorDate: Tue Nov 27 19:03:12 2018 +0000
4 Commit: Andrey Utkin <andrey_utkin <AT> gentoo <DOT> org>
5 CommitDate: Tue Nov 27 19:17:30 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6deb11e4
7
8 net-im/swift: disable experimental option
9
10 For some users, net-im/swift crashes directly, when experimental is
11 active. According to upstream, this should be anyway disabled.
12 But experimental_ft stays enabled, since according to upstream, it is
13 considered stable, they have only forgotten to remove experimental from
14 it's name. Besides, it's needed for net-im/spectrum2.
15
16 Many thanks for testing goes to Martin Samek <mr <AT> vmsc.eu>
17
18 Closes: https://bugs.gentoo.org/671826
19 Package-Manager: Portage-2.3.52, Repoman-2.3.12
20 Signed-off-by: Conrad Kostecki <conrad <AT> kostecki.com>
21 Signed-off-by: Andrey Utkin <andrey_utkin <AT> gentoo.org>
22
23 net-im/swift/swift-4.0.2-r1.ebuild | 207 +++++++++++++++++++++++++++++++++++++
24 1 file changed, 207 insertions(+)
25
26 diff --git a/net-im/swift/swift-4.0.2-r1.ebuild b/net-im/swift/swift-4.0.2-r1.ebuild
27 new file mode 100644
28 index 00000000000..1fdb1c0dd08
29 --- /dev/null
30 +++ b/net-im/swift/swift-4.0.2-r1.ebuild
31 @@ -0,0 +1,207 @@
32 +# Copyright 1999-2018 Gentoo Authors
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=6
36 +
37 +inherit gnome2-utils scons-utils toolchain-funcs
38 +
39 +DESCRIPTION="An elegant, secure, adaptable and intuitive XMPP Client"
40 +HOMEPAGE="https://www.swift.im/"
41 +SRC_URI="https://swift.im/downloads/releases/${P}/${P}.tar.gz"
42 +
43 +LICENSE="BSD BSD-1 CC-BY-3.0 GPL-3 OFL-1.1"
44 +SLOT="4/0"
45 +KEYWORDS="~amd64"
46 +IUSE="client expat gconf +icu +idn lua spell test zeroconf"
47 +REQUIRED_USE="
48 + || ( icu idn )
49 + gconf? ( client )
50 + spell? ( client )
51 +"
52 +
53 +RDEPEND="
54 + dev-db/sqlite:3
55 + dev-libs/boost:=
56 + dev-libs/openssl:0=
57 + net-libs/libnatpmp
58 + net-libs/miniupnpc:=
59 + sys-libs/zlib:=
60 + client? (
61 + dev-qt/qtcore:5
62 + dev-qt/qtdbus:5
63 + dev-qt/qtgui:5
64 + dev-qt/qtmultimedia:5
65 + dev-qt/qtnetwork:5
66 + dev-qt/qtsvg:5
67 + dev-qt/qtwidgets:5
68 + dev-qt/qtwebkit:5
69 + dev-qt/qtx11extras:5
70 + net-dns/avahi
71 + )
72 + expat? ( dev-libs/expat )
73 + !expat? ( dev-libs/libxml2:2 )
74 + gconf? ( gnome-base/gconf:2 )
75 + icu? ( dev-libs/icu:= )
76 + idn? ( net-dns/libidn:= )
77 + lua? ( dev-lang/lua:= )
78 + spell? ( app-text/hunspell:= )
79 +"
80 +
81 +DEPEND="
82 + ${RDEPEND}
83 + >=dev-util/scons-3.0.1-r3
84 + client? ( dev-qt/linguist-tools:5 )
85 + test? ( net-dns/avahi )
86 +"
87 +
88 +# Tests don't run, as they fail with "[QA/UnitTest/**dummy**] Error -6".
89 +RESTRICT="test"
90 +
91 +DOCS=(
92 + "DEVELOPMENT.md"
93 + "README.md"
94 + "Swiften/ChangeLog.md"
95 +)
96 +
97 +PATCHES=(
98 + "${FILESDIR}"/${P}-make-generated-files-handle-unicode-characters.patch
99 + "${FILESDIR}"/${P}-qt-5.11-compatibility.patch
100 +)
101 +
102 +src_prepare() {
103 + default
104 +
105 + # Hack for finding Qt system libs
106 + mkdir "${T}"/qt || die
107 + ln -s "${EPREFIX%/}"/usr/$(get_libdir)/qt5/bin "${T}"/qt/bin || die
108 + ln -s "${EPREFIX%/}"/usr/$(get_libdir)/qt5 "${T}"/qt/lib || die
109 + ln -s "${EPREFIX%/}"/usr/include/qt5 "${T}"/qt/include || die
110 +
111 + # Remove parts of Swift, which a user don't want to compile
112 + if ! use client; then rm -fr Swift Slimber || die; fi
113 + if ! use lua; then rm -fr Sluift || die; fi
114 + if ! use zeroconf; then
115 + rm -fr Limber || die
116 + if use client; then rm -fr Slimber || die; fi
117 + fi
118 +
119 + # Remove '3rdParty', as the system libs should be used
120 + # `CppUnit`, `GoogleTest` and `HippoMocks` are needed for tests
121 + local my3rdparty=(
122 + Boost
123 + Breakpad
124 + DocBook
125 + Expat
126 + LCov
127 + Ldns
128 + LibIDN
129 + LibMiniUPnPc
130 + LibNATPMP
131 + Lua
132 + OpenSSL
133 + SCons
134 + SQLite
135 + Unbound
136 + ZLib
137 + )
138 +
139 + if use test; then
140 + cd 3rdParty && rm -fr "${my3rdparty[@]}" || die
141 + else
142 + rm -fr 3rdParty || die
143 + fi
144 +}
145 +
146 +src_configure() {
147 + MYSCONS=(
148 + ar="$(tc-getAR)"
149 + allow_warnings="yes"
150 + assertions="no"
151 + build_examples="yes"
152 + boost_bundled_enable="false"
153 + boost_force_bundled="false"
154 + cc="$(tc-getCC)"
155 + ccache="no"
156 + ccflags="${CFLAGS}"
157 + coverage="no"
158 + cxx="$(tc-getCXX)"
159 + cxxflags="${CXXFLAGS}"
160 + debug="no"
161 + distcc="no"
162 + experimental="no"
163 + experimental_ft="yes"
164 + hunspell_enable="$(usex spell)"
165 + icu="$(usex icu)"
166 + install_git_hooks="no"
167 + libidn_bundled_enable="false"
168 + libminiupnpc_force_bundled="false"
169 + libnatpmp_force_bundled="false"
170 + link="$(tc-getCXX)"
171 + linkflags="${LDFLAGS}"
172 + max_jobs="no"
173 + optimize="no"
174 + qt="${T}/qt"
175 + qt5="$(usex client)"
176 + swiften_dll="true"
177 + swift_mobile="no"
178 + target="native"
179 + test="none"
180 + try_avahi="$(usex client)"
181 + try_expat="$(usex expat)"
182 + try_gconf="$(usex gconf)"
183 + try_libidn="$(usex idn)"
184 + try_libxml="$(usex !expat)"
185 + tls_backend="openssl"
186 + unbound="no"
187 + V="1"
188 + valgrind="no"
189 + zlib_bundled_enable="false"
190 + )
191 +}
192 +
193 +src_compile() {
194 + local myesconsinstall=(
195 + Swiften
196 + $(usex client Swift '')
197 + $(usex lua Sluift '')
198 + $(usex zeroconf Limber '')
199 + $(usex zeroconf "$(usex client Slimber '')" '')
200 + )
201 +
202 + escons "${MYSCONS[@]}" "${myesconsinstall[@]}"
203 +}
204 +
205 +src_test() {
206 + MYSCONS=(
207 + V="1"
208 + )
209 +
210 + escons "${MYSCONS[@]}" test=unit QA
211 +}
212 +
213 +src_install() {
214 + local myesconsinstall=(
215 + SWIFTEN_INSTALLDIR="${ED%/}/usr"
216 + SWIFTEN_LIBDIR="${ED%/}/usr/$(get_libdir)"
217 + $(usex client "SWIFT_INSTALLDIR=${ED%/}/usr" '')
218 + $(usex lua "SLUIFT_DIR=${ED%/}/usr" '')
219 + $(usex lua "SLUIFT_INSTALLDIR=${ED%/}/usr" '')
220 + "${ED}"
221 + )
222 +
223 + escons "${MYSCONS[@]}" "${myesconsinstall[@]}"
224 +
225 + use zeroconf && dobin Limber/limber
226 + use zeroconf && use client && newbin Slimber/CLI/slimber slimber-cli
227 + use zeroconf && use client && newbin Slimber/Qt/slimber slimber-qt
228 +
229 + einstalldocs
230 +}
231 +
232 +pkg_postinst() {
233 + use client && gnome2_icon_cache_update
234 +}
235 +
236 +pkg_postrm() {
237 + use client && gnome2_icon_cache_update
238 +}