Gentoo Archives: gentoo-commits

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