Gentoo Archives: gentoo-commits

From: "Andreas HAttel (dilfridge)" <dilfridge@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-office/libreoffice: libreoffice-4.2.5.2.ebuild ChangeLog
Date: Tue, 24 Jun 2014 23:50:15
Message-Id: 20140624235009.C30CF2004E@flycatcher.gentoo.org
1 dilfridge 14/06/24 23:50:09
2
3 Modified: ChangeLog
4 Added: libreoffice-4.2.5.2.ebuild
5 Log:
6 Version bump
7
8 (Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!)
9
10 Revision Changes Path
11 1.557 app-office/libreoffice/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/libreoffice/ChangeLog?rev=1.557&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/libreoffice/ChangeLog?rev=1.557&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/libreoffice/ChangeLog?r1=1.556&r2=1.557
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-office/libreoffice/ChangeLog,v
20 retrieving revision 1.556
21 retrieving revision 1.557
22 diff -u -r1.556 -r1.557
23 --- ChangeLog 2 Jun 2014 10:35:02 -0000 1.556
24 +++ ChangeLog 24 Jun 2014 23:50:09 -0000 1.557
25 @@ -1,6 +1,12 @@
26 # ChangeLog for app-office/libreoffice
27 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/app-office/libreoffice/ChangeLog,v 1.556 2014/06/02 10:35:02 zlogene Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/app-office/libreoffice/ChangeLog,v 1.557 2014/06/24 23:50:09 dilfridge Exp $
30 +
31 +*libreoffice-4.2.5.2 (24 Jun 2014)
32 +
33 + 24 Jun 2014; Andreas K. Huettel <dilfridge@g.o>
34 + +libreoffice-4.2.5.2.ebuild:
35 + Version bump
36
37 02 Jun 2014; Mikle Kolyada <zlogene@g.o> libreoffice-4.2.3.3-r1.ebuild:
38 amd64 stable wrt bug #511144
39
40
41
42 1.1 app-office/libreoffice/libreoffice-4.2.5.2.ebuild
43
44 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/libreoffice/libreoffice-4.2.5.2.ebuild?rev=1.1&view=markup
45 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/libreoffice/libreoffice-4.2.5.2.ebuild?rev=1.1&content-type=text/plain
46
47 Index: libreoffice-4.2.5.2.ebuild
48 ===================================================================
49 # Copyright 1999-2014 Gentoo Foundation
50 # Distributed under the terms of the GNU General Public License v2
51 # $Header: /var/cvsroot/gentoo-x86/app-office/libreoffice/libreoffice-4.2.5.2.ebuild,v 1.1 2014/06/24 23:50:09 dilfridge Exp $
52
53 EAPI=5
54
55 KDE_REQUIRED="optional"
56 QT_MINIMAL="4.7.4"
57 KDE_SCM="git"
58 CMAKE_REQUIRED="never"
59
60 PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
61 PYTHON_REQ_USE="threads,xml"
62
63 # experimental ; release ; old
64 # Usually the tarballs are moved a lot so this should make
65 # everyone happy.
66 DEV_URI="
67 http://dev-builds.libreoffice.org/pre-releases/src
68 http://download.documentfoundation.org/libreoffice/src/${PV:0:5}/
69 http://download.documentfoundation.org/libreoffice/old/${PV}/
70 "
71 EXT_URI="http://ooo.itc.hu/oxygenoffice/download/libreoffice"
72 ADDONS_URI="http://dev-www.libreoffice.org/src/"
73
74 BRANDING="${PN}-branding-gentoo-0.8.tar.xz"
75 # PATCHSET="${P}-patchset-01.tar.xz"
76
77 [[ ${PV} == *9999* ]] && SCM_ECLASS="git-2"
78 inherit base autotools bash-completion-r1 check-reqs eutils java-pkg-opt-2 kde4-base pax-utils python-single-r1 multilib toolchain-funcs flag-o-matic nsplugins ${SCM_ECLASS}
79 unset SCM_ECLASS
80
81 DESCRIPTION="LibreOffice, a full office productivity suite."
82 HOMEPAGE="http://www.libreoffice.org"
83 SRC_URI="branding? ( http://dev.gentoo.org/~dilfridge/distfiles/${BRANDING} )"
84 [[ -n ${PATCHSET} ]] && SRC_URI+=" http://dev.gentooexperimental.org/~scarabeus/${PATCHSET}"
85
86 # Split modules following git/tarballs
87 # Core MUST be first!
88 # Help is used for the image generator
89 MODULES="core help"
90 # Only release has the tarballs
91 if [[ ${PV} != *9999* ]]; then
92 for i in ${DEV_URI}; do
93 for mod in ${MODULES}; do
94 if [[ ${mod} == core ]]; then
95 SRC_URI+=" ${i}/${P}.tar.xz"
96 else
97 SRC_URI+=" ${i}/${PN}-${mod}-${PV}.tar.xz"
98 fi
99 done
100 unset mod
101 done
102 unset i
103 fi
104 unset DEV_URI
105
106 # Really required addons
107 # These are bundles that can't be removed for now due to huge patchsets.
108 # If you want them gone, patches are welcome.
109 ADDONS_SRC+=" ${ADDONS_URI}/d62650a6f908e85643e557a236ea989c-vigra1.6.0.tar.gz"
110 ADDONS_SRC+=" ${ADDONS_URI}/1f24ab1d39f4a51faf22244c94a6203f-xmlsec1-1.2.14.tar.gz" # modifies source code
111 ADDONS_SRC+=" java? ( ${ADDONS_URI}/17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip )"
112 ADDONS_SRC+=" libreoffice_extensions_wiki-publisher? ( ${ADDONS_URI}/a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip )" # no release for 8 years, should we package it?
113 ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip )" # Does not build with 1.6 rhino at all
114 ADDONS_SRC+=" libreoffice_extensions_scripting-javascript? ( ${ADDONS_URI}/35c94d2df8893241173de1d16b6034c0-swingExSrc.zip )" # requirement of rhino
115 ADDONS_SRC+=" odk? ( http://download.go-oo.org/extern/185d60944ea767075d27247c3162b3bc-unowinreg.dll )" # not packageable
116 SRC_URI+=" ${ADDONS_SRC}"
117
118 unset ADDONS_URI
119 unset EXT_URI
120 unset ADDONS_SRC
121
122 IUSE="bluetooth +branding +cups dbus debug eds firebird gnome gstreamer +gtk
123 gtk3 jemalloc kde mysql odk opengl postgres telepathy test +vba vlc +webdav"
124
125 LO_EXTS="nlpsolver scripting-beanshell scripting-javascript wiki-publisher"
126 # Unpackaged separate extensions:
127 # diagram: lo has 0.9.5 upstream is weirdly patched 0.9.4 -> wtf?
128 # hunart: only on ooo extensions -> fubared download path somewhere on sf
129 # numbertext, typo, validator, watch-window: ^^
130 # oooblogger: no homepage or anything
131 # Extensions that need extra work:
132 for lo_xt in ${LO_EXTS}; do
133 IUSE+=" libreoffice_extensions_${lo_xt}"
134 done
135 unset lo_xt
136
137 LICENSE="|| ( LGPL-3 MPL-1.1 )"
138 SLOT="0"
139 [[ ${PV} == *9999* ]] || \
140 KEYWORDS="~amd64 ~arm ~ppc ~x86 ~amd64-linux ~x86-linux"
141
142 COMMON_DEPEND="
143 ${PYTHON_DEPS}
144 app-arch/zip
145 app-arch/unzip
146 >=app-text/hunspell-1.3.2-r3
147 app-text/mythes
148 app-text/libabw
149 >=app-text/libexttextcat-3.2
150 app-text/libebook
151 app-text/libetonyek
152 app-text/liblangtag
153 app-text/libmspub
154 >=app-text/libmwaw-0.2
155 >=app-text/libodfgen-0.0.3
156 app-text/libwpd:0.9[tools]
157 app-text/libwpg:0.2
158 >=app-text/libwps-0.2.2
159 >=app-text/poppler-0.16:=[xpdf-headers(+),cxx]
160 >=dev-cpp/clucene-2.3.3.4-r2
161 dev-cpp/libcmis:0.4
162 dev-db/unixODBC
163 >=dev-libs/boost-1.46:=
164 dev-libs/expat
165 >=dev-libs/hyphen-2.7.1
166 >=dev-libs/icu-4.8.1.1:=
167 >=dev-libs/libatomic_ops-7.2d
168 =dev-libs/liborcus-0.5*:=
169 >=dev-libs/nspr-4.8.8
170 >=dev-libs/nss-3.12.9
171 >=dev-lang/perl-5.0
172 >=dev-libs/openssl-1.0.0d
173 >=dev-libs/redland-1.0.16[ssl]
174 media-gfx/graphite2
175 >=media-libs/fontconfig-2.8.0
176 media-libs/freetype:2
177 >=media-libs/harfbuzz-0.9.18:=[icu(+)]
178 media-libs/lcms:2
179 >=media-libs/libpng-1.4
180 >=media-libs/libcdr-0.0.5
181 media-libs/libfreehand
182 media-libs/libvisio
183 >=net-misc/curl-7.21.4
184 net-nds/openldap
185 sci-mathematics/lpsolve
186 virtual/jpeg:0
187 >=x11-libs/cairo-1.10.0[X]
188 x11-libs/libXinerama
189 x11-libs/libXrandr
190 x11-libs/libXrender
191 bluetooth? ( net-wireless/bluez )
192 cups? ( net-print/cups )
193 dbus? ( >=dev-libs/dbus-glib-0.92 )
194 eds? ( gnome-extra/evolution-data-server )
195 firebird? ( >=dev-db/firebird-2.5 )
196 gnome? ( gnome-base/gconf:2 )
197 gtk? (
198 x11-libs/gdk-pixbuf[X]
199 >=x11-libs/gtk+-2.24:2
200 )
201 gtk3? ( >=x11-libs/gtk+-3.2:3 )
202 gstreamer? (
203 media-libs/gstreamer:1.0
204 media-libs/gst-plugins-base:1.0
205 )
206 jemalloc? ( dev-libs/jemalloc )
207 libreoffice_extensions_scripting-beanshell? ( >=dev-java/bsh-2.0_beta4 )
208 libreoffice_extensions_scripting-javascript? ( dev-java/rhino:1.6 )
209 libreoffice_extensions_wiki-publisher? (
210 dev-java/commons-codec:0
211 dev-java/commons-httpclient:3
212 dev-java/commons-lang:2.1
213 dev-java/commons-logging:0
214 dev-java/tomcat-servlet-api:3.0
215 )
216 mysql? ( >=dev-db/mysql-connector-c++-1.1.0 )
217 opengl? (
218 virtual/glu
219 virtual/opengl
220 )
221 postgres? ( >=dev-db/postgresql-base-9.0[kerberos] )
222 telepathy? (
223 dev-libs/glib:2
224 >=net-libs/telepathy-glib-0.18.0
225 >=x11-libs/gtk+-2.24:2
226 )
227 webdav? ( net-libs/neon )
228 "
229
230 RDEPEND="${COMMON_DEPEND}
231 !app-office/libreoffice-bin
232 !app-office/libreoffice-bin-debug
233 !<app-office/openoffice-bin-3.4.0-r1
234 !app-office/openoffice
235 media-fonts/libertine-ttf
236 media-fonts/liberation-fonts
237 media-fonts/urw-fonts
238 java? ( >=virtual/jre-1.6 )
239 vlc? ( media-video/vlc )
240 "
241
242 if [[ ${PV} != *9999* ]]; then
243 PDEPEND="~app-office/libreoffice-l10n-${PV}"
244 else
245 # Translations are not reliable on live ebuilds
246 # rather force people to use english only.
247 PDEPEND="!app-office/libreoffice-l10n"
248 fi
249
250 # FIXME: cppunit should be moved to test conditional
251 # after everything upstream is under gbuild
252 # as dmake execute tests right away
253 DEPEND="${COMMON_DEPEND}
254 >=dev-libs/libxml2-2.7.8
255 dev-libs/libxslt
256 dev-perl/Archive-Zip
257 dev-util/cppunit
258 >=dev-util/gperf-3
259 dev-util/intltool
260 >=dev-util/mdds-0.10.2:=
261 virtual/pkgconfig
262 net-misc/npapi-sdk
263 >=sys-apps/findutils-4.4.2
264 sys-devel/bison
265 sys-apps/coreutils
266 sys-devel/flex
267 sys-devel/gettext
268 >=sys-devel/make-3.82
269 sys-devel/ucpp
270 sys-libs/zlib
271 x11-libs/libXt
272 x11-libs/libXtst
273 x11-proto/randrproto
274 x11-proto/xextproto
275 x11-proto/xineramaproto
276 x11-proto/xproto
277 java? (
278 >=virtual/jdk-1.6
279 >=dev-java/ant-core-1.7
280 )
281 odk? ( >=app-doc/doxygen-1.8.4 )
282 test? ( dev-util/cppunit )
283 "
284
285 PATCHES=(
286 # not upstreamable stuff
287 "${FILESDIR}/${PN}-3.7-system-pyuno.patch"
288
289 # staged for git master
290 "${FILESDIR}/${PN}-4.2.0.4-curl-config.patch"
291 )
292
293 REQUIRED_USE="
294 ${PYTHON_REQUIRED_USE}
295 bluetooth? ( dbus )
296 gnome? ( gtk )
297 eds? ( gnome )
298 telepathy? ( gtk )
299 libreoffice_extensions_nlpsolver? ( java )
300 libreoffice_extensions_scripting-beanshell? ( java )
301 libreoffice_extensions_scripting-javascript? ( java )
302 libreoffice_extensions_wiki-publisher? ( java )
303 "
304
305 CHECKREQS_MEMORY="512M"
306 CHECKREQS_DISK_BUILD="6G"
307
308 pkg_pretend() {
309 local pgslot
310
311 if [[ ${MERGE_TYPE} != binary ]]; then
312 check-reqs_pkg_pretend
313
314 if [[ $(gcc-major-version) -lt 4 ]] || \
315 ( [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 6 ]] ) \
316 ; then
317 eerror "Compilation with gcc older than 4.6 is not supported"
318 die "Too old gcc found."
319 fi
320 fi
321
322 # Ensure pg version but we have to be sure the pg is installed (first
323 # install on clean system)
324 if use postgres && has_version dev-db/postgresql-base; then
325 pgslot=$(postgresql-config show)
326 if [[ ${pgslot//.} < 90 ]] ; then
327 eerror "PostgreSQL slot must be set to 9.0 or higher."
328 eerror " postgresql-config set 9.0"
329 die "PostgreSQL slot is not set to 9.0 or higher."
330 fi
331 fi
332 }
333
334 pkg_setup() {
335 java-pkg-opt-2_pkg_setup
336 kde4-base_pkg_setup
337 python-single-r1_pkg_setup
338
339 [[ ${MERGE_TYPE} != binary ]] && check-reqs_pkg_setup
340 }
341
342 src_unpack() {
343 local mod mod2 dest tmplfile tmplname mypv
344
345 [[ -n ${PATCHSET} ]] && unpack ${PATCHSET}
346 use branding && unpack "${BRANDING}"
347
348 if [[ ${PV} != *9999* ]]; then
349 unpack "${P}.tar.xz"
350 for mod in ${MODULES}; do
351 [[ ${mod} == core ]] && continue
352 unpack "${PN}-${mod}-${PV}.tar.xz"
353 done
354 else
355 for mod in ${MODULES}; do
356 mypv=${PV/.9999}
357 [[ ${mypv} != ${PV} ]] && EGIT_BRANCH="${PN}-${mypv/./-}"
358 EGIT_PROJECT="${PN}/${mod}"
359 EGIT_SOURCEDIR="${WORKDIR}/${P}"
360 [[ ${mod} != core ]] && EGIT_SOURCEDIR="${WORKDIR}/${PN}-${mod}-${PV}"
361 EGIT_REPO_URI="git://anongit.freedesktop.org/${PN}/${mod}"
362 EGIT_NOUNPACK="true"
363 git-2_src_unpack
364 if [[ ${mod} != core ]]; then
365 mod2=${mod}
366 # mapping does not match on help
367 [[ ${mod} == help ]] && mod2="helpcontent2"
368 mkdir -p "${S}/${mod2}/" || die
369 mv -n "${WORKDIR}/${PN}-${mod}-${PV}"/* "${S}/${mod2}" || die
370 rm -rf "${WORKDIR}/${PN}-${mod}-${PV}"
371 fi
372 done
373 unset EGIT_PROJECT EGIT_SOURCEDIR EGIT_REPO_URI EGIT_BRANCH
374 fi
375 }
376
377 src_prepare() {
378 # optimization flags
379 export GMAKE_OPTIONS="${MAKEOPTS}"
380 # System python 2.7 enablement:
381 export PYTHON_CFLAGS=$(python_get_CFLAGS)
382 export PYTHON_LIBS=$(python_get_LIBS)
383
384 # patchset
385 if [[ -n ${PATCHSET} ]]; then
386 EPATCH_FORCE="yes" \
387 EPATCH_SOURCE="${WORKDIR}/${PATCHSET/.tar.xz/}" \
388 EPATCH_SUFFIX="patch" \
389 epatch
390 fi
391
392 base_src_prepare
393
394 AT_M4DIR="m4" eautoreconf
395 # hack in the autogen.sh
396 touch autogen.lastrun
397
398 # system pyuno mess
399 sed \
400 -e "s:%eprefix%:${EPREFIX}:g" \
401 -e "s:%libdir%:$(get_libdir):g" \
402 -i pyuno/source/module/uno.py \
403 -i scripting/source/pyprov/officehelper.py || die
404 # sed in the tests
405 sed -i \
406 -e 's#all : build unitcheck#all : build#g' \
407 solenv/gbuild/Module.mk || die
408 sed -i \
409 -e 's#check: dev-install subsequentcheck#check: unitcheck slowcheck dev-install subsequentcheck#g' \
410 -e 's#Makefile.gbuild all slowcheck#Makefile.gbuild all#g' \
411 Makefile.in || die
412
413 if use branding; then
414 # hack...
415 mv -v "${WORKDIR}/branding-intro.png" "${S}/icon-themes/galaxy/brand/intro.png" || die
416 fi
417 }
418
419 src_configure() {
420 local java_opts
421 local internal_libs
422 local lo_ext
423 local ext_opts
424 local jbs=$(sed -ne 's/.*\(-j[[:space:]]*\|--jobs=\)\([[:digit:]]\+\).*/\2/;T;p' <<< "${MAKEOPTS}")
425
426 # recheck that there is some value in jobs
427 [[ -z ${jbs} ]] && jbs="1"
428
429 # sane: just sane.h header that is used for scan in writer, not
430 # linked or anything else, worthless to depend on
431 # vigra: just uses templates from there
432 # it is serious pain in the ass for packaging
433 # should be replaced by boost::gil if someone interested
434 internal_libs+="
435 --without-system-sane
436 --without-system-vigra
437 "
438
439 # libreoffice extensions handling
440 for lo_xt in ${LO_EXTS}; do
441 if [[ "${lo_xt}" == "scripting-beanshell" || "${lo_xt}" == "scripting-javascript" ]]; then
442 ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ${lo_xt})"
443 else
444 ext_opts+=" $(use_enable libreoffice_extensions_${lo_xt} ext-${lo_xt})"
445 fi
446 done
447
448 if use java; then
449 # hsqldb: system one is too new
450 java_opts="
451 --without-junit
452 --without-system-hsqldb
453 --with-ant-home="${ANT_HOME}"
454 --with-jdk-home=$(java-config --jdk-home 2>/dev/null)
455 --with-jvm-path="${EPREFIX}/usr/lib/"
456 "
457
458 use libreoffice_extensions_scripting-beanshell && \
459 java_opts+=" --with-beanshell-jar=$(java-pkg_getjar bsh bsh.jar)"
460
461 use libreoffice_extensions_scripting-javascript && \
462 java_opts+=" --with-rhino-jar=$(java-pkg_getjar rhino-1.6 js.jar)"
463
464 if use libreoffice_extensions_wiki-publisher; then
465 java_opts+="
466 --with-commons-codec-jar=$(java-pkg_getjar commons-codec commons-codec.jar)
467 --with-commons-httpclient-jar=$(java-pkg_getjar commons-httpclient-3 commons-httpclient.jar)
468 --with-commons-lang-jar=$(java-pkg_getjar commons-lang-2.1 commons-lang.jar)
469 --with-commons-logging-jar=$(java-pkg_getjar commons-logging commons-logging.jar)
470 --with-servlet-api-jar=$(java-pkg_getjar tomcat-servlet-api-3.0 servlet-api.jar)
471 "
472 fi
473 fi
474
475 # system headers/libs/...: enforce using system packages
476 # --enable-cairo: ensure that cairo is always required
477 # --enable-graphite: disabling causes build breakages
478 # --enable-*-link: link to the library rather than just dlopen on runtime
479 # --enable-release-build: build the libreoffice as release
480 # --disable-fetch-external: prevent dowloading during compile phase
481 # --disable-gnome-vfs: old gnome virtual fs support
482 # --disable-kdeab: kde3 adressbook
483 # --disable-kde: kde3 support
484 # --disable-systray: quickstarter does not actually work at all so do not
485 # promote it
486 # --enable-extension-integration: enable any extension integration support
487 # --without-{afms,fonts,myspell-dicts,ppsd}: prevent install of sys pkgs
488 # --disable-report-builder: too much java packages pulled in without pkgs
489 econf \
490 --docdir="${EPREFIX}/usr/share/doc/${PF}/" \
491 --with-system-headers \
492 --with-system-libs \
493 --with-system-jars \
494 --with-system-dicts \
495 --enable-cairo-canvas \
496 --enable-graphite \
497 --enable-largefile \
498 --enable-mergelibs \
499 --enable-python=system \
500 --enable-randr \
501 --enable-randr-link \
502 --enable-release-build \
503 --disable-hardlink-deliver \
504 --disable-ccache \
505 --disable-crashdump \
506 --disable-dependency-tracking \
507 --disable-epm \
508 --disable-fetch-external \
509 --disable-gnome-vfs \
510 --disable-gstreamer-0-10 \
511 --disable-report-builder \
512 --disable-kdeab \
513 --disable-kde \
514 --disable-online-update \
515 --disable-systray \
516 --with-alloc=$(use jemalloc && echo "jemalloc" || echo "system") \
517 --with-build-version="Gentoo official package" \
518 --enable-extension-integration \
519 --with-external-dict-dir="${EPREFIX}/usr/share/myspell" \
520 --with-external-hyph-dir="${EPREFIX}/usr/share/myspell" \
521 --with-external-thes-dir="${EPREFIX}/usr/share/myspell" \
522 --with-external-tar="${DISTDIR}" \
523 --with-lang="" \
524 --with-parallelism=${jbs} \
525 --with-system-ucpp \
526 --with-vendor="Gentoo Foundation" \
527 --with-x \
528 --without-afms \
529 --without-fonts \
530 --without-myspell-dicts \
531 --without-help \
532 --with-helppack-integration \
533 --without-sun-templates \
534 $(use_enable bluetooth sdremote-bluetooth) \
535 $(use_enable cups) \
536 $(use_enable debug) \
537 $(use_enable dbus) \
538 $(use_enable eds evolution2) \
539 $(use_enable firebird firebird-sdbc) \
540 $(use_enable gnome gconf) \
541 $(use_enable gnome gio) \
542 $(use_enable gnome lockdown) \
543 $(use_enable gstreamer) \
544 $(use_enable gtk) \
545 $(use_enable gtk3) \
546 $(use_enable kde kde4) \
547 $(use_enable mysql ext-mariadb-connector) \
548 $(use_enable odk) \
549 $(use_enable opengl) \
550 $(use_enable postgres postgresql-sdbc) \
551 $(use_enable telepathy) \
552 $(use_enable vba) \
553 $(use_enable vlc) \
554 $(use_enable webdav neon) \
555 $(use_with java) \
556 $(use_with mysql system-mysql-cppconn) \
557 $(use_with odk doxygen) \
558 ${internal_libs} \
559 ${java_opts} \
560 ${ext_opts}
561 }
562
563 src_compile() {
564 # hack for offlinehelp, this needs fixing upstream at some point
565 # it is broken because we send --without-help
566 # https://bugs.freedesktop.org/show_bug.cgi?id=46506
567 (
568 grep "^export" "${S}/config_host.mk" > "${T}/config_host.mk"
569 source "${T}/config_host.mk" 2&> /dev/null
570
571 local path="${WORKDIR}/helpcontent2/source/auxiliary/"
572 mkdir -p "${path}" || die
573
574 echo "perl \"${S}/helpcontent2/helpers/create_ilst.pl\" -dir=icon-themes/galaxy/res/helpimg > \"${path}/helpimg.ilst\""
575 perl "${S}/helpcontent2/helpers/create_ilst.pl" \
576 -dir=icon-themes/galaxy/res/helpimg \
577 > "${path}/helpimg.ilst"
578 [[ -s "${path}/helpimg.ilst" ]] || ewarn "The help images list is empty, something is fishy, report a bug."
579 )
580
581 local target
582 use test && target="build" || target="build-nocheck"
583
584 # this is not a proper make script
585 make ${target} || die
586 }
587
588 src_test() {
589 make unitcheck || die
590 make slowcheck || die
591 }
592
593 src_install() {
594 # This is not Makefile so no buildserver
595 make DESTDIR="${D}" distro-pack-install -o build -o check || die
596
597 # Fix bash completion placement
598 newbashcomp "${ED}"/etc/bash_completion.d/libreoffice.sh ${PN}
599 rm -rf "${ED}"/etc/
600
601 if use branding; then
602 insinto /usr/$(get_libdir)/${PN}/program
603 newins "${WORKDIR}/branding-sofficerc" sofficerc
604 echo "CONFIG_PROTECT=/usr/$(get_libdir)/${PN}/program/sofficerc" > "${ED}"/etc/env.d/99${PN}
605 fi
606
607 # symlink the nsplugin to proper location
608 # use gtk && inst_plugin /usr/$(get_libdir)/libreoffice/program/libnpsoplugin.so
609
610 # Hack for offlinehelp, this needs fixing upstream at some point.
611 # It is broken because we send --without-help
612 # https://bugs.freedesktop.org/show_bug.cgi?id=46506
613 insinto /usr/$(get_libdir)/libreoffice/help
614 doins xmlhelp/util/*.xsl
615
616 # Remove desktop files for support to old installs that can't parse mime
617 rm -rf "${ED}"/usr/share/mimelnk/
618
619 pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/soffice.bin
620 pax-mark -m "${ED}"/usr/$(get_libdir)/libreoffice/program/unopkg.bin
621 }
622
623 pkg_preinst() {
624 # Cache updates - all handled by kde eclass for all environments
625 kde4-base_pkg_preinst
626 }
627
628 pkg_postinst() {
629 kde4-base_pkg_postinst
630
631 use java || \
632 ewarn 'If you plan to use lbase application you should enable java or you will get various crashes.'
633 }
634
635 pkg_postrm() {
636 kde4-base_pkg_postrm
637 }