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