Gentoo Archives: gentoo-commits

From: Andreas Sturmlechner <asturm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-office/libreoffice/files/, app-office/libreoffice/
Date: Tue, 29 Oct 2019 17:39:36
Message-Id: 1572370609.421194839bf05e5af9c02f1a6ec343ba1f575374.asturm@gentoo
1 commit: 421194839bf05e5af9c02f1a6ec343ba1f575374
2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
3 AuthorDate: Tue Oct 29 17:29:17 2019 +0000
4 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
5 CommitDate: Tue Oct 29 17:36:49 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=42119483
7
8 app-office/libreoffice: 6.3.3.2 version bump
9
10 Closes: https://bugs.gentoo.org/698504
11 Package-Manager: Portage-2.3.76, Repoman-2.3.16
12 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
13
14 app-office/libreoffice/Manifest | 2 +
15 .../libreoffice-6.3.3.2-mysql-connector-c-8.patch | 45 ++
16 app-office/libreoffice/libreoffice-6.3.3.2.ebuild | 553 +++++++++++++++++++++
17 3 files changed, 600 insertions(+)
18
19 diff --git a/app-office/libreoffice/Manifest b/app-office/libreoffice/Manifest
20 index fb1e34f891c..78da4892a63 100644
21 --- a/app-office/libreoffice/Manifest
22 +++ b/app-office/libreoffice/Manifest
23 @@ -7,8 +7,10 @@ DIST libreoffice-6.2.5.2.tar.xz 215008848 BLAKE2B 5dd1ef185820944816e01c8ed6a787
24 DIST libreoffice-6.2.7.1.tar.xz 215022744 BLAKE2B 717acc3c310d3d973464b422176ccb4aae1481f2537c419e3afd031a2c2967a7b20b4cc5b60499befcae279441176a275f339e65534c4eb9d7395c6e050ba6e3 SHA512 9ed37c7957bb214a3de0b3dadea9debd5056d641052a669904d543a7065f1f5c721e09ddda800dfb478ff0474f71a275c7208077cb7b6566786d3b637f42860b
25 DIST libreoffice-6.2.8.2.tar.xz 215070800 BLAKE2B d6bc1e94de1df4dd20dafaeac9702435f305fe15117e8aee02233c6d2e74423bb475aeaf79ff6dcd30e22d69a5d6f0648218819b08003524a2c7b1db340281c4 SHA512 cf1dd708f10ea4b9a3134851cad45fe91c1d535e2b2068f7e65f1cb1bf4076c5c41ec253f628c5b912590e91ccfe16f5c8bcf39bc92df2ec7c8aef84210349bd
26 DIST libreoffice-6.3.2.2.tar.xz 224752776 BLAKE2B 397d125714ae591d174ea185a488ecb652946de76d015c4ffb85e1c27ed34f87b5808ac41309b52fba117aab67097a0c378284721f0e5f3eb8e3284c799ed8dd SHA512 f0576f5a5b2c91ee6c003cbf9772580c564e05f66c3b34ddee4b723095aaa3a55070df3d70d7e6b8be68e23a7e204c1237496d7e798f9494282cadba0eacf930
27 +DIST libreoffice-6.3.3.2.tar.xz 224944844 BLAKE2B 16d58d1b34f6a7da5a9cb32dade8f15ce074f516b77d6481f1befec75572f2533f3ae19964ce2688ff121789241a11823f05768b3386bc755f015a243af6c55a SHA512 4809ce26c48419e1e8408bdd71e7aeec3940bad150afeb90034013fbe8757c37417da3a996f8935aac3103806e14bd47dee7e560051d6718a75e6b869a2b1934
28 DIST libreoffice-branding-gentoo-0.8.tar.xz 151568 BLAKE2B f03c7ddeb53c5ca3fd23401679601fcf2c4037ba17be4eb7b784c7ce7ebb71a24b8ab4aac8b7da8c6b1f14dd23bc1294ba85ff4f70ad271fb4ee3c5372e10883 SHA512 785031a699b1d1895ce4b50ffc3ddf645f3a0ef9acdf37facfd18cf75db9484cb8f53a50abb63d6006ead76a80b6ff5aa99661063245ebb84bd64013d713de7f
29 DIST libreoffice-help-6.2.5.2.tar.xz 13023680 BLAKE2B f1f3a03104c1270e59f2b9130a29e1fbc99a9bf76b2bf4cedef8dc61487c9a2036f143501ad7fcd0c056c8b72446305b7a4ca9a719b11200ade5feca35e5e7ea SHA512 14f964161bd827a5846ec667ae1dac80d1485450e172da44010103e31f3872df62595e8b1b1d45c720caac9256d2adaf8f5a0bb80d059d35f1c560b533eb764c
30 DIST libreoffice-help-6.2.7.1.tar.xz 13024328 BLAKE2B fcdb01a52abb90773baa96b0c25fc04bf928e13b940a5cadd7eb455a3004f83d339252346d7c615fbe511cee7e093560c99bf6ff6bd2e5e832d57d4d1053ebc6 SHA512 b4599bf6854efa800483cf16132c9809ea439d29ea63c7621a0f04ce19609a7a1966d86862342f911cde22a3bd19fe5b96ad9bdb34d5255eb716352a8ce9bbaa
31 DIST libreoffice-help-6.2.8.2.tar.xz 13024032 BLAKE2B 524ba3ff77670afeddddbf8be4724b5e54f9b157582cfcac8640e2184b8ae24c8e5e01b924415949f1756c18e2d54b8eab7efb78c979321e50b6d52b741ddd49 SHA512 c1f5b1b3c50da0a47a9724c9fc3544a15b7df72e66c5c2008afeae7732e2b29f0e57e64ce9a216c3237acdb4345715525f32be290f3196ba6e28685fa6c0925c
32 DIST libreoffice-help-6.3.2.2.tar.xz 13192064 BLAKE2B 83c742faa698370e1561133d4c7351619639b343068691d830433ff5dfa4af20ba7f89428b67275f7f19c947dd84e4c03aa330e4ddd684dbd19acee14e842ba9 SHA512 34f34abbd21e37ea6f8ed860af27bbd641cb98331f235b84c5b5cc4e3fa01d9f43a32469f5df4f4cf4dde0e804ba12e73fdd6d357413d5d7641c32396abf09f1
33 +DIST libreoffice-help-6.3.3.2.tar.xz 13192080 BLAKE2B 108f33d77ec24ac5f5b669aae72dc23f0ae1800038d9028a3c92b6dfbe09003cb6d9f89a6675162c8cb058ac850a0e7c5544f8692c527cfa83bd32ba28149a50 SHA512 c4d994c4047aeee5e35207228e2b62ccc7d7303ae8fcbfb52cbf73950f232ad8d45953ee364379d3834e79c59ab79df920ec624ebe4b7214f955c2bd89af7cee
34
35 diff --git a/app-office/libreoffice/files/libreoffice-6.3.3.2-mysql-connector-c-8.patch b/app-office/libreoffice/files/libreoffice-6.3.3.2-mysql-connector-c-8.patch
36 new file mode 100644
37 index 00000000000..5fa7b343f4f
38 --- /dev/null
39 +++ b/app-office/libreoffice/files/libreoffice-6.3.3.2-mysql-connector-c-8.patch
40 @@ -0,0 +1,45 @@
41 +From 5917ba8bc645a2b105ec089101b8a664481b5b61 Mon Sep 17 00:00:00 2001
42 +From: Peter Levine <plevine457@×××××.com>
43 +Date: Thu, 17 Oct 2019 23:08:57 -0400
44 +Subject: Fix building against MySQL Connector/C 8
45 +
46 +In MySQL Connector/C 8, my_bool is replaced by bool. It was
47 +previously defined as char. When building against
48 +MySQL Connector/C 8, this leads to type punning build errors.
49 +Redefine affected members of struct BindMetaData as bool if using
50 +version 8 of greater. Otherwise, default to char.
51 +
52 +Change-Id: If12b975d95afae86502867cb334cb4195802f91d
53 +Reviewed-on: https://gerrit.libreoffice.org/81002
54 +Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@×××.de>
55 +Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@×××.de>
56 +---
57 + .../source/drivers/mysqlc/mysqlc_preparedstatement.hxx | 10 ++++++++--
58 + 1 file changed, 8 insertions(+), 2 deletions(-)
59 +
60 +diff --git a/connectivity/source/drivers/mysqlc/mysqlc_preparedstatement.hxx b/connectivity/source/drivers/mysqlc/mysqlc_preparedstatement.hxx
61 +index 1df2c70..3450473 100644
62 +--- a/connectivity/source/drivers/mysqlc/mysqlc_preparedstatement.hxx
63 ++++ b/connectivity/source/drivers/mysqlc/mysqlc_preparedstatement.hxx
64 +@@ -39,11 +39,17 @@ using ::com::sun::star::uno::Reference;
65 + using ::com::sun::star::uno::RuntimeException;
66 + using ::com::sun::star::uno::Type;
67 +
68 ++#if defined MYSQL_VERSION_ID && (MYSQL_VERSION_ID >= 80000) && !defined MARIADB_BASE_VERSION
69 ++using my_bool = bool;
70 ++#else
71 ++using my_bool = char;
72 ++#endif
73 ++
74 + struct BindMetaData
75 + {
76 +- char is_null = 0;
77 ++ my_bool is_null = 0;
78 + unsigned long length = 0;
79 +- char error = 0;
80 ++ my_bool error = 0;
81 + };
82 +
83 + typedef ::cppu::ImplHelper5<css::sdbc::XPreparedStatement, css::sdbc::XParameters,
84 +--
85 +cgit v1.1
86
87 diff --git a/app-office/libreoffice/libreoffice-6.3.3.2.ebuild b/app-office/libreoffice/libreoffice-6.3.3.2.ebuild
88 new file mode 100644
89 index 00000000000..0233e28a4fb
90 --- /dev/null
91 +++ b/app-office/libreoffice/libreoffice-6.3.3.2.ebuild
92 @@ -0,0 +1,553 @@
93 +# Copyright 1999-2019 Gentoo Authors
94 +# Distributed under the terms of the GNU General Public License v2
95 +
96 +EAPI=7
97 +
98 +PYTHON_COMPAT=( python2_7 python3_{5,6,7} )
99 +PYTHON_REQ_USE="threads(+),xml"
100 +
101 +MY_PV="${PV/_alpha/.alpha}"
102 +MY_PV="${MY_PV/_beta/.beta}"
103 +# experimental ; release ; old
104 +# Usually the tarballs are moved a lot so this should make everyone happy.
105 +DEV_URI="
106 + https://dev-builds.libreoffice.org/pre-releases/src
107 + https://download.documentfoundation.org/libreoffice/src/${MY_PV:0:5}/
108 + https://downloadarchive.documentfoundation.org/libreoffice/old/${MY_PV}/src
109 +"
110 +ADDONS_URI="https://dev-www.libreoffice.org/src/"
111 +
112 +BRANDING="${PN}-branding-gentoo-0.8.tar.xz"
113 +# PATCHSET="${P}-patchset-01.tar.xz"
114 +
115 +[[ ${MY_PV} == *9999* ]] && inherit git-r3
116 +inherit autotools bash-completion-r1 check-reqs flag-o-matic java-pkg-opt-2 multiprocessing python-single-r1 qmake-utils toolchain-funcs xdg-utils
117 +
118 +DESCRIPTION="A full office productivity suite"
119 +HOMEPAGE="https://www.libreoffice.org"
120 +SRC_URI="branding? ( https://dev.gentoo.org/~dilfridge/distfiles/${BRANDING} )"
121 +[[ -n ${PATCHSET} ]] && SRC_URI+=" https://dev.gentoo.org/~asturm/distfiles/${PATCHSET}"
122 +
123 +# Split modules following git/tarballs; Core MUST be first!
124 +# Help is used for the image generator
125 +# Only release has the tarballs
126 +if [[ ${MY_PV} != *9999* ]]; then
127 + for i in ${DEV_URI}; do
128 + SRC_URI+=" ${i}/${PN}-${MY_PV}.tar.xz"
129 + SRC_URI+=" ${i}/${PN}-help-${MY_PV}.tar.xz"
130 + done
131 + unset i
132 +fi
133 +unset DEV_URI
134 +
135 +# Really required addons
136 +# These are bundles that can't be removed for now due to huge patchsets.
137 +# If you want them gone, patches are welcome.
138 +ADDONS_SRC=(
139 + "java? ( ${ADDONS_URI}/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip )"
140 + # no release for 8 years, should we package it?
141 + "libreoffice_extensions_wiki-publisher? ( ${ADDONS_URI}/a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip )"
142 + # Does not build with 1.6 rhino at all
143 + "libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip )"
144 + # requirement of rhino
145 + "libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/35c94d2df8893241173de1d16b6034c0-swingExSrc.zip )"
146 + # not packageable
147 + "odk? ( http://download.go-oo.org/extern/185d60944ea767075d27247c3162b3bc-unowinreg.dll )"
148 +)
149 +SRC_URI+=" ${ADDONS_SRC[*]}"
150 +
151 +unset ADDONS_URI
152 +unset ADDONS_SRC
153 +
154 +# Extensions that need extra work:
155 +LO_EXTS="nlpsolver scripting-beanshell scripting-javascript wiki-publisher"
156 +
157 +IUSE="accessibility bluetooth +branding coinmp +cups dbus debug eds firebird
158 +googledrive gstreamer +gtk gtk2 kde ldap +mariadb odk pdfimport postgres test
159 +$(printf 'libreoffice_extensions_%s ' ${LO_EXTS})"
160 +
161 +REQUIRED_USE="${PYTHON_REQUIRED_USE}
162 + bluetooth? ( dbus )
163 + libreoffice_extensions_nlpsolver? ( java )
164 + libreoffice_extensions_scripting-beanshell? ( java )
165 + libreoffice_extensions_scripting-javascript? ( java )
166 + libreoffice_extensions_wiki-publisher? ( java )
167 +"
168 +
169 +LICENSE="|| ( LGPL-3 MPL-1.1 )"
170 +SLOT="0"
171 +[[ ${MY_PV} == *9999* ]] || \
172 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x86-linux"
173 +
174 +BDEPEND="
175 + dev-util/intltool
176 + sys-devel/bison
177 + sys-devel/flex
178 + sys-devel/gettext
179 + virtual/pkgconfig
180 + odk? ( >=app-doc/doxygen-1.8.4 )
181 +"
182 +COMMON_DEPEND="${PYTHON_DEPS}
183 + app-arch/unzip
184 + app-arch/zip
185 + app-crypt/gpgme[cxx]
186 + app-text/hunspell:=
187 + >=app-text/libabw-0.1.0
188 + >=app-text/libebook-0.1
189 + app-text/libepubgen
190 + >=app-text/libetonyek-0.1
191 + app-text/libexttextcat
192 + app-text/liblangtag
193 + >=app-text/libmspub-0.1.0
194 + >=app-text/libmwaw-0.3.1
195 + app-text/libnumbertext
196 + >=app-text/libodfgen-0.1.0
197 + app-text/libqxp
198 + app-text/libstaroffice
199 + app-text/libwpd:0.10[tools]
200 + app-text/libwpg:0.3
201 + >=app-text/libwps-0.4
202 + app-text/mythes
203 + >=dev-cpp/clucene-2.3.3.4-r2
204 + >=dev-cpp/libcmis-0.5.2
205 + dev-db/unixODBC
206 + dev-lang/perl
207 + dev-libs/boost:=[nls]
208 + dev-libs/expat
209 + dev-libs/hyphen
210 + dev-libs/icu:=
211 + dev-libs/libassuan
212 + dev-libs/libgpg-error
213 + >=dev-libs/liborcus-0.14.0
214 + dev-libs/librevenge
215 + dev-libs/libxml2
216 + dev-libs/libxslt
217 + dev-libs/nspr
218 + dev-libs/nss
219 + >=dev-libs/redland-1.0.16
220 + >=dev-libs/xmlsec-1.2.28[nss]
221 + media-gfx/fontforge
222 + media-gfx/graphite2
223 + media-libs/fontconfig
224 + media-libs/freetype:2
225 + >=media-libs/harfbuzz-0.9.42:=[graphite,icu]
226 + media-libs/lcms:2
227 + >=media-libs/libcdr-0.1.0
228 + >=media-libs/libepoxy-1.3.1[X]
229 + >=media-libs/libfreehand-0.1.0
230 + media-libs/libpagemaker
231 + >=media-libs/libpng-1.4:0=
232 + >=media-libs/libvisio-0.1.0
233 + media-libs/libzmf
234 + net-libs/neon
235 + net-misc/curl
236 + sci-mathematics/lpsolve
237 + sys-libs/zlib
238 + virtual/glu
239 + virtual/jpeg:0
240 + virtual/opengl
241 + x11-libs/cairo[X]
242 + x11-libs/libXinerama
243 + x11-libs/libXrandr
244 + x11-libs/libXrender
245 + accessibility? ( dev-python/lxml[${PYTHON_USEDEP}] )
246 + bluetooth? (
247 + dev-libs/glib:2
248 + net-wireless/bluez
249 + )
250 + coinmp? ( sci-libs/coinor-mp )
251 + cups? ( net-print/cups )
252 + dbus? ( sys-apps/dbus )
253 + eds? (
254 + dev-libs/glib:2
255 + gnome-base/dconf
256 + gnome-extra/evolution-data-server
257 + )
258 + firebird? ( >=dev-db/firebird-3.0.2.32703.0-r1[server] )
259 + gstreamer? (
260 + media-libs/gstreamer:1.0
261 + media-libs/gst-plugins-base:1.0
262 + )
263 + gtk? (
264 + dev-libs/glib:2
265 + dev-libs/gobject-introspection
266 + gnome-base/dconf
267 + media-libs/mesa[egl]
268 + x11-libs/gtk+:3
269 + x11-libs/pango
270 + )
271 + gtk2? (
272 + x11-libs/gdk-pixbuf
273 + >=x11-libs/gtk+-2.24:2
274 + x11-libs/pango
275 + )
276 + kde? (
277 + dev-qt/qtcore:5
278 + dev-qt/qtgui:5
279 + dev-qt/qtwidgets:5
280 + dev-qt/qtx11extras:5
281 + kde-frameworks/kconfig:5
282 + kde-frameworks/kcoreaddons:5
283 + kde-frameworks/ki18n:5
284 + kde-frameworks/kio:5
285 + kde-frameworks/kwindowsystem:5
286 + )
287 + ldap? ( net-nds/openldap )
288 + libreoffice_extensions_scripting-beanshell? ( dev-java/bsh )
289 + libreoffice_extensions_scripting-javascript? ( dev-java/rhino:1.6 )
290 + mariadb? ( dev-db/mariadb-connector-c )
291 + !mariadb? ( dev-db/mysql-connector-c )
292 + pdfimport? ( app-text/poppler:=[cxx] )
293 + postgres? ( >=dev-db/postgresql-9.0:*[kerberos] )
294 +"
295 +# FIXME: cppunit should be moved to test conditional
296 +# after everything upstream is under gbuild
297 +# as dmake execute tests right away
298 +# tests apparently also need google-carlito-fonts (not packaged)
299 +DEPEND="${COMMON_DEPEND}
300 + >=dev-libs/libatomic_ops-7.2d
301 + dev-perl/Archive-Zip
302 + >=dev-util/cppunit-1.14.0
303 + >=dev-util/gperf-3.1
304 + >=dev-util/mdds-1.4.1:1=
305 + media-libs/glm
306 + sys-devel/ucpp
307 + x11-base/xorg-proto
308 + x11-libs/libXt
309 + x11-libs/libXtst
310 + java? (
311 + dev-java/ant-core
312 + >=virtual/jdk-1.6
313 + )
314 + test? (
315 + app-crypt/gnupg
316 + dev-util/cppunit
317 + media-fonts/dejavu
318 + media-fonts/liberation-fonts
319 + )
320 +"
321 +RDEPEND="${COMMON_DEPEND}
322 + !app-office/libreoffice-bin
323 + !app-office/libreoffice-bin-debug
324 + !app-office/openoffice
325 + media-fonts/liberation-fonts
326 + || ( x11-misc/xdg-utils kde-plasma/kde-cli-tools )
327 + java? ( >=virtual/jre-1.6 )
328 + kde? ( kde-frameworks/breeze-icons:* )
329 +"
330 +if [[ ${MY_PV} != *9999* ]] && [[ ${PV} != *_* ]]; then
331 + PDEPEND="=app-office/libreoffice-l10n-$(ver_cut 1-2)*"
332 +else
333 + # Translations are not reliable on live ebuilds
334 + # rather force people to use english only.
335 + PDEPEND="!app-office/libreoffice-l10n"
336 +fi
337 +
338 +PATCHES=(
339 + # "${WORKDIR}"/${PATCHSET/.tar.xz/}
340 +
341 + # not upstreamable stuff
342 + "${FILESDIR}/${PN}-5.4-system-pyuno.patch"
343 + "${FILESDIR}/${PN}-5.3.4.2-kioclient5.patch"
344 + "${FILESDIR}/${PN}-6.1-nomancompress.patch"
345 +
346 + # master branch
347 + "${FILESDIR}/${P}-mysql-connector-c-8.patch" # bug #692422
348 +)
349 +
350 +S="${WORKDIR}/${PN}-${MY_PV}"
351 +
352 +_check_reqs() {
353 + CHECKREQS_MEMORY="512M"
354 + if is-flagq "-g*" && ! is-flagq "-g*0" ; then
355 + CHECKREQS_DISK_BUILD="22G"
356 + else
357 + CHECKREQS_DISK_BUILD="6G"
358 + fi
359 + check-reqs_$1
360 +}
361 +
362 +pkg_pretend() {
363 + if ! use java && ! use firebird; then
364 + ewarn "If you plan to use Base application you must enable either firebird or java."
365 + fi
366 +
367 + use java || ewarn "Without java, several wizards are not going to be available."
368 +
369 + if has_version "<app-office/libreoffice-5.3.0[firebird]"; then
370 + ewarn "Firebird has been upgraded to version 3. It is unable to read back Firebird 2.5 data, so"
371 + ewarn "embedded firebird odb files created in LibreOffice pre-5.3 can't be opened with this version."
372 + ewarn "See also: https://wiki.documentfoundation.org/ReleaseNotes/5.3#Base"
373 + fi
374 +
375 + [[ ${MERGE_TYPE} != binary ]] && _check_reqs pkg_pretend
376 +}
377 +
378 +pkg_setup() {
379 + java-pkg-opt-2_pkg_setup
380 + python-single-r1_pkg_setup
381 + xdg_environment_reset
382 +
383 + [[ ${MERGE_TYPE} != binary ]] && _check_reqs pkg_setup
384 +}
385 +
386 +src_unpack() {
387 + default
388 +
389 + if [[ ${MY_PV} = *9999* ]]; then
390 + local base_uri branch mypv
391 + base_uri="https://anongit.freedesktop.org/git"
392 + branch="master"
393 + mypv=${MY_PV/.9999}
394 + [[ ${mypv} != ${MY_PV} ]] && branch="${PN}-${mypv/./-}"
395 + git-r3_fetch "${base_uri}/${PN}/core" "refs/heads/${branch}"
396 + git-r3_checkout "${base_uri}/${PN}/core"
397 + LOCOREGIT_VERSION=${EGIT_VERSION}
398 +
399 + git-r3_fetch "${base_uri}/${PN}/help" "refs/heads/master"
400 + git-r3_checkout "${base_uri}/${PN}/help" "helpcontent2" # doesn't match on help
401 + fi
402 +}
403 +
404 +src_prepare() {
405 + default
406 +
407 + # sandbox violations on many systems, we don't need it. Bug #646406
408 + sed -i \
409 + -e "/KF5_CONFIG/s/kf5-config/no/" \
410 + configure.ac || die "Failed to disable kf5-config"
411 +
412 + AT_M4DIR="m4" eautoreconf
413 + # hack in the autogen.sh
414 + touch autogen.lastrun
415 +
416 + # system pyuno mess
417 + sed -i \
418 + -e "s:%eprefix%:${EPREFIX}:g" \
419 + -e "s:%libdir%:$(get_libdir):g" \
420 + pyuno/source/module/uno.py \
421 + pyuno/source/officehelper.py || die
422 + # sed in the tests
423 + sed -i \
424 + -e "s#all : build unitcheck#all : build#g" \
425 + solenv/gbuild/Module.mk || die
426 + sed -i \
427 + -e "s#check: dev-install subsequentcheck#check: unitcheck slowcheck dev-install subsequentcheck#g" \
428 + -e "s#Makefile.gbuild all slowcheck#Makefile.gbuild all#g" \
429 + Makefile.in || die
430 +
431 + sed -i \
432 + -e "s,/usr/share/bash-completion/completions,$(get_bashcompdir)," \
433 + -e "s,\$INSTALLDIRNAME.sh,${PN}," \
434 + bin/distro-install-desktop-integration || die
435 +
436 + if use branding; then
437 + # hack...
438 + mv -v "${WORKDIR}/branding-intro.png" "icon-themes/colibre/brand/intro.png" || die
439 + fi
440 +
441 + # Don't list pdfimport support in desktop when built with none, bug # 605464
442 + if ! use pdfimport; then
443 + sed -i \
444 + -e ":MimeType: s:application/pdf;::" \
445 + -e ":Keywords: s:pdf;::" \
446 + sysui/desktop/menus/draw.desktop || die
447 + fi
448 +}
449 +
450 +src_configure() {
451 + # Set up Google API keys, see https://www.chromium.org/developers/how-tos/api-keys
452 + # Note: these are for Gentoo use ONLY. For your own distribution, please get
453 + # your own set of keys. Feel free to contact chromium@g.o for more info.
454 + local google_default_client_id="329227923882.apps.googleusercontent.com"
455 + local google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu"
456 +
457 + # optimization flags
458 + export GMAKE_OPTIONS="${MAKEOPTS}"
459 + # System python enablement:
460 + export PYTHON_CFLAGS=$(python_get_CFLAGS)
461 + export PYTHON_LIBS=$(python_get_LIBS)
462 +
463 + if use kde; then
464 + export QT_SELECT=5 # bug 639620 needs proper fix though
465 + export QT5DIR="$(qt5_get_bindir)/../"
466 + export MOC5="$(qt5_get_bindir)/moc"
467 + fi
468 +
469 + local gentoo_buildid="Gentoo official package"
470 + if [[ -n ${LOCOREGIT_VERSION} ]]; then
471 + gentoo_buildid+=" (from git: ${LOCOREGIT_VERSION})"
472 + fi
473 +
474 + # system headers/libs/...: enforce using system packages
475 + # --disable-breakpad: requires not-yet-in-tree dev-utils/breakpad
476 + # --enable-cairo: ensure that cairo is always required
477 + # --enable-*-link: link to the library rather than just dlopen on runtime
478 + # --enable-release-build: build the libreoffice as release
479 + # --disable-fetch-external: prevent dowloading during compile phase
480 + # --enable-extension-integration: enable any extension integration support
481 + # --without-{fonts,myspell-dicts,ppsd}: prevent install of sys pkgs
482 + # --disable-report-builder: too much java packages pulled in without pkgs
483 + # --without-system-sane: just sane.h header that is used for scan in writer,
484 + # not linked or anything else, worthless to depend on
485 + # --disable-pdfium: not yet packaged
486 + local myeconfargs=(
487 + --with-system-dicts
488 + --with-system-epoxy
489 + --with-system-headers
490 + --with-system-jars
491 + --with-system-libs
492 + --enable-build-opensymbol
493 + --enable-cairo-canvas
494 + --enable-largefile
495 + --enable-mergelibs
496 + --enable-neon
497 + --enable-python=system
498 + --enable-randr
499 + --enable-release-build
500 + --disable-breakpad
501 + --disable-bundle-mariadb
502 + --disable-ccache
503 + --disable-dependency-tracking
504 + --disable-epm
505 + --disable-fetch-external
506 + --disable-gstreamer-0-10
507 + --disable-gtk3-kde5
508 + --disable-online-update
509 + --disable-openssl
510 + --disable-pdfium
511 + --disable-report-builder
512 + --disable-vlc
513 + --with-build-version="${gentoo_buildid}"
514 + --enable-extension-integration
515 + --with-external-dict-dir="${EPREFIX}/usr/share/myspell"
516 + --with-external-hyph-dir="${EPREFIX}/usr/share/myspell"
517 + --with-external-thes-dir="${EPREFIX}/usr/share/myspell"
518 + --with-external-tar="${DISTDIR}"
519 + --with-lang=""
520 + --with-parallelism=$(makeopts_jobs)
521 + --with-system-ucpp
522 + --with-tls=nss
523 + --with-vendor="Gentoo Foundation"
524 + --with-x
525 + --without-fonts
526 + --without-myspell-dicts
527 + --with-help="html"
528 + --without-helppack-integration
529 + --with-system-gpgmepp
530 + --without-system-sane
531 + $(use_enable bluetooth sdremote-bluetooth)
532 + $(use_enable coinmp)
533 + $(use_enable cups)
534 + $(use_enable dbus)
535 + $(use_enable debug)
536 + $(use_enable eds evolution2)
537 + $(use_enable firebird firebird-sdbc)
538 + $(use_enable gstreamer gstreamer-1-0)
539 + $(use_enable gtk gtk3)
540 + $(use_enable gtk2 gtk)
541 + $(use_enable kde kde5)
542 + $(use_enable kde qt5)
543 + $(use_enable ldap)
544 + $(use_enable odk)
545 + $(use_enable pdfimport)
546 + $(use_enable postgres postgresql-sdbc)
547 + $(use_with accessibility lxml)
548 + $(use_with coinmp system-coinmp)
549 + $(use_with googledrive gdrive-client-id ${google_default_client_id})
550 + $(use_with googledrive gdrive-client-secret ${google_default_client_secret})
551 + $(use_with java)
552 + $(use_with odk doxygen)
553 + )
554 +
555 + if use eds || use gtk; then
556 + myeconfargs+=( --enable-dconf --enable-gio )
557 + else
558 + myeconfargs+=( --disable-dconf --disable-gio )
559 + fi
560 +
561 + # libreoffice extensions handling
562 + for lo_xt in ${LO_EXTS}; do
563 + if [[ "${lo_xt}" == "scripting-beanshell" || "${lo_xt}" == "scripting-javascript" ]]; then
564 + myeconfargs+=( $(use_enable libreoffice_extensions_${lo_xt} ${lo_xt}) )
565 + else
566 + myeconfargs+=( $(use_enable libreoffice_extensions_${lo_xt} ext-${lo_xt}) )
567 + fi
568 + done
569 +
570 + if use java; then
571 + # hsqldb: system one is too new
572 + myeconfargs+=(
573 + --without-junit
574 + --without-system-hsqldb
575 + --with-ant-home="${ANT_HOME}"
576 + --with-jdk-home=$(java-config --jdk-home 2>/dev/null)
577 + --with-jvm-path="${EPREFIX}/usr/lib/"
578 + )
579 +
580 + use libreoffice_extensions_scripting-beanshell && \
581 + myeconfargs+=( --with-beanshell-jar=$(java-pkg_getjar bsh bsh.jar) )
582 +
583 + use libreoffice_extensions_scripting-javascript && \
584 + myeconfargs+=( --with-rhino-jar=$(java-pkg_getjar rhino-1.6 js.jar) )
585 + fi
586 +
587 + is-flagq "-flto*" && myeconfargs+=( --enable-lto )
588 +
589 + MARIADBCONFIG="$(type -p $(usex mariadb mariadb mysql)_config)" \
590 + econf "${myeconfargs[@]}"
591 +}
592 +
593 +src_compile() {
594 + # more and more LO stuff tries to use OpenGL, including tests during build
595 + # bug 501508, bug 540624, bug 545974 and probably more
596 + addpredict /dev/dri
597 + addpredict /dev/ati
598 + addpredict /dev/nvidiactl
599 +
600 + local target
601 + use test && target="build" || target="build-nocheck"
602 +
603 + # this is not a proper make script
604 + make ${target} || die
605 +}
606 +
607 +src_test() {
608 + make unitcheck || die
609 + make slowcheck || die
610 +}
611 +
612 +src_install() {
613 + # This is not Makefile so no buildserver
614 + make DESTDIR="${D}" distro-pack-install -o build -o check || die
615 +
616 + # bug 593514
617 + if use gtk; then
618 + dosym libreoffice/program/liblibreofficekitgtk.so \
619 + /usr/$(get_libdir)/liblibreofficekitgtk.so
620 + fi
621 +
622 + # bash completion aliases
623 + bashcomp_alias \
624 + libreoffice \
625 + unopkg loimpress lobase localc lodraw lomath lowriter lofromtemplate loweb loffice
626 +
627 + if use branding; then
628 + insinto /usr/$(get_libdir)/${PN}/program
629 + newins "${WORKDIR}/branding-sofficerc" sofficerc
630 + dodir /etc/env.d
631 + echo "CONFIG_PROTECT=/usr/$(get_libdir)/${PN}/program/sofficerc" > "${ED}"/etc/env.d/99${PN} || die
632 + fi
633 +}
634 +
635 +pkg_postinst() {
636 + xdg_icon_cache_update
637 + xdg_desktop_database_update
638 + xdg_mimeinfo_database_update
639 +}
640 +
641 +pkg_postrm() {
642 + xdg_icon_cache_update
643 + xdg_desktop_database_update
644 + xdg_mimeinfo_database_update
645 +}