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