Gentoo Archives: gentoo-commits

From: "Andreas Hüttel" <dilfridge@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-office/libreoffice/files/, app-office/libreoffice/
Date: Sat, 28 Nov 2015 00:13:26
Message-Id: 1448669507.bc39edf16bae36a38856a164a2aac92fc80f579a.dilfridge@gentoo
1 commit: bc39edf16bae36a38856a164a2aac92fc80f579a
2 Author: Andreas K. Huettel (dilfridge) <dilfridge <AT> gentoo <DOT> org>
3 AuthorDate: Sat Nov 28 00:11:47 2015 +0000
4 Commit: Andreas Hüttel <dilfridge <AT> gentoo <DOT> org>
5 CommitDate: Sat Nov 28 00:11:47 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bc39edf1
7
8 app-office/libreoffice: Remove old
9
10 Package-Manager: portage-2.2.25
11
12 app-office/libreoffice/Manifest | 4 -
13 ...breoffice-4.4.0.3-gcc-4.9-Os-link-failure.patch | 80 ---
14 ...ibreoffice-4.4.1.2-improve-KDE4FilePicker.patch | 192 -------
15 app-office/libreoffice/libreoffice-4.4.5.2.ebuild | 618 ---------------------
16 app-office/libreoffice/libreoffice-5.0.2.2.ebuild | 607 --------------------
17 5 files changed, 1501 deletions(-)
18
19 diff --git a/app-office/libreoffice/Manifest b/app-office/libreoffice/Manifest
20 index cf5d401..6b7786a 100644
21 --- a/app-office/libreoffice/Manifest
22 +++ b/app-office/libreoffice/Manifest
23 @@ -6,12 +6,8 @@ DIST 4b87018f7fff1d054939d19920b751a0-collada2gltf-master-cb1d97788a.tar.bz2 555
24 DIST 798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip 1521926 SHA256 1fb458d6aab06932693cc8a9b6e4e70944ee1ff052fa63606e3131df34e21753 SHA512 ec5ae23c8fe2f5efc377f7a9665039afadf28b4d8f2791379296766a5fbc9a3bf7548f9b0e3b3b07762229ec733a92ccbb69791ee0318c9c6f78f8e847253d3f WHIRLPOOL 8e446eb44188046b0e90694feba232f42c2e9f13d0f43783a18de37c94b86ff919b994931125c5d8001ecd320c1f4db5da482847304aa61646600a3bb33144b4
25 DIST a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip 23150 SHA256 75823776fb51a9c526af904f1503a7afaaab900fba83eda64f8a41073724c870 SHA512 2d3835f7ac356805025cafedcad97faa48d0f5da386e6ac7b7451030059df8e2fdb0861ade07a576ebf9fb5b88a973585ab0437944b06aac9289d6898ba8586a WHIRLPOOL 60b98d9af2c83c0cf12a5a60ba30957d335b8b967cac07971e1edbc787b9caecd4b3c5bb480e8b38fe8109c1cf74439ebafae130c976182c2c15399f38f5d28c
26 DIST d62650a6f908e85643e557a236ea989c-vigra1.6.0.tar.gz 16525605 SHA256 1f188ac03a8aa4663223eca8c82f91a55293d066d67127082e29a7dba1a98c9f SHA512 d08a7fe432e8df47d1d8992a45bb5f33149cb75b90eb74b2f2e457628d21a94b17eae0045096b053d2a866bf7710c775581c3e417b5dfaf66601aa18071b7305 WHIRLPOOL 95dc6ec0fb293c3538c1d51241283edf4e21647dcfd10229233ab7c3f13f7c78e6bb02c4d292a7cd2a2ec95575d775f0395e837bbc88ab4ddbaa5adfd62be2f0
27 -DIST libreoffice-4.4.5.2.tar.xz 164472672 SHA256 3aeb4f08918c6ca6ec12fc47c2be690d2180c2e41cc3136b6ed36185b89cec0d SHA512 15abecb02d8ca478cb7d006834c8670b9e42d3e5d8ec772e9a1d805dbd2ef1145092d1d4e3a6531f21eeb75210c1354e91c4d3abeec97103ad4c3092b7b7273b WHIRLPOOL a06c9e520e6f2b40c90cb703689527faf9ed6dbe0c0c3810ad276933daa21d56465c286d3de0fe6d5330be7968ae77cff1d30151d62fb34cc7fb57535e82edd6
28 DIST libreoffice-4.4.6.3.tar.xz 164742068 SHA256 3f1bd66fedc34d60448f74e864c1cb79c3e44aeadbd1d0bb9544011d29f422ac SHA512 ffdbe9b46622d30b176f3120e84cd9bd3d0ea35b2759e1886bc3038455bf63a09305cc9c6ceba9e02a6279e12859c78e689ddfe02d60585115ebb0d3787db8bd WHIRLPOOL 9ce888415d9366e0402ac9d6bbb189d41a9bf42aa49bd8b1c90ef9071fbdb5ce4da7bd7029efcf538fd6cf4ec412d246e943b29cffbbd53499d50065103e2566
29 -DIST libreoffice-5.0.2.2.tar.xz 166869100 SHA256 01f0680709432039762fa608bcb1240786d2b6549099a96095aab92dcebbc176 SHA512 7a72ed01b0f9fc131b7241ea4d1bb70bc813752e33d8e823e91a769d77308d2eec2d32a0fac61bdb41fd605a6f91dbaa3d5478a0b150e64fa9f7e47724f46cce WHIRLPOOL 85a592a0f478b1957d22d932adee758d48084c0c7ee00c0549fa8c956fd30f5eead09f6fc802d22d9613bda8da0c708ec99fb6d10fd82e0922c6da96a326a14c
30 DIST libreoffice-5.0.3.2.tar.xz 167009360 SHA256 77f9c9569c1199d914f38afa01547c1874535c56ad74b19614a0afc3ad66d4bd SHA512 fe49577d26c2241a2e7d6f2e8faa25cacf77dc94dbe76f7dbbf1b208295695298d24842c73444b284e9af2a323b7536cce6727ffab0431ac22d80691a9902e62 WHIRLPOOL 2a907729d9f2b436a0206f558022d9ace69d494106e3c76f9c141d1202438ca7c662eca102595e8143cb4c70cece44447f99b1093e813249433684725f3287d0
31 DIST libreoffice-branding-gentoo-0.8.tar.xz 151568 SHA256 22722121be062742624e0634beae92289c75e6a99ed507d3bf0a05c5164e3c69 SHA512 785031a699b1d1895ce4b50ffc3ddf645f3a0ef9acdf37facfd18cf75db9484cb8f53a50abb63d6006ead76a80b6ff5aa99661063245ebb84bd64013d713de7f WHIRLPOOL 1f36652a52d501d6548cfa9aa013b3e3a1867aa2b0693d2274cf7816d4aa4e0cde3c7096cc71ed47cf74e5f96da2757bf537f553021f8fd86939accb227bf538
32 -DIST libreoffice-help-4.4.5.2.tar.xz 1876044 SHA256 66044aaff17cdf4d523ceea00197381bb50d4cb86359be83016a838c27761681 SHA512 0d75f41fa3a7593c621fb3cd6e7f94fe24cb5d5251e05f9e67f58e6603853cceb2b4df2cb28228e7bf464d053b5ce068bcae752bdf6ba977fdde20882540c869 WHIRLPOOL 2715278ed374f8850ccd79e94682cc003b69501c7863c84b3dc609b0377277fa523bc8eba41d8045bff344b1cc70f08171f8acc1aebb47914a4ac190ee66bc49
33 DIST libreoffice-help-4.4.6.3.tar.xz 1875828 SHA256 d3b18c7dc4c68d152c298498f014e82183ade008d9d64a74353df306b286818b SHA512 6871252079738c7c1a44a17dba6aa842411c1c0a7e92a92dcfa3afe0e314edf9ba4d277bacbc558cf26362e94ff1e8370c91a00f81aee697528ba359f5559a3c WHIRLPOOL 2383ce2bf9a52529d7a4d34e8eeb3ea3d74ec547375ab8cb5556e694519976121528019f53ebd287d07ef40dd19a946acdf469ce0b75301c4ed51fc0add6f6f0
34 -DIST libreoffice-help-5.0.2.2.tar.xz 1882964 SHA256 4342a5593ba8a33b1d63549f256a4127a0b51cc1a53faffdc2708f04fef5f094 SHA512 1000423578211dc843dcedb9f864634235ab09d5234f8d8fe2897065207bdf6cd3bca7cdc1b3c012de0c78b585978a25c0df5048779bd0b9a734c9160064e313 WHIRLPOOL 8b92bcd19487c1c286a477ff0dc1b7e6bd9aaf862cfe002fadc25d461add4c4f2f8ee1e45ac0426dc2d27a6322317cacb7f65e9d0a6e6d6dad01075d18476363
35 DIST libreoffice-help-5.0.3.2.tar.xz 1882292 SHA256 7e5535b8bd9be88170abdef187d3cf16d2cccdb1fdbd4404a22f1cff55bd953e SHA512 73de5507b0e7994a189d5580ad7bfdf842e9a3a10cc0a9bbe39eb11f20e47fa7016f6cf6748ad7c35260587cfc7078eaac6055b439292068a9d9783509bd715d WHIRLPOOL 1e7c79250a407c0eac5f1538290dfe1f04b22799bc04a295cd6dfbf0405dc4478283dea09ede52adf25077729852c11f9f74e98f257c47a8a30b350d83d532ac
36
37 diff --git a/app-office/libreoffice/files/libreoffice-4.4.0.3-gcc-4.9-Os-link-failure.patch b/app-office/libreoffice/files/libreoffice-4.4.0.3-gcc-4.9-Os-link-failure.patch
38 deleted file mode 100644
39 index 0f39688..0000000
40 --- a/app-office/libreoffice/files/libreoffice-4.4.0.3-gcc-4.9-Os-link-failure.patch
41 +++ /dev/null
42 @@ -1,80 +0,0 @@
43 -From 0e4b1d2127957459b79f41a96f1fa0061d399b3b Mon Sep 17 00:00:00 2001
44 -From: Michael Stahl <mstahl@××××××.com>
45 -Date: Sat, 14 Feb 2015 00:17:06 +0100
46 -Subject: tdf#78174: toolkit: work around GCC 4.9 -Os link failure
47 -
48 -A build with gcc (GCC) 4.9.2 20141101 (Red Hat 4.9.2-1) for 32-bit x86
49 -fails because of these undefined symbols:
50 -
51 -> nm --demangle workdir/CxxObject/svx/source/fmcomp/fmgridif.o | grep
52 - \\bWindowListenerMultiplexer::acquire
53 - U non-virtual thunk to WindowListenerMultiplexer::acquire()
54 -
55 -They should probably be generated inline. Work around by out-lining the
56 -definition of the methods.
57 -
58 -https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64812
59 -
60 -Change-Id: I318f7c39bdf1243be385bc6dc0a47862b22e92c5
61 -(cherry picked from commit 6b3aa0fe4094e87290bd33a30bd6cd99ee78ce38)
62 -Reviewed-on: https://gerrit.libreoffice.org/14509
63 -Reviewed-by: Miklos Vajna <vmiklos@××××××××××××.uk>
64 -Tested-by: Miklos Vajna <vmiklos@××××××××××××.uk>
65 -
66 -diff --git a/include/toolkit/helper/macros.hxx b/include/toolkit/helper/macros.hxx
67 -index e048e75..b212dff 100644
68 ---- a/include/toolkit/helper/macros.hxx
69 -+++ b/include/toolkit/helper/macros.hxx
70 -@@ -112,8 +112,8 @@ class ClassName : public ListenerMultiplexerBase, public InterfaceName \
71 - public: \
72 - ClassName( ::cppu::OWeakObject& rSource ); \
73 - ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; \
74 -- void SAL_CALL acquire() throw() SAL_OVERRIDE { ListenerMultiplexerBase::acquire(); } \
75 -- void SAL_CALL release() throw() SAL_OVERRIDE { ListenerMultiplexerBase::release(); } \
76 -+ void SAL_CALL acquire() throw() SAL_OVERRIDE; \
77 -+ void SAL_CALL release() throw() SAL_OVERRIDE; \
78 - void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
79 -
80 -
81 -@@ -124,8 +124,8 @@ class TOOLKIT_DLLPUBLIC ClassName : public ListenerMultiplexerBase, public Inter
82 - public: \
83 - ClassName( ::cppu::OWeakObject& rSource ); \
84 - ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; \
85 -- void SAL_CALL acquire() throw() SAL_OVERRIDE { ListenerMultiplexerBase::acquire(); } \
86 -- void SAL_CALL release() throw() SAL_OVERRIDE { ListenerMultiplexerBase::release(); } \
87 -+ void SAL_CALL acquire() throw() SAL_OVERRIDE; \
88 -+ void SAL_CALL release() throw() SAL_OVERRIDE; \
89 - void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
90 -
91 -
92 -@@ -140,6 +140,8 @@ ClassName::ClassName( ::cppu::OWeakObject& rSource ) \
93 - : ListenerMultiplexerBase( rSource ) \
94 - { \
95 - } \
96 -+void SAL_CALL ClassName::acquire() throw() { ListenerMultiplexerBase::acquire(); } \
97 -+void SAL_CALL ClassName::release() throw() { ListenerMultiplexerBase::release(); } \
98 - ::com::sun::star::uno::Any ClassName::queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) \
99 - { \
100 - ::com::sun::star::uno::Any aRet = ::cppu::queryInterface( rType, \
101 -diff --git a/toolkit/source/helper/listenermultiplexer.cxx b/toolkit/source/helper/listenermultiplexer.cxx
102 -index 797fad2..b109c5f 100644
103 ---- a/toolkit/source/helper/listenermultiplexer.cxx
104 -+++ b/toolkit/source/helper/listenermultiplexer.cxx
105 -@@ -47,6 +47,15 @@ EventListenerMultiplexer::EventListenerMultiplexer( ::cppu::OWeakObject& rSource
106 - {
107 - }
108 -
109 -+void SAL_CALL EventListenerMultiplexer::acquire() throw ()
110 -+{
111 -+ return ListenerMultiplexerBase::acquire();
112 -+}
113 -+void SAL_CALL EventListenerMultiplexer::release() throw ()
114 -+{
115 -+ return ListenerMultiplexerBase::release();
116 -+}
117 -+
118 - // ::com::sun::star::uno::XInterface
119 - ::com::sun::star::uno::Any EventListenerMultiplexer::queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception)
120 - {
121 ---
122 -cgit v0.10.2
123
124 diff --git a/app-office/libreoffice/files/libreoffice-4.4.1.2-improve-KDE4FilePicker.patch b/app-office/libreoffice/files/libreoffice-4.4.1.2-improve-KDE4FilePicker.patch
125 deleted file mode 100644
126 index 61e036e..0000000
127 --- a/app-office/libreoffice/files/libreoffice-4.4.1.2-improve-KDE4FilePicker.patch
128 +++ /dev/null
129 @@ -1,192 +0,0 @@
130 -Merged upstream commits:
131 -
132 -6fc55b9abd783b624241d56e34751ea495adbd7d "KDE4: actually apply file dialog operation mode"
133 -b613270a730ace29dd1b16b29be2222b34f34a5d "KDE4: improve default load and save dialog titles"
134 -
135 -
136 -diff -u b/vcl/unx/kde4/KDE4FilePicker.cxx b/vcl/unx/kde4/KDE4FilePicker.cxx
137 ---- b/vcl/unx/kde4/KDE4FilePicker.cxx
138 -+++ b/vcl/unx/kde4/KDE4FilePicker.cxx
139 -@@ -58,6 +58,8 @@
140 -
141 - #include "generic/geninst.h"
142 -
143 -+#include "svids.hrc"
144 -+
145 - using namespace ::com::sun::star;
146 - using namespace ::com::sun::star::ui::dialogs;
147 - using namespace ::com::sun::star::ui::dialogs::TemplateDescription;
148 -@@ -109,7 +111,6 @@
149 -
150 - KDE4FilePicker::KDE4FilePicker( const uno::Reference<uno::XComponentContext>& )
151 - : KDE4FilePicker_Base(_helperMutex)
152 -- , _resMgr( ResMgr::CreateResMgr("fps_office") )
153 - , allowRemoteUrls( false )
154 - {
155 - _extraControls = new QWidget();
156 -@@ -128,8 +129,7 @@
157 - #endif
158 -
159 - setMultiSelectionMode( false );
160 -- //default mode
161 -- _dialog->setOperationMode(KFileDialog::Opening);
162 -+ _dialog->setConfirmOverwrite( true );
163 -
164 - // XExecutableDialog functions
165 - connect( this, SIGNAL( setTitleSignal( const OUString & ) ),
166 -@@ -202,7 +202,6 @@
167 - SalYieldMutexReleaser aReleaser;
168 - return Q_EMIT cleanupProxySignal();
169 - }
170 -- delete _resMgr;
171 - delete _dialog;
172 - }
173 -
174 -@@ -524,6 +523,24 @@
175 - return toOUString(label);
176 - }
177 -
178 -+QString KDE4FilePicker::getResString( sal_Int16 aRedId )
179 -+{
180 -+ QString aResString;
181 -+
182 -+ if( aRedId < 0 )
183 -+ return aResString;
184 -+
185 -+ try
186 -+ {
187 -+ aResString = toQString(ResId(aRedId, *ImplGetResMgr()).toString());
188 -+ }
189 -+ catch(...)
190 -+ {
191 -+ }
192 -+
193 -+ return aResString.replace('~', '&');
194 -+}
195 -+
196 - void KDE4FilePicker::addCustomControl(sal_Int16 controlId)
197 - {
198 - QWidget* widget = 0;
199 -@@ -532,37 +549,37 @@
200 - switch (controlId)
201 - {
202 - case CHECKBOX_AUTOEXTENSION:
203 -- resId = STR_SVT_FILEPICKER_AUTO_EXTENSION;
204 -+ resId = STR_FPICKER_AUTO_EXTENSION;
205 - break;
206 - case CHECKBOX_PASSWORD:
207 -- resId = STR_SVT_FILEPICKER_PASSWORD;
208 -+ resId = STR_FPICKER_PASSWORD;
209 - break;
210 - case CHECKBOX_FILTEROPTIONS:
211 -- resId = STR_SVT_FILEPICKER_FILTER_OPTIONS;
212 -+ resId = STR_FPICKER_FILTER_OPTIONS;
213 - break;
214 - case CHECKBOX_READONLY:
215 -- resId = STR_SVT_FILEPICKER_READONLY;
216 -+ resId = STR_FPICKER_READONLY;
217 - break;
218 - case CHECKBOX_LINK:
219 -- resId = STR_SVT_FILEPICKER_INSERT_AS_LINK;
220 -+ resId = STR_FPICKER_INSERT_AS_LINK;
221 - break;
222 - case CHECKBOX_PREVIEW:
223 -- resId = STR_SVT_FILEPICKER_SHOW_PREVIEW;
224 -+ resId = STR_FPICKER_SHOW_PREVIEW;
225 - break;
226 - case CHECKBOX_SELECTION:
227 -- resId = STR_SVT_FILEPICKER_SELECTION;
228 -+ resId = STR_FPICKER_SELECTION;
229 - break;
230 - case PUSHBUTTON_PLAY:
231 -- resId = STR_SVT_FILEPICKER_PLAY;
232 -+ resId = STR_FPICKER_PLAY;
233 - break;
234 - case LISTBOX_VERSION:
235 -- resId = STR_SVT_FILEPICKER_VERSION;
236 -+ resId = STR_FPICKER_VERSION;
237 - break;
238 - case LISTBOX_TEMPLATE:
239 -- resId = STR_SVT_FILEPICKER_TEMPLATES;
240 -+ resId = STR_FPICKER_TEMPLATES;
241 - break;
242 - case LISTBOX_IMAGE_TEMPLATE:
243 -- resId = STR_SVT_FILEPICKER_IMAGE_TEMPLATE;
244 -+ resId = STR_FPICKER_IMAGE_TEMPLATE;
245 - break;
246 - case LISTBOX_VERSION_LABEL:
247 - case LISTBOX_TEMPLATE_LABEL:
248 -@@ -581,16 +598,7 @@
249 - case CHECKBOX_PREVIEW:
250 - case CHECKBOX_SELECTION:
251 - {
252 -- QString label;
253 --
254 -- if (_resMgr && resId != -1)
255 -- {
256 -- OUString s(ResId(resId, *_resMgr).toString());
257 -- label = toQString(s);
258 -- label.replace("~", "&");
259 -- }
260 --
261 -- widget = new QCheckBox(label, _extraControls);
262 -+ widget = new QCheckBox(getResString(resId), _extraControls);
263 -
264 - // the checkbox is created even for CHECKBOX_AUTOEXTENSION to simplify
265 - // code, but the checkbox is hidden and ignored
266 -@@ -719,8 +727,22 @@
267 - 1 );
268 - }
269 -
270 -- _dialog->setOperationMode(operationMode);
271 -- _dialog->setConfirmOverwrite(true);
272 -+ _dialog->setOperationMode( operationMode );
273 -+
274 -+ sal_Int16 resId = -1;
275 -+ switch (_dialog->operationMode())
276 -+ {
277 -+ case KFileDialog::Opening:
278 -+ resId = STR_FPICKER_OPEN;
279 -+ break;
280 -+ case KFileDialog::Saving:
281 -+ resId = STR_FPICKER_SAVE;
282 -+ break;
283 -+ default:
284 -+ break;
285 -+ }
286 -+
287 -+ _dialog->setCaption(getResString(resId));
288 - }
289 -
290 - void SAL_CALL KDE4FilePicker::cancel()
291 -only in patch2:
292 -unchanged:
293 ---- a/vcl/unx/kde4/KDE4FilePicker.hxx
294 -+++ b/vcl/unx/kde4/KDE4FilePicker.hxx
295 -@@ -41,8 +41,6 @@ class KFileDialog;
296 - class QWidget;
297 - class QLayout;
298 -
299 --class ResMgr;
300 --
301 - typedef ::cppu::WeakComponentImplHelper5
302 - < ::com::sun::star::ui::dialogs::XFilePicker2
303 - , ::com::sun::star::ui::dialogs::XFilePicker3
304 -@@ -61,8 +59,6 @@ protected:
305 -
306 - ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XFilePickerListener > m_xListener;
307 -
308 -- ResMgr *_resMgr;
309 --
310 - //the dialog to display
311 - KFileDialog* _dialog;
312 -
313 -@@ -225,6 +221,8 @@ private:
314 - //add a custom control widget to the file dialog
315 - void addCustomControl(sal_Int16 controlId);
316 -
317 -+ QString getResString( sal_Int16 aRedId );
318 -+
319 - private Q_SLOTS:
320 - void cleanupProxy();
321 - void checkProtocol();
322
323 diff --git a/app-office/libreoffice/libreoffice-4.4.5.2.ebuild b/app-office/libreoffice/libreoffice-4.4.5.2.ebuild
324 deleted file mode 100644
325 index 24f0563..0000000
326 --- a/app-office/libreoffice/libreoffice-4.4.5.2.ebuild
327 +++ /dev/null
328 @@ -1,618 +0,0 @@
329 -# Copyright 1999-2015 Gentoo Foundation
330 -# Distributed under the terms of the GNU General Public License v2
331 -# $Id$
332 -
333 -EAPI=5
334 -
335 -KDE_REQUIRED="optional"
336 -QT_MINIMAL="4.7.4"
337 -KDE_SCM="git"
338 -CMAKE_REQUIRED="never"
339 -
340 -PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
341 -PYTHON_REQ_USE="threads,xml"
342 -
343 -# experimental ; release ; old
344 -# Usually the tarballs are moved a lot so this should make
345 -# everyone happy.
346 -DEV_URI="
347 - http://dev-builds.libreoffice.org/pre-releases/src
348 - http://download.documentfoundation.org/libreoffice/src/${PV:0:5}/
349 - http://download.documentfoundation.org/libreoffice/old/${PV}/
350 -"
351 -EXT_URI="http://ooo.itc.hu/oxygenoffice/download/libreoffice"
352 -ADDONS_URI="http://dev-www.libreoffice.org/src/"
353 -
354 -BRANDING="${PN}-branding-gentoo-0.8.tar.xz"
355 -# PATCHSET="${P}-patchset-01.tar.xz"
356 -
357 -[[ ${PV} == *9999* ]] && SCM_ECLASS="git-r3"
358 -inherit base multiprocessing autotools bash-completion-r1 check-reqs eutils java-pkg-opt-2 kde4-base pax-utils python-single-r1 multilib toolchain-funcs flag-o-matic versionator ${SCM_ECLASS}
359 -unset SCM_ECLASS
360 -
361 -DESCRIPTION="LibreOffice, a full office productivity suite"
362 -HOMEPAGE="http://www.libreoffice.org"
363 -SRC_URI="branding? ( http://dev.gentoo.org/~dilfridge/distfiles/${BRANDING} )"
364 -[[ -n ${PATCHSET} ]] && SRC_URI+=" http://dev.gentooexperimental.org/~scarabeus/${PATCHSET}"
365 -
366 -# Split modules following git/tarballs
367 -# Core MUST be first!
368 -# Help is used for the image generator
369 -MODULES="core help"
370 -# Only release has the tarballs
371 -if [[ ${PV} != *9999* ]]; then
372 - for i in ${DEV_URI}; do
373 - for mod in ${MODULES}; do
374 - if [[ ${mod} == core ]]; then
375 - SRC_URI+=" ${i}/${P}.tar.xz"
376 - else
377 - SRC_URI+=" ${i}/${PN}-${mod}-${PV}.tar.xz"
378 - fi
379 - done
380 - unset mod
381 - done
382 - unset i
383 -fi
384 -unset DEV_URI
385 -
386 -# Really required addons
387 -# These are bundles that can't be removed for now due to huge patchsets.
388 -# If you want them gone, patches are welcome.
389 -ADDONS_SRC+=" ${ADDONS_URI}/d62650a6f908e85643e557a236ea989c-vigra1.6.0.tar.gz"
390 -ADDONS_SRC+=" ${ADDONS_URI}/1f24ab1d39f4a51faf22244c94a6203f-xmlsec1-1.2.14.tar.gz" # modifies source code
391 -ADDONS_SRC+=" collada? ( ${ADDONS_URI}/4b87018f7fff1d054939d19920b751a0-collada2gltf-master-cb1d97788a.tar.bz2 )"
392 -ADDONS_SRC+=" java? ( ${ADDONS_URI}/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip )"
393 -ADDONS_SRC+=" libreoffice_extensions_wiki-publisher? ( ${ADDONS_URI}/a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip )" # no release for 8 years, should we package it?
394 -ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip )" # Does not build with 1.6 rhino at all
395 -ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/35c94d2df8893241173de1d16b6034c0-swingExSrc.zip )" # requirement of rhino
396 -ADDONS_SRC+=" odk? ( http://download.go-oo.org/extern/185d60944ea767075d27247c3162b3bc-unowinreg.dll )" # not packageable
397 -SRC_URI+=" ${ADDONS_SRC}"
398 -
399 -unset ADDONS_URI
400 -unset EXT_URI
401 -unset ADDONS_SRC
402 -
403 -IUSE="bluetooth +branding coinmp collada +cups dbus debug eds firebird gltf gnome gstreamer
404 -+gtk gtk3 jemalloc kde mysql odk postgres telepathy test vlc"
405 -
406 -LO_EXTS="nlpsolver scripting-beanshell scripting-javascript wiki-publisher"
407 -# Unpackaged separate extensions:
408 -# diagram: lo has 0.9.5 upstream is weirdly patched 0.9.4 -> wtf?
409 -# hunart: only on ooo extensions -> fubared download path somewhere on sf
410 -# numbertext, typo, validator, watch-window: ^^
411 -# oooblogger: no homepage or anything
412 -# Extensions that need extra work:
413 -for lo_xt in ${LO_EXTS}; do
414 - IUSE+=" libreoffice_extensions_${lo_xt}"
415 -done
416 -unset lo_xt
417 -
418 -LICENSE="|| ( LGPL-3 MPL-1.1 )"
419 -SLOT="0"
420 -[[ ${PV} == *9999* ]] || \
421 -KEYWORDS="amd64 ~arm x86 ~amd64-linux ~x86-linux"
422 -
423 -COMMON_DEPEND="
424 - ${PYTHON_DEPS}
425 - app-arch/zip
426 - app-arch/unzip
427 - >=app-text/hunspell-1.3.2-r3
428 - app-text/mythes
429 - >=app-text/libabw-0.1.0
430 - >=app-text/libexttextcat-3.2
431 - >=app-text/libebook-0.1.1
432 - >=app-text/libetonyek-0.1.1
433 - app-text/liblangtag
434 - >=app-text/libmspub-0.1.0
435 - >=app-text/libmwaw-0.3.4
436 - >=app-text/libodfgen-0.1.0
437 - app-text/libwpd:0.10[tools]
438 - app-text/libwpg:0.3
439 - =app-text/libwps-0.3*
440 - >=app-text/poppler-0.16:=[xpdf-headers(+),cxx]
441 - >=dev-cpp/clucene-2.3.3.4-r2
442 - =dev-cpp/libcmis-0.5*
443 - dev-db/unixODBC
444 - >=dev-libs/boost-1.55:=
445 - dev-libs/expat
446 - >=dev-libs/hyphen-2.7.1
447 - >=dev-libs/icu-4.8.1.1:=
448 - =dev-libs/liborcus-0.7*
449 - >=dev-libs/librevenge-0.0.1
450 - >=dev-libs/nspr-4.8.8
451 - >=dev-libs/nss-3.12.9
452 - >=dev-lang/perl-5.0
453 - >=dev-libs/openssl-1.0.0d:0
454 - >=dev-libs/redland-1.0.16
455 - media-gfx/graphite2
456 - >=media-libs/fontconfig-2.8.0
457 - media-libs/freetype:2
458 - >=media-libs/glew-1.10
459 - >=media-libs/harfbuzz-0.9.18:=[icu(+)]
460 - media-libs/lcms:2
461 - >=media-libs/libpng-1.4:0=
462 - >=media-libs/libcdr-0.1.0
463 - >=media-libs/libfreehand-0.1.0
464 - media-libs/libpagemaker
465 - >=media-libs/libvisio-0.1.0
466 - >=net-misc/curl-7.21.4
467 - net-libs/neon
468 - net-nds/openldap
469 - sci-mathematics/lpsolve
470 - virtual/jpeg:0
471 - >=x11-libs/cairo-1.10.0[X]
472 - x11-libs/libXinerama
473 - x11-libs/libXrandr
474 - x11-libs/libXrender
475 - virtual/glu
476 - virtual/opengl
477 - bluetooth? ( net-wireless/bluez )
478 - coinmp? ( sci-libs/coinor-mp )
479 - collada? ( >=media-libs/opencollada-1.2.2_p20150207 )
480 - cups? ( net-print/cups )
481 - dbus? ( >=dev-libs/dbus-glib-0.92 )
482 - eds? ( gnome-extra/evolution-data-server )
483 - firebird? ( >=dev-db/firebird-2.5 )
484 - gltf? ( media-libs/libgltf )
485 - gnome? ( gnome-base/gconf:2 )
486 - gtk? (
487 - x11-libs/gdk-pixbuf[X]
488 - >=x11-libs/gtk+-2.24:2
489 - )
490 - gtk3? ( >=x11-libs/gtk+-3.2:3 )
491 - gstreamer? (
492 - media-libs/gstreamer:1.0
493 - media-libs/gst-plugins-base:1.0
494 - )
495 - jemalloc? ( dev-libs/jemalloc )
496 - libreoffice_extensions_scripting-beanshell? ( >=dev-java/bsh-2.0_beta4 )
497 - libreoffice_extensions_scripting-javascript? ( dev-java/rhino:1.6 )
498 - libreoffice_extensions_wiki-publisher? (
499 - dev-java/commons-codec:0
500 - dev-java/commons-httpclient:3
501 - dev-java/commons-lang:2.1
502 - dev-java/commons-logging:0
503 - dev-java/tomcat-servlet-api:3.0
504 - )
505 - mysql? ( >=dev-db/mysql-connector-c++-1.1.0 )
506 - postgres? ( >=dev-db/postgresql-9.0:*[kerberos] )
507 - telepathy? (
508 - dev-libs/glib:2
509 - >=net-libs/telepathy-glib-0.18.0
510 - >=x11-libs/gtk+-2.24:2
511 - )
512 -"
513 -
514 -RDEPEND="${COMMON_DEPEND}
515 - !app-office/libreoffice-bin
516 - !app-office/libreoffice-bin-debug
517 - !<app-office/openoffice-bin-3.4.0-r1
518 - !app-office/openoffice
519 - media-fonts/libertine
520 - media-fonts/liberation-fonts
521 - media-fonts/urw-fonts
522 - java? ( >=virtual/jre-1.6 )
523 - kde? ( $(add_kdeapps_dep kioclient) )
524 - vlc? ( media-video/vlc )
525 -"
526 -
527 -if [[ ${PV} != *9999* ]]; then
528 - PDEPEND="=app-office/libreoffice-l10n-$(get_version_component_range 1-2)*"
529 -else
530 - # Translations are not reliable on live ebuilds
531 - # rather force people to use english only.
532 - PDEPEND="!app-office/libreoffice-l10n"
533 -fi
534 -
535 -# FIXME: cppunit should be moved to test conditional
536 -# after everything upstream is under gbuild
537 -# as dmake execute tests right away
538 -DEPEND="${COMMON_DEPEND}
539 - >=dev-libs/libatomic_ops-7.2d
540 - >=dev-libs/libxml2-2.7.8
541 - dev-libs/libxslt
542 - dev-perl/Archive-Zip
543 - dev-util/cppunit
544 - >=dev-util/gperf-3
545 - dev-util/intltool
546 - >=dev-util/mdds-0.11.2:=
547 - media-libs/glm
548 - net-misc/npapi-sdk
549 - >=sys-apps/findutils-4.4.2
550 - sys-devel/bison
551 - sys-apps/coreutils
552 - sys-devel/flex
553 - sys-devel/gettext
554 - >=sys-devel/make-3.82
555 - sys-devel/ucpp
556 - sys-libs/zlib
557 - virtual/pkgconfig
558 - x11-libs/libXt
559 - x11-libs/libXtst
560 - x11-proto/randrproto
561 - x11-proto/xextproto
562 - x11-proto/xineramaproto
563 - x11-proto/xproto
564 - java? (
565 - >=virtual/jdk-1.6
566 - >=dev-java/ant-core-1.7
567 - )
568 - odk? ( >=app-doc/doxygen-1.8.4 )
569 - test? ( dev-util/cppunit )
570 -"
571 -
572 -PATCHES=(
573 - # not upstreamable stuff
574 - "${FILESDIR}/${PN}-4.4-system-pyuno.patch"
575 -
576 - # from 5.0 branch
577 - "${FILESDIR}/${PN}-4.3.5.2-remove-bashisms.patch" # bug 525454
578 - "${FILESDIR}/${PN}-4.4.0.3-telepathy-build-fix.patch"
579 - "${FILESDIR}/${PN}-4.4.1.2-add-kde4-open-url-script.patch"
580 - "${FILESDIR}/${PN}-4.4.4.3-improve-KDE4FilePicker.patch"
581 - "${FILESDIR}/${PN}-4.4.4.3-fix-KDE4-FileDialog.patch"
582 - "${FILESDIR}/${PN}-4.4.4.3-cleanup-IsNativeControlSupported.patch"
583 -
584 - # from master branch
585 - "${FILESDIR}/${PN}-4.4.5.2-fix-KDE4-listbox-regression.patch"
586 -)
587 -
588 -REQUIRED_USE="
589 - ${PYTHON_REQUIRED_USE}
590 - bluetooth? ( dbus )
591 - collada? ( gltf )
592 - gnome? ( gtk )
593 - eds? ( gnome )
594 - telepathy? ( gtk )
595 - libreoffice_extensions_nlpsolver? ( java )
596 - libreoffice_extensions_scripting-beanshell? ( java )
597 - libreoffice_extensions_scripting-javascript? ( java )
598 - libreoffice_extensions_wiki-publisher? ( java )
599 -"
600 -
601 -CHECKREQS_MEMORY="512M"
602 -CHECKREQS_DISK_BUILD="6G"
603 -
604 -pkg_pretend() {
605 - local pgslot
606 -
607 - if [[ ${MERGE_TYPE} != binary ]]; then
608 - check-reqs_pkg_pretend
609 -
610 - if [[ $(gcc-major-version) -lt 4 ]] || \
611 - ( [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 6 ]] ) \
612 - ; then
613 - eerror "Compilation with gcc older than 4.6 is not supported"
614 - die "Too old gcc found."
615 - fi
616 - fi
617 -
618 - # Ensure pg version but we have to be sure the pg is installed (first
619 - # install on clean system)
620 - if use postgres && has_version dev-db/postgresql; then
621 - pgslot=$(postgresql-config show)
622 - if [[ ${pgslot//.} < 90 ]] ; then
623 - eerror "PostgreSQL slot must be set to 9.0 or higher."
624 - eerror " postgresql-config set 9.0"
625 - die "PostgreSQL slot is not set to 9.0 or higher."
626 - fi
627 - fi
628 -}
629 -
630 -pkg_setup() {
631 - java-pkg-opt-2_pkg_setup
632 - kde4-base_pkg_setup
633 - python-single-r1_pkg_setup
634 -
635 - [[ ${MERGE_TYPE} != binary ]] && check-reqs_pkg_setup
636 -}
637 -
638 -src_unpack() {
639 - local mod mod2 dest tmplfile tmplname mypv
640 -
641 - [[ -n ${PATCHSET} ]] && unpack ${PATCHSET}
642 - use branding && unpack "${BRANDING}"
643 -
644 - if [[ ${PV} != *9999* ]]; then
645 - unpack "${P}.tar.xz"
646 - for mod in ${MODULES}; do
647 - [[ ${mod} == core ]] && continue
648 - unpack "${PN}-${mod}-${PV}.tar.xz"
649 - done
650 - else
651 - for mod in ${MODULES}; do
652 - mypv=${PV/.9999}
653 - [[ ${mypv} != ${PV} ]] && EGIT_BRANCH="${PN}-${mypv/./-}"
654 - EGIT_CHECKOUT_DIR="${WORKDIR}/${P}"
655 - [[ ${mod} != core ]] && EGIT_CHECKOUT_DIR="${WORKDIR}/${PN}-${mod}-${PV}"
656 - EGIT_REPO_URI="git://anongit.freedesktop.org/${PN}/${mod}"
657 - git-r3_src_unpack
658 - if [[ ${mod} != core ]]; then
659 - mod2=${mod}
660 - # mapping does not match on help
661 - [[ ${mod} == help ]] && mod2="helpcontent2"
662 - mkdir -p "${S}/${mod2}/" || die
663 - mv -n "${WORKDIR}/${PN}-${mod}-${PV}"/* "${S}/${mod2}" || die
664 - rm -rf "${WORKDIR}/${PN}-${mod}-${PV}"
665 - fi
666 - done
667 - unset EGIT_CHECKOUT_DIR EGIT_REPO_URI EGIT_BRANCH
668 - fi
669 -}
670 -
671 -src_prepare() {
672 - # optimization flags
673 - export GMAKE_OPTIONS="${MAKEOPTS}"
674 - # System python 2.7 enablement:
675 - export PYTHON_CFLAGS=$(python_get_CFLAGS)
676 - export PYTHON_LIBS=$(python_get_LIBS)
677 -
678 - if use collada; then
679 - export OPENCOLLADA_CFLAGS="-I/usr/include/opencollada/COLLADABaseUtils -I/usr/include/opencollada/COLLADAFramework -I/usr/include/opencollada/COLLADASaxFrameworkLoader -I/usr/include/opencollada/GeneratedSaxParser"
680 - export OPENCOLLADA_LIBS="-L /usr/$(get_libdir)/opencollada -lOpenCOLLADABaseUtils -lOpenCOLLADAFramework -lOpenCOLLADASaxFrameworkLoader -lGeneratedSaxParser"
681 - fi
682 -
683 - # patchset
684 - if [[ -n ${PATCHSET} ]]; then
685 - EPATCH_FORCE="yes" \
686 - EPATCH_SOURCE="${WORKDIR}/${PATCHSET/.tar.xz/}" \
687 - EPATCH_SUFFIX="patch" \
688 - epatch
689 - fi
690 -
691 - base_src_prepare
692 -
693 - AT_M4DIR="m4" eautoreconf
694 - # hack in the autogen.sh
695 - touch autogen.lastrun
696 -
697 - # system pyuno mess
698 - sed \
699 - -e "s:%eprefix%:${EPREFIX}:g" \
700 - -e "s:%libdir%:$(get_libdir):g" \
701 - -i pyuno/source/module/uno.py \
702 - -i pyuno/source/officehelper.py || die
703 - # sed in the tests
704 - sed -i \
705 - -e 's#all : build unitcheck#all : build#g' \
706 - solenv/gbuild/Module.mk || die
707 - sed -i \
708 - -e 's#check: dev-install subsequentcheck#check: unitcheck slowcheck dev-install subsequentcheck#g' \
709 - -e 's#Makefile.gbuild all slowcheck#Makefile.gbuild all#g' \
710 - Makefile.in || die
711 -
712 - if use branding; then
713 - # hack...
714 - mv -v "${WORKDIR}/branding-intro.png" "${S}/icon-themes/galaxy/brand/intro.png" || die
715 - fi
716 -}
717 -
718 -src_configure() {
719 - local java_opts
720 - local internal_libs
721 - local lo_ext
722 - local ext_opts
723 -
724 - # sane: just sane.h header that is used for scan in writer, not
725 - # linked or anything else, worthless to depend on
726 - # vigra: just uses templates from there
727 - # it is serious pain in the ass for packaging
728 - # should be replaced by boost::gil if someone interested
729 - internal_libs+="
730 - --without-system-sane
731 - --without-system-vigra
732 - "
733 -
734 - # libreoffice extensions handling
735 - for lo_xt in ${LO_EXTS}; do
736 - if [[ "${lo_xt}" == "scripting-beanshell" || "${lo_xt}" == "scripting-javascript" ]]; then
737 - ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ${lo_xt})"
738 - else
739 - ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ext-${lo_xt})"
740 - fi
741 - done
742 -
743 - if use java; then
744 - # hsqldb: system one is too new
745 - java_opts="
746 - --without-junit
747 - --without-system-hsqldb
748 - --with-ant-home="${ANT_HOME}"
749 - --with-jdk-home=$(java-config --jdk-home 2>/dev/null)
750 - --with-jvm-path="${EPREFIX}/usr/lib/"
751 - "
752 -
753 - use libreoffice_extensions_scripting-beanshell && \
754 - java_opts+=" --with-beanshell-jar=$(java-pkg_getjar bsh bsh.jar)"
755 -
756 - use libreoffice_extensions_scripting-javascript && \
757 - java_opts+=" --with-rhino-jar=$(java-pkg_getjar rhino-1.6 js.jar)"
758 -
759 - if use libreoffice_extensions_wiki-publisher; then
760 - java_opts+="
761 - --with-commons-codec-jar=$(java-pkg_getjar commons-codec commons-codec.jar)
762 - --with-commons-httpclient-jar=$(java-pkg_getjar commons-httpclient-3 commons-httpclient.jar)
763 - --with-commons-lang-jar=$(java-pkg_getjar commons-lang-2.1 commons-lang.jar)
764 - --with-commons-logging-jar=$(java-pkg_getjar commons-logging commons-logging.jar)
765 - --with-servlet-api-jar=$(java-pkg_getjar tomcat-servlet-api-3.0 servlet-api.jar)
766 - "
767 - fi
768 - fi
769 -
770 - # system headers/libs/...: enforce using system packages
771 - # --enable-cairo: ensure that cairo is always required
772 - # --enable-graphite: disabling causes build breakages
773 - # --enable-*-link: link to the library rather than just dlopen on runtime
774 - # --enable-release-build: build the libreoffice as release
775 - # --disable-fetch-external: prevent dowloading during compile phase
776 - # --disable-gnome-vfs: old gnome virtual fs support
777 - # --disable-kdeab: kde3 adressbook
778 - # --disable-kde: kde3 support
779 - # --disable-systray: quickstarter does not actually work at all so do not
780 - # promote it
781 - # --enable-extension-integration: enable any extension integration support
782 - # --without-{fonts,myspell-dicts,ppsd}: prevent install of sys pkgs
783 - # --disable-report-builder: too much java packages pulled in without pkgs
784 - econf \
785 - --docdir="${EPREFIX}/usr/share/doc/${PF}/" \
786 - --with-system-headers \
787 - --with-system-libs \
788 - --with-system-jars \
789 - --with-system-dicts \
790 - --enable-cairo-canvas \
791 - --enable-graphite \
792 - --enable-largefile \
793 - --enable-mergelibs \
794 - --enable-neon \
795 - --enable-python=system \
796 - --enable-randr \
797 - --enable-randr-link \
798 - --enable-release-build \
799 - --disable-hardlink-deliver \
800 - --disable-ccache \
801 - --disable-crashdump \
802 - --disable-dependency-tracking \
803 - --disable-epm \
804 - --disable-fetch-external \
805 - --disable-gnome-vfs \
806 - --disable-gstreamer-0-10 \
807 - --disable-report-builder \
808 - --disable-kdeab \
809 - --disable-kde \
810 - --disable-online-update \
811 - --disable-systray \
812 - --with-alloc=$(use jemalloc && echo "jemalloc" || echo "system") \
813 - --with-build-version="Gentoo official package" \
814 - --enable-extension-integration \
815 - --with-external-dict-dir="${EPREFIX}/usr/share/myspell" \
816 - --with-external-hyph-dir="${EPREFIX}/usr/share/myspell" \
817 - --with-external-thes-dir="${EPREFIX}/usr/share/myspell" \
818 - --with-external-tar="${DISTDIR}" \
819 - --with-lang="" \
820 - --with-parallelism=$(makeopts_jobs) \
821 - --with-system-ucpp \
822 - --with-vendor="Gentoo Foundation" \
823 - --with-x \
824 - --without-fonts \
825 - --without-myspell-dicts \
826 - --without-help \
827 - --with-helppack-integration \
828 - --without-sun-templates \
829 - $(use_enable bluetooth sdremote-bluetooth) \
830 - $(use_enable coinmp) \
831 - $(use_enable collada) \
832 - $(use_enable cups) \
833 - $(use_enable debug) \
834 - $(use_enable dbus) \
835 - $(use_enable eds evolution2) \
836 - $(use_enable firebird firebird-sdbc) \
837 - $(use_enable gltf) \
838 - $(use_enable gnome gconf) \
839 - $(use_enable gnome gio) \
840 - $(use_enable gnome lockdown) \
841 - $(use_enable gstreamer gstreamer-1-0) \
842 - $(use_enable gtk) \
843 - $(use_enable gtk3) \
844 - $(use_enable kde kde4) \
845 - $(use_enable mysql ext-mariadb-connector) \
846 - $(use_enable odk) \
847 - $(use_enable postgres postgresql-sdbc) \
848 - $(use_enable telepathy) \
849 - $(use_enable vlc) \
850 - $(use_with coinmp system-coinmp) \
851 - $(use_with collada system-opencollada) \
852 - $(use_with gltf system-libgltf) \
853 - $(use_with java) \
854 - $(use_with mysql system-mysql-cppconn) \
855 - $(use_with odk doxygen) \
856 - ${internal_libs} \
857 - ${java_opts} \
858 - ${ext_opts}
859 -}
860 -
861 -src_compile() {
862 - # more and more LO stuff tries to use OpenGL, including tests during build
863 - # bug 501508, bug 540624, bug 545974 and probably more
864 - addpredict /dev/dri
865 - addpredict /dev/ati
866 - addpredict /dev/nvidiactl
867 -
868 - # hack for offlinehelp, this needs fixing upstream at some point
869 - # it is broken because we send --without-help
870 - # https://bugs.freedesktop.org/show_bug.cgi?id=46506
871 - (
872 - grep "^export" "${S}/config_host.mk" > "${T}/config_host.mk"
873 - source "${T}/config_host.mk" 2&> /dev/null
874 -
875 - local path="${WORKDIR}/helpcontent2/source/auxiliary/"
876 - mkdir -p "${path}" || die
877 -
878 - echo "perl \"${S}/helpcontent2/helpers/create_ilst.pl\" -dir=icon-themes/galaxy/res/helpimg > \"${path}/helpimg.ilst\""
879 - perl "${S}/helpcontent2/helpers/create_ilst.pl" \
880 - -dir=icon-themes/galaxy/res/helpimg \
881 - > "${path}/helpimg.ilst"
882 - [[ -s "${path}/helpimg.ilst" ]] || ewarn "The help images list is empty, something is fishy, report a bug."
883 - )
884 -
885 - local target
886 - use test && target="build" || target="build-nocheck"
887 -
888 - # this is not a proper make script
889 - make ${target} || die
890 -}
891 -
892 -src_test() {
893 - make unitcheck || die
894 - make slowcheck || die
895 -}
896 -
897 -src_install() {
898 - # This is not Makefile so no buildserver
899 - make DESTDIR="${D}" distro-pack-install -o build -o check || die
900 -
901 - # Fix bash completion placement
902 - newbashcomp "${ED}"/etc/bash_completion.d/libreoffice.sh ${PN}
903 - bashcomp_alias \
904 - libreoffice \
905 - unopkg loimpress lobase localc lodraw lomath lowriter lofromtemplate loweb loffice
906 - rm -rf "${ED}"/etc/ || die
907 -
908 - if use branding; then
909 - insinto /usr/$(get_libdir)/${PN}/program
910 - newins "${WORKDIR}/branding-sofficerc" sofficerc
911 - dodir /etc/env.d
912 - echo "CONFIG_PROTECT=/usr/$(get_libdir)/${PN}/program/sofficerc" > "${ED}"/etc/env.d/99${PN}
913 - fi
914 -
915 - # Hack for offlinehelp, this needs fixing upstream at some point.
916 - # It is broken because we send --without-help
917 - # https://bugs.freedesktop.org/show_bug.cgi?id=46506
918 - insinto /usr/$(get_libdir)/libreoffice/help
919 - doins xmlhelp/util/*.xsl
920 -
921 - # Remove desktop files for support to old installs that can't parse mime
922 - rm -rf "${ED}"/usr/share/mimelnk/
923 -
924 - # FIXME: Hack add missing file
925 - insinto /usr/$(get_libdir)/${PN}/program
926 - doins "${S}"/instdir/program/libsaxlo.so
927 -
928 - pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/soffice.bin
929 - pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/unopkg.bin
930 -}
931 -
932 -pkg_preinst() {
933 - # Cache updates - all handled by kde eclass for all environments
934 - kde4-base_pkg_preinst
935 -}
936 -
937 -pkg_postinst() {
938 - kde4-base_pkg_postinst
939 -
940 - use java || \
941 - ewarn 'If you plan to use lbase application you should enable java or you will get various crashes.'
942 -}
943 -
944 -pkg_postrm() {
945 - kde4-base_pkg_postrm
946 -}
947
948 diff --git a/app-office/libreoffice/libreoffice-5.0.2.2.ebuild b/app-office/libreoffice/libreoffice-5.0.2.2.ebuild
949 deleted file mode 100644
950 index beabdc7..0000000
951 --- a/app-office/libreoffice/libreoffice-5.0.2.2.ebuild
952 +++ /dev/null
953 @@ -1,607 +0,0 @@
954 -# Copyright 1999-2015 Gentoo Foundation
955 -# Distributed under the terms of the GNU General Public License v2
956 -# $Id$
957 -
958 -EAPI=5
959 -
960 -KDE_REQUIRED="optional"
961 -QT_MINIMAL="4.7.4"
962 -KDE_SCM="git"
963 -CMAKE_REQUIRED="never"
964 -
965 -PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
966 -PYTHON_REQ_USE="threads,xml"
967 -
968 -# experimental ; release ; old
969 -# Usually the tarballs are moved a lot so this should make
970 -# everyone happy.
971 -DEV_URI="
972 - http://dev-builds.libreoffice.org/pre-releases/src
973 - http://download.documentfoundation.org/libreoffice/src/${PV:0:5}/
974 - http://download.documentfoundation.org/libreoffice/old/${PV}/
975 -"
976 -EXT_URI="http://ooo.itc.hu/oxygenoffice/download/libreoffice"
977 -ADDONS_URI="http://dev-www.libreoffice.org/src/"
978 -
979 -BRANDING="${PN}-branding-gentoo-0.8.tar.xz"
980 -# PATCHSET="${P}-patchset-01.tar.xz"
981 -
982 -[[ ${PV} == *9999* ]] && SCM_ECLASS="git-r3"
983 -inherit base multiprocessing autotools bash-completion-r1 check-reqs eutils java-pkg-opt-2 kde4-base pax-utils python-single-r1 multilib toolchain-funcs flag-o-matic versionator ${SCM_ECLASS}
984 -unset SCM_ECLASS
985 -
986 -DESCRIPTION="LibreOffice, a full office productivity suite"
987 -HOMEPAGE="http://www.libreoffice.org"
988 -SRC_URI="branding? ( http://dev.gentoo.org/~dilfridge/distfiles/${BRANDING} )"
989 -[[ -n ${PATCHSET} ]] && SRC_URI+=" http://dev.gentooexperimental.org/~scarabeus/${PATCHSET}"
990 -
991 -# Split modules following git/tarballs
992 -# Core MUST be first!
993 -# Help is used for the image generator
994 -MODULES="core help"
995 -# Only release has the tarballs
996 -if [[ ${PV} != *9999* ]]; then
997 - for i in ${DEV_URI}; do
998 - for mod in ${MODULES}; do
999 - if [[ ${mod} == core ]]; then
1000 - SRC_URI+=" ${i}/${P}.tar.xz"
1001 - else
1002 - SRC_URI+=" ${i}/${PN}-${mod}-${PV}.tar.xz"
1003 - fi
1004 - done
1005 - unset mod
1006 - done
1007 - unset i
1008 -fi
1009 -unset DEV_URI
1010 -
1011 -# Really required addons
1012 -# These are bundles that can't be removed for now due to huge patchsets.
1013 -# If you want them gone, patches are welcome.
1014 -ADDONS_SRC+=" ${ADDONS_URI}/d62650a6f908e85643e557a236ea989c-vigra1.6.0.tar.gz"
1015 -ADDONS_SRC+=" ${ADDONS_URI}/1f24ab1d39f4a51faf22244c94a6203f-xmlsec1-1.2.14.tar.gz" # modifies source code
1016 -ADDONS_SRC+=" collada? ( ${ADDONS_URI}/4b87018f7fff1d054939d19920b751a0-collada2gltf-master-cb1d97788a.tar.bz2 )"
1017 -ADDONS_SRC+=" java? ( ${ADDONS_URI}/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip )"
1018 -ADDONS_SRC+=" libreoffice_extensions_wiki-publisher? ( ${ADDONS_URI}/a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip )" # no release for 8 years, should we package it?
1019 -ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip )" # Does not build with 1.6 rhino at all
1020 -ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/35c94d2df8893241173de1d16b6034c0-swingExSrc.zip )" # requirement of rhino
1021 -ADDONS_SRC+=" odk? ( http://download.go-oo.org/extern/185d60944ea767075d27247c3162b3bc-unowinreg.dll )" # not packageable
1022 -SRC_URI+=" ${ADDONS_SRC}"
1023 -
1024 -unset ADDONS_URI
1025 -unset EXT_URI
1026 -unset ADDONS_SRC
1027 -
1028 -IUSE="bluetooth +branding coinmp collada +cups dbus debug eds firebird gltf gnome gstreamer
1029 -+gtk gtk3 jemalloc kde mysql odk postgres telepathy test vlc"
1030 -
1031 -LO_EXTS="nlpsolver scripting-beanshell scripting-javascript wiki-publisher"
1032 -# Unpackaged separate extensions:
1033 -# diagram: lo has 0.9.5 upstream is weirdly patched 0.9.4 -> wtf?
1034 -# hunart: only on ooo extensions -> fubared download path somewhere on sf
1035 -# numbertext, typo, validator, watch-window: ^^
1036 -# oooblogger: no homepage or anything
1037 -# Extensions that need extra work:
1038 -for lo_xt in ${LO_EXTS}; do
1039 - IUSE+=" libreoffice_extensions_${lo_xt}"
1040 -done
1041 -unset lo_xt
1042 -
1043 -LICENSE="|| ( LGPL-3 MPL-1.1 )"
1044 -SLOT="0"
1045 -[[ ${PV} == *9999* ]] || \
1046 -KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux"
1047 -
1048 -COMMON_DEPEND="
1049 - ${PYTHON_DEPS}
1050 - app-arch/zip
1051 - app-arch/unzip
1052 - >=app-text/hunspell-1.3.2-r3
1053 - app-text/mythes
1054 - >=app-text/libabw-0.1.0
1055 - >=app-text/libexttextcat-3.2
1056 - >=app-text/libebook-0.1.1
1057 - >=app-text/libetonyek-0.1.2
1058 - app-text/liblangtag
1059 - >=app-text/libmspub-0.1.0
1060 - >=app-text/libmwaw-0.3.5
1061 - >=app-text/libodfgen-0.1.0
1062 - app-text/libwpd:0.10[tools]
1063 - app-text/libwpg:0.3
1064 - =app-text/libwps-0.4*
1065 - >=app-text/poppler-0.16:=[xpdf-headers(+),cxx]
1066 - >=dev-cpp/clucene-2.3.3.4-r2
1067 - =dev-cpp/libcmis-0.5*
1068 - dev-db/unixODBC
1069 - >=dev-libs/boost-1.55:=
1070 - dev-libs/expat
1071 - >=dev-libs/hyphen-2.7.1
1072 - >=dev-libs/icu-4.8.1.1:=
1073 - =dev-libs/liborcus-0.7*
1074 - >=dev-libs/librevenge-0.0.1
1075 - >=dev-libs/nspr-4.8.8
1076 - >=dev-libs/nss-3.12.9
1077 - >=dev-lang/perl-5.0
1078 - >=dev-libs/openssl-1.0.0d:0
1079 - >=dev-libs/redland-1.0.16
1080 - media-gfx/graphite2
1081 - >=media-libs/fontconfig-2.8.0
1082 - media-libs/freetype:2
1083 - >=media-libs/glew-1.10
1084 - >=media-libs/harfbuzz-0.9.18:=[icu(+)]
1085 - media-libs/lcms:2
1086 - >=media-libs/libpng-1.4:0=
1087 - >=media-libs/libcdr-0.1.0
1088 - >=media-libs/libfreehand-0.1.0
1089 - media-libs/libpagemaker
1090 - >=media-libs/libvisio-0.1.0
1091 - >=net-misc/curl-7.21.4
1092 - net-libs/neon
1093 - net-nds/openldap
1094 - sci-mathematics/lpsolve
1095 - virtual/jpeg:0
1096 - >=x11-libs/cairo-1.10.0[X]
1097 - x11-libs/libXinerama
1098 - x11-libs/libXrandr
1099 - x11-libs/libXrender
1100 - virtual/glu
1101 - virtual/opengl
1102 - bluetooth? ( net-wireless/bluez )
1103 - coinmp? ( sci-libs/coinor-mp )
1104 - collada? ( >=media-libs/opencollada-1.2.2_p20150207 )
1105 - cups? ( net-print/cups )
1106 - dbus? ( >=dev-libs/dbus-glib-0.92 )
1107 - eds? ( gnome-extra/evolution-data-server )
1108 - firebird? ( >=dev-db/firebird-2.5 )
1109 - gltf? ( media-libs/libgltf )
1110 - gnome? ( gnome-base/gconf:2 )
1111 - gtk? (
1112 - x11-libs/gdk-pixbuf[X]
1113 - >=x11-libs/gtk+-2.24:2
1114 - )
1115 - gtk3? ( >=x11-libs/gtk+-3.8:3 )
1116 - gstreamer? (
1117 - media-libs/gstreamer:1.0
1118 - media-libs/gst-plugins-base:1.0
1119 - )
1120 - jemalloc? ( dev-libs/jemalloc )
1121 - libreoffice_extensions_scripting-beanshell? ( >=dev-java/bsh-2.0_beta4 )
1122 - libreoffice_extensions_scripting-javascript? ( dev-java/rhino:1.6 )
1123 - libreoffice_extensions_wiki-publisher? (
1124 - dev-java/commons-codec:0
1125 - dev-java/commons-httpclient:3
1126 - dev-java/commons-lang:2.1
1127 - dev-java/commons-logging:0
1128 - dev-java/tomcat-servlet-api:3.0
1129 - )
1130 - mysql? ( >=dev-db/mysql-connector-c++-1.1.0 )
1131 - postgres? ( >=dev-db/postgresql-9.0:*[kerberos] )
1132 - telepathy? (
1133 - dev-libs/glib:2
1134 - >=net-libs/telepathy-glib-0.18.0
1135 - >=x11-libs/gtk+-2.24:2
1136 - )
1137 -"
1138 -
1139 -RDEPEND="${COMMON_DEPEND}
1140 - !app-office/libreoffice-bin
1141 - !app-office/libreoffice-bin-debug
1142 - !<app-office/openoffice-bin-3.4.0-r1
1143 - !app-office/openoffice
1144 - media-fonts/libertine
1145 - media-fonts/liberation-fonts
1146 - media-fonts/urw-fonts
1147 - java? ( >=virtual/jre-1.6 )
1148 - kde? ( $(add_kdeapps_dep kioclient) )
1149 - vlc? ( media-video/vlc )
1150 -"
1151 -
1152 -if [[ ${PV} != *9999* ]]; then
1153 - PDEPEND="=app-office/libreoffice-l10n-$(get_version_component_range 1-2)*"
1154 -else
1155 - # Translations are not reliable on live ebuilds
1156 - # rather force people to use english only.
1157 - PDEPEND="!app-office/libreoffice-l10n"
1158 -fi
1159 -
1160 -# FIXME: cppunit should be moved to test conditional
1161 -# after everything upstream is under gbuild
1162 -# as dmake execute tests right away
1163 -DEPEND="${COMMON_DEPEND}
1164 - >=dev-libs/libatomic_ops-7.2d
1165 - >=dev-libs/libxml2-2.7.8
1166 - dev-libs/libxslt
1167 - dev-perl/Archive-Zip
1168 - dev-util/cppunit
1169 - >=dev-util/gperf-3
1170 - dev-util/intltool
1171 - >=dev-util/mdds-0.12.0:=
1172 - media-libs/glm
1173 - net-misc/npapi-sdk
1174 - >=sys-apps/findutils-4.4.2
1175 - sys-devel/bison
1176 - sys-apps/coreutils
1177 - sys-devel/flex
1178 - sys-devel/gettext
1179 - >=sys-devel/make-3.82
1180 - sys-devel/ucpp
1181 - sys-libs/zlib
1182 - virtual/pkgconfig
1183 - x11-libs/libXt
1184 - x11-libs/libXtst
1185 - x11-proto/randrproto
1186 - x11-proto/xextproto
1187 - x11-proto/xineramaproto
1188 - x11-proto/xproto
1189 - java? (
1190 - >=virtual/jdk-1.6
1191 - >=dev-java/ant-core-1.7
1192 - )
1193 - odk? ( >=app-doc/doxygen-1.8.4 )
1194 - test? ( dev-util/cppunit )
1195 -"
1196 -
1197 -PATCHES=(
1198 - # not upstreamable stuff
1199 - "${FILESDIR}/${PN}-4.4-system-pyuno.patch"
1200 -)
1201 -
1202 -REQUIRED_USE="
1203 - ${PYTHON_REQUIRED_USE}
1204 - bluetooth? ( dbus )
1205 - collada? ( gltf )
1206 - gnome? ( gtk )
1207 - eds? ( gnome )
1208 - telepathy? ( gtk )
1209 - libreoffice_extensions_nlpsolver? ( java )
1210 - libreoffice_extensions_scripting-beanshell? ( java )
1211 - libreoffice_extensions_scripting-javascript? ( java )
1212 - libreoffice_extensions_wiki-publisher? ( java )
1213 -"
1214 -
1215 -CHECKREQS_MEMORY="512M"
1216 -if [[ ${MERGE_TYPE} != binary ]] ; then CHECKREQS_DISK_BUILD="6G" ; fi
1217 -
1218 -pkg_pretend() {
1219 - local pgslot
1220 -
1221 - if [[ ${MERGE_TYPE} != binary ]]; then
1222 - check-reqs_pkg_pretend
1223 -
1224 - if [[ $(gcc-major-version) -lt 4 ]] || \
1225 - ( [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 6 ]] ) \
1226 - ; then
1227 - eerror "Compilation with gcc older than 4.6 is not supported"
1228 - die "Too old gcc found."
1229 - fi
1230 - fi
1231 -
1232 - # Ensure pg version but we have to be sure the pg is installed (first
1233 - # install on clean system)
1234 - if use postgres && has_version dev-db/postgresql; then
1235 - pgslot=$(postgresql-config show)
1236 - if [[ ${pgslot//.} < 90 ]] ; then
1237 - eerror "PostgreSQL slot must be set to 9.0 or higher."
1238 - eerror " postgresql-config set 9.0"
1239 - die "PostgreSQL slot is not set to 9.0 or higher."
1240 - fi
1241 - fi
1242 -}
1243 -
1244 -pkg_setup() {
1245 - java-pkg-opt-2_pkg_setup
1246 - kde4-base_pkg_setup
1247 - python-single-r1_pkg_setup
1248 -
1249 - [[ ${MERGE_TYPE} != binary ]] && check-reqs_pkg_setup
1250 -}
1251 -
1252 -src_unpack() {
1253 - local mod mod2 dest tmplfile tmplname mypv
1254 -
1255 - [[ -n ${PATCHSET} ]] && unpack ${PATCHSET}
1256 - use branding && unpack "${BRANDING}"
1257 -
1258 - if [[ ${PV} != *9999* ]]; then
1259 - unpack "${P}.tar.xz"
1260 - for mod in ${MODULES}; do
1261 - [[ ${mod} == core ]] && continue
1262 - unpack "${PN}-${mod}-${PV}.tar.xz"
1263 - done
1264 - else
1265 - for mod in ${MODULES}; do
1266 - mypv=${PV/.9999}
1267 - [[ ${mypv} != ${PV} ]] && EGIT_BRANCH="${PN}-${mypv/./-}"
1268 - EGIT_CHECKOUT_DIR="${WORKDIR}/${P}"
1269 - [[ ${mod} != core ]] && EGIT_CHECKOUT_DIR="${WORKDIR}/${PN}-${mod}-${PV}"
1270 - EGIT_REPO_URI="git://anongit.freedesktop.org/${PN}/${mod}"
1271 - git-r3_src_unpack
1272 - if [[ ${mod} != core ]]; then
1273 - mod2=${mod}
1274 - # mapping does not match on help
1275 - [[ ${mod} == help ]] && mod2="helpcontent2"
1276 - mkdir -p "${S}/${mod2}/" || die
1277 - mv -n "${WORKDIR}/${PN}-${mod}-${PV}"/* "${S}/${mod2}" || die
1278 - rm -rf "${WORKDIR}/${PN}-${mod}-${PV}"
1279 - fi
1280 - done
1281 - unset EGIT_CHECKOUT_DIR EGIT_REPO_URI EGIT_BRANCH
1282 - fi
1283 -}
1284 -
1285 -src_prepare() {
1286 - # optimization flags
1287 - export GMAKE_OPTIONS="${MAKEOPTS}"
1288 - # System python 2.7 enablement:
1289 - export PYTHON_CFLAGS=$(python_get_CFLAGS)
1290 - export PYTHON_LIBS=$(python_get_LIBS)
1291 -
1292 - if use collada; then
1293 - export OPENCOLLADA_CFLAGS="-I/usr/include/opencollada/COLLADABaseUtils -I/usr/include/opencollada/COLLADAFramework -I/usr/include/opencollada/COLLADASaxFrameworkLoader -I/usr/include/opencollada/GeneratedSaxParser"
1294 - export OPENCOLLADA_LIBS="-L /usr/$(get_libdir)/opencollada -lOpenCOLLADABaseUtils -lOpenCOLLADAFramework -lOpenCOLLADASaxFrameworkLoader -lGeneratedSaxParser"
1295 - fi
1296 -
1297 - # patchset
1298 - if [[ -n ${PATCHSET} ]]; then
1299 - EPATCH_FORCE="yes" \
1300 - EPATCH_SOURCE="${WORKDIR}/${PATCHSET/.tar.xz/}" \
1301 - EPATCH_SUFFIX="patch" \
1302 - epatch
1303 - fi
1304 -
1305 - base_src_prepare
1306 -
1307 - AT_M4DIR="m4" eautoreconf
1308 - # hack in the autogen.sh
1309 - touch autogen.lastrun
1310 -
1311 - # system pyuno mess
1312 - sed \
1313 - -e "s:%eprefix%:${EPREFIX}:g" \
1314 - -e "s:%libdir%:$(get_libdir):g" \
1315 - -i pyuno/source/module/uno.py \
1316 - -i pyuno/source/officehelper.py || die
1317 - # sed in the tests
1318 - sed -i \
1319 - -e 's#all : build unitcheck#all : build#g' \
1320 - solenv/gbuild/Module.mk || die
1321 - sed -i \
1322 - -e 's#check: dev-install subsequentcheck#check: unitcheck slowcheck dev-install subsequentcheck#g' \
1323 - -e 's#Makefile.gbuild all slowcheck#Makefile.gbuild all#g' \
1324 - Makefile.in || die
1325 -
1326 - if use branding; then
1327 - # hack...
1328 - mv -v "${WORKDIR}/branding-intro.png" "${S}/icon-themes/galaxy/brand/intro.png" || die
1329 - fi
1330 -}
1331 -
1332 -src_configure() {
1333 - local java_opts
1334 - local internal_libs
1335 - local lo_ext
1336 - local ext_opts
1337 -
1338 - # sane: just sane.h header that is used for scan in writer, not
1339 - # linked or anything else, worthless to depend on
1340 - # vigra: just uses templates from there
1341 - # it is serious pain in the ass for packaging
1342 - # should be replaced by boost::gil if someone interested
1343 - internal_libs+="
1344 - --without-system-sane
1345 - --without-system-vigra
1346 - "
1347 -
1348 - # libreoffice extensions handling
1349 - for lo_xt in ${LO_EXTS}; do
1350 - if [[ "${lo_xt}" == "scripting-beanshell" || "${lo_xt}" == "scripting-javascript" ]]; then
1351 - ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ${lo_xt})"
1352 - else
1353 - ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ext-${lo_xt})"
1354 - fi
1355 - done
1356 -
1357 - if use java; then
1358 - # hsqldb: system one is too new
1359 - java_opts="
1360 - --without-junit
1361 - --without-system-hsqldb
1362 - --with-ant-home="${ANT_HOME}"
1363 - --with-jdk-home=$(java-config --jdk-home 2>/dev/null)
1364 - --with-jvm-path="${EPREFIX}/usr/lib/"
1365 - "
1366 -
1367 - use libreoffice_extensions_scripting-beanshell && \
1368 - java_opts+=" --with-beanshell-jar=$(java-pkg_getjar bsh bsh.jar)"
1369 -
1370 - use libreoffice_extensions_scripting-javascript && \
1371 - java_opts+=" --with-rhino-jar=$(java-pkg_getjar rhino-1.6 js.jar)"
1372 -
1373 - if use libreoffice_extensions_wiki-publisher; then
1374 - java_opts+="
1375 - --with-commons-codec-jar=$(java-pkg_getjar commons-codec commons-codec.jar)
1376 - --with-commons-httpclient-jar=$(java-pkg_getjar commons-httpclient-3 commons-httpclient.jar)
1377 - --with-commons-lang-jar=$(java-pkg_getjar commons-lang-2.1 commons-lang.jar)
1378 - --with-commons-logging-jar=$(java-pkg_getjar commons-logging commons-logging.jar)
1379 - --with-servlet-api-jar=$(java-pkg_getjar tomcat-servlet-api-3.0 servlet-api.jar)
1380 - "
1381 - fi
1382 - fi
1383 -
1384 - # system headers/libs/...: enforce using system packages
1385 - # --enable-cairo: ensure that cairo is always required
1386 - # --enable-graphite: disabling causes build breakages
1387 - # --enable-*-link: link to the library rather than just dlopen on runtime
1388 - # --enable-release-build: build the libreoffice as release
1389 - # --disable-fetch-external: prevent dowloading during compile phase
1390 - # --disable-gnome-vfs: old gnome virtual fs support
1391 - # --disable-kdeab: kde3 adressbook
1392 - # --disable-kde: kde3 support
1393 - # --disable-systray: quickstarter does not actually work at all so do not
1394 - # promote it
1395 - # --enable-extension-integration: enable any extension integration support
1396 - # --without-{fonts,myspell-dicts,ppsd}: prevent install of sys pkgs
1397 - # --disable-report-builder: too much java packages pulled in without pkgs
1398 - econf \
1399 - --docdir="${EPREFIX}/usr/share/doc/${PF}/" \
1400 - --with-system-headers \
1401 - --with-system-libs \
1402 - --with-system-jars \
1403 - --with-system-dicts \
1404 - --enable-cairo-canvas \
1405 - --enable-graphite \
1406 - --enable-largefile \
1407 - --enable-mergelibs \
1408 - --enable-neon \
1409 - --enable-python=system \
1410 - --enable-randr \
1411 - --enable-randr-link \
1412 - --enable-release-build \
1413 - --disable-hardlink-deliver \
1414 - --disable-ccache \
1415 - --disable-crashdump \
1416 - --disable-dependency-tracking \
1417 - --disable-epm \
1418 - --disable-fetch-external \
1419 - --disable-gnome-vfs \
1420 - --disable-gstreamer-0-10 \
1421 - --disable-report-builder \
1422 - --disable-kdeab \
1423 - --disable-kde \
1424 - --disable-online-update \
1425 - --disable-systray \
1426 - --with-alloc=$(use jemalloc && echo "jemalloc" || echo "system") \
1427 - --with-build-version="Gentoo official package" \
1428 - --enable-extension-integration \
1429 - --with-external-dict-dir="${EPREFIX}/usr/share/myspell" \
1430 - --with-external-hyph-dir="${EPREFIX}/usr/share/myspell" \
1431 - --with-external-thes-dir="${EPREFIX}/usr/share/myspell" \
1432 - --with-external-tar="${DISTDIR}" \
1433 - --with-lang="" \
1434 - --with-parallelism=$(makeopts_jobs) \
1435 - --with-system-ucpp \
1436 - --with-vendor="Gentoo Foundation" \
1437 - --with-x \
1438 - --without-fonts \
1439 - --without-myspell-dicts \
1440 - --without-help \
1441 - --with-helppack-integration \
1442 - --without-sun-templates \
1443 - $(use_enable bluetooth sdremote-bluetooth) \
1444 - $(use_enable coinmp) \
1445 - $(use_enable collada) \
1446 - $(use_enable cups) \
1447 - $(use_enable debug) \
1448 - $(use_enable dbus) \
1449 - $(use_enable eds evolution2) \
1450 - $(use_enable firebird firebird-sdbc) \
1451 - $(use_enable gltf) \
1452 - $(use_enable gnome gconf) \
1453 - $(use_enable gnome gio) \
1454 - $(use_enable gnome lockdown) \
1455 - $(use_enable gstreamer gstreamer-1-0) \
1456 - $(use_enable gtk) \
1457 - $(use_enable gtk3) \
1458 - $(use_enable kde kde4) \
1459 - $(use_enable mysql ext-mariadb-connector) \
1460 - $(use_enable odk) \
1461 - $(use_enable postgres postgresql-sdbc) \
1462 - $(use_enable telepathy) \
1463 - $(use_enable vlc) \
1464 - $(use_with coinmp system-coinmp) \
1465 - $(use_with collada system-opencollada) \
1466 - $(use_with gltf system-libgltf) \
1467 - $(use_with java) \
1468 - $(use_with mysql system-mysql-cppconn) \
1469 - $(use_with odk doxygen) \
1470 - ${internal_libs} \
1471 - ${java_opts} \
1472 - ${ext_opts}
1473 -}
1474 -
1475 -src_compile() {
1476 - # more and more LO stuff tries to use OpenGL, including tests during build
1477 - # bug 501508, bug 540624, bug 545974 and probably more
1478 - addpredict /dev/dri
1479 - addpredict /dev/ati
1480 - addpredict /dev/nvidiactl
1481 -
1482 - # hack for offlinehelp, this needs fixing upstream at some point
1483 - # it is broken because we send --without-help
1484 - # https://bugs.freedesktop.org/show_bug.cgi?id=46506
1485 - (
1486 - grep "^export" "${S}/config_host.mk" > "${T}/config_host.mk"
1487 - source "${T}/config_host.mk" 2&> /dev/null
1488 -
1489 - local path="${WORKDIR}/helpcontent2/source/auxiliary/"
1490 - mkdir -p "${path}" || die
1491 -
1492 - echo "perl \"${S}/helpcontent2/helpers/create_ilst.pl\" -dir=icon-themes/galaxy/res/helpimg > \"${path}/helpimg.ilst\""
1493 - perl "${S}/helpcontent2/helpers/create_ilst.pl" \
1494 - -dir=icon-themes/galaxy/res/helpimg \
1495 - > "${path}/helpimg.ilst"
1496 - [[ -s "${path}/helpimg.ilst" ]] || ewarn "The help images list is empty, something is fishy, report a bug."
1497 - )
1498 -
1499 - local target
1500 - use test && target="build" || target="build-nocheck"
1501 -
1502 - # this is not a proper make script
1503 - make ${target} || die
1504 -}
1505 -
1506 -src_test() {
1507 - make unitcheck || die
1508 - make slowcheck || die
1509 -}
1510 -
1511 -src_install() {
1512 - # This is not Makefile so no buildserver
1513 - make DESTDIR="${D}" distro-pack-install -o build -o check || die
1514 -
1515 - # Fix bash completion placement
1516 - newbashcomp "${ED}"/etc/bash_completion.d/libreoffice.sh ${PN}
1517 - bashcomp_alias \
1518 - libreoffice \
1519 - unopkg loimpress lobase localc lodraw lomath lowriter lofromtemplate loweb loffice
1520 - rm -rf "${ED}"/etc/ || die
1521 -
1522 - if use branding; then
1523 - insinto /usr/$(get_libdir)/${PN}/program
1524 - newins "${WORKDIR}/branding-sofficerc" sofficerc
1525 - dodir /etc/env.d
1526 - echo "CONFIG_PROTECT=/usr/$(get_libdir)/${PN}/program/sofficerc" > "${ED}"/etc/env.d/99${PN}
1527 - fi
1528 -
1529 - # Hack for offlinehelp, this needs fixing upstream at some point.
1530 - # It is broken because we send --without-help
1531 - # https://bugs.freedesktop.org/show_bug.cgi?id=46506
1532 - insinto /usr/$(get_libdir)/libreoffice/help
1533 - doins xmlhelp/util/*.xsl
1534 -
1535 - # Remove desktop files for support to old installs that can't parse mime
1536 - rm -rf "${ED}"/usr/share/mimelnk/
1537 -
1538 - # FIXME: Hack add missing file
1539 - insinto /usr/$(get_libdir)/${PN}/program
1540 - doins "${S}"/instdir/program/libsaxlo.so
1541 -
1542 - pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/soffice.bin
1543 - pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/unopkg.bin
1544 -}
1545 -
1546 -pkg_preinst() {
1547 - # Cache updates - all handled by kde eclass for all environments
1548 - kde4-base_pkg_preinst
1549 -}
1550 -
1551 -pkg_postinst() {
1552 - kde4-base_pkg_postinst
1553 -
1554 - use java || \
1555 - ewarn 'If you plan to use lbase application you should enable java or you will get various crashes.'
1556 -}
1557 -
1558 -pkg_postrm() {
1559 - kde4-base_pkg_postrm
1560 -}