Summary: | app-office/openoffice does not build with net-libs/xulrunner-1.9.1 | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Alexey Shvetsov <alexxy> |
Component: | New packages | Assignee: | Gentoo Office Team <office> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ab4bd, Adrian.Bassett, b.brachaczek, caster, dark.shadow, deduktionstheorem, dilfridge, dwc, eric_chaligny, evan.teran, fabio.coatti, flameeyes, gentoo-bugzilla, jcallen, M4rkusXXL, marcin.deranek, marek, mozilla, musv, nick, nikoli, paolo.pedroni, rahul, simon, vklimovs |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 268394 | ||
Attachments: |
environment
java-pkg-depend build.log.gz oo patch to work with xulrunner 1.9.1 |
Description
Alexey Shvetsov
2009-01-29 11:36:59 UTC
Created attachment 180083 [details]
environment
env
Created attachment 180085 [details]
java-pkg-depend
java-pkg-depend
Created attachment 180086 [details]
build.log.gz
build.log.gz
Could you please post the relevant build error, makes it a lot easier than having to search inside the whole build log. (In reply to comment #4) > Could you please post the relevant build error, makes it a lot easier than > having to search inside the whole build log. > Checking DLL ../unxlngx6.pro/lib/check_libvbaobjlx.uno.so ...: ok -rwxr-xr-x 1 root root 3659822 Jan 29 14:21 ../unxlngx6.pro/lib/libvbaobjlx.uno.so Making: ../unxlngx6.pro/bin/scen-US.res Making: ../unxlngx6.pro/bin/scru.res using rsc multi-res feature rsc -presponse @/var/tmp/portage/app-office/openoffice-3.0.1/temp/mkhycugh > /dev/null ------------- echo . > ../unxlngx6.pro/misc/linkinc.ls Running processes: 0 deliver -- version: 1.130 Module 'sc' delivered successfully. 170 files copied, 6 files unchanged 1 module(s): extensions need(s) to be rebuilt Reason(s): ERROR: error 65280 occurred while making /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/extensions/source/plugin/base Attention: if you build and deliver the above module(s) you may prolongue your the build issuing command "build --from extensions" rmdir /tmp/5583 make: *** [stamp/build] Error 1 This is *a* error from the log. Making: ../../unxlngx6.pro/slo/bibload.obj In file included from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/basegfx/polygon/b2dpolypolygon.hxx:36, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/vcl/region.hxx:39, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/vcl/outdev.hxx:42, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/vcl/window.hxx:37, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/vcl/syswin.hxx:37, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/vcl/dialog.hxx:37, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/desktop/source/deployment/gui/dp_gui_dialog2.hxx:36, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/desktop/source/deployment/gui/dp_gui_dialog2.cxx:40: /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/o3tl/cow_wrapper.hxx:281: warning: type qualifiers ignored on function return type /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/o3tl/cow_wrapper.hxx:285: warning: type qualifiers ignored on function return type Making: ../../../unxlngx6.pro/slo/dp_gui_theextmgr.obj In file included from ../inc/plugin/unx/plugcon.hxx:105, from ../inc/plugin/unx/sysplug.hxx:35, from ../inc/plugin/impl.hxx:85, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/extensions/source/plugin/base/service.cxx:38: /usr/include/xulrunner-1.9/unstable/npapi.h:94:1: warning: "NP_VERSION_MINOR" redefined In file included from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npupp.h:58, from ../inc/plugin/unx/plugcon.hxx:103, from ../inc/plugin/unx/sysplug.hxx:35, from ../inc/plugin/impl.hxx:85, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/extensions/source/plugin/base/service.cxx:38: /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:96:1: warning: this is the location of the previous definition In file included from ../inc/plugin/unx/plugcon.hxx:106, from ../inc/plugin/unx/sysplug.hxx:36, from ../inc/plugin/impl.hxx:86, from /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/extensions/source/plugin/base/service.cxx:39: /usr/include/xulrunner-1.9/unstable/npapi.h:155: error: redefinition of 'struct _NPP' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:210: error: previous definition of 'struct _NPP' /usr/include/xulrunner-1.9/unstable/npapi.h:159: error: invalid type in declaration before ';' token /usr/include/xulrunner-1.9/unstable/npapi.h:159: error: conflicting declaration 'typedef int NPP_t' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:213: error: 'NPP_t' has a previous declaration as 'typedef struct _NPP NPP_t' /usr/include/xulrunner-1.9/unstable/npapi.h:163: error: redefinition of 'struct _NPStream' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:219: error: previous definition of 'struct _NPStream' /usr/include/xulrunner-1.9/unstable/npapi.h:181: error: invalid type in declaration before ';' token /usr/include/xulrunner-1.9/unstable/npapi.h:181: error: conflicting declaration 'typedef int NPStream' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:226: error: 'NPStream' has a previous declaration as 'typedef struct _NPStream NPStream' /usr/include/xulrunner-1.9/unstable/npapi.h:183: error: redefinition of 'struct _NPByteRange' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:230: error: previous definition of 'struct _NPByteRange' /usr/include/xulrunner-1.9/unstable/npapi.h:188: error: invalid type in declaration before ';' token /usr/include/xulrunner-1.9/unstable/npapi.h:188: error: conflicting declaration 'typedef int NPByteRange' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:234: error: 'NPByteRange' has a previous declaration as 'typedef struct _NPByteRange NPByteRange' /usr/include/xulrunner-1.9/unstable/npapi.h:190: error: redefinition of 'struct _NPSavedData' /var/tmp/portage/app-office/openoffice-3.0.1/work/ooo/build/ooo300-m15/solver/300/unxlngx6.pro/inc/npsdk/npapi.h:238: error: previous definition of 'struct _NPSavedData' /usr/include/xulrunner-1.9/unstable/npapi.h:194: error: invalid type in declaration before ';' token /usr/include/xulrunner-1.9/unstable/npapi.h:194: error: conflicting declaration 'typedef int NPSavedData' (In reply to comment #6) > This is *a* error from the log. thanks, this is actually helpful ;) Looks like Alexey is using Firefox 3.0.1 / Xulrunner 1.9.1 which is not supported yet (it's not even in the tree). Feel free to file a bug upstream though. For the time being disable the nsplugin-use-flag for openoffice (if you don't want to downgrade to a supported Firefox) Regarding the last post: I meant Firefox 3.1, mixing up numbers here... was it fixed meanwhile or is my system-configuration an exception ? Portage 2.2_rc24 (default/linux/amd64/2008.0, gcc-4.3.3, glibc-2.9_p20081201-r2, 2.6.29-rc7-zen2_test x86_64) ================================================================= System uname: Linux-2.6.29-rc7-zen2_test-x86_64-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-glibc2.4 Timestamp of tree: Wed, 11 Mar 2009 13:20:01 +0000 app-shells/bash: 3.2_p48-r1 dev-java/java-config: 1.3.7-r1, 2.1.7 dev-lang/python: 2.5.4-r2 dev-python/pycrypto: 2.0.1-r8 dev-util/cmake: 2.6.3 sys-apps/baselayout: 2.0.0 sys-apps/openrc: 0.4.3-r2 sys-apps/sandbox: 1.4 sys-devel/autoconf: 2.13, 2.63 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.18-r4, 2.18.50.0.9, 2.19.50.0.1, 2.19.51.0.1, 2.19.51.0.2, 2.19.51.0.3 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6a virtual/os-headers: 2.6.28-r1 ACCEPT_KEYWORDS="amd64 ~amd64" CBUILD="x86_64-pc-linux-gnu" openoffice 3.0.1 and xulrunner 1.9.1_beta2 from mozilla-overlay seems to work fine here Confirming this problem. I also have Firefox 3.1 installed, from the Mozilla overlay. Not sure it is directly related, though... Ok, the reason for this is rather shocking, but probably also easy to fix, or rather work around. openoffice comes with its own copy of npapi.h, but still includes the system npapi.h first. What happened now is that the #ifdef protection for double-inclusion of the header changed between gecko 1.9 and gecko 1.9.1, if you look at /usr/include/xulrunner-1.9/stable/npapi.h it changed from #ifndef _NPAPI_H_ to #ifndef npapi_h_, but the copy inside OOo still uses #ifndef _NPAPI_H_. So, with FF 3.0 the npapi.h copy inside OOo was not used, because the #define _NPAPI_H_ from the system header prevented it to be parsed. Now, since they differ, gcc will go through the copy a second time and die from the double-definition clashes. So the fault is really that OOo is including the system and the local copy at the same time. By changing npapi_h_ back to _NPAPI_H_ in the system header I got OOo to compile. However, this is not the solution, one should rather fix OOo to not include its local copy if a system header is found. (or as a rather ugly workardoung change the #ifndef of the OOo npapi.h copy to "#if !defined(_NPAPI_H_) && !define(npapi_h_) *** Bug 273712 has been marked as a duplicate of this bug. *** I can confirm the bug and the workaround proposed by Christophe Saout *** Bug 275147 has been marked as a duplicate of this bug. *** fix summary... I have attempted aforementioned "rather ugly workaround"... Modified /usr/include/xulrunner-1.9.1/unstable/npapi.h, as follows: - #ifndef npapi_h_ + #if !defined(_NPAPI_H_) && !define(npapi_h_) Attempted re-emerge, still broken, received similar error as Comment #5... Making: ../unxlngi6.pro/bin/swen-US.res using rsc multi-res feature rsc -presponse @/var/tmp/portage/app-office/openoffice-3.1.0/temp/mkBuMMCD > /dev/null Running processes: 0 deliver -- version: 266154 Module 'sw' delivered successfully. 265 files copied, 0 files unchanged 1 module(s): extensions need(s) to be rebuilt Reason(s): ERROR: error 65280 occurred while making /var/tmp/portage/app-office/openoffice-3.1.0/work/ooo/build/ooo310-m11/extensions/source/plugin/base Attention: if you build and deliver the above module(s) you may prolongue your the build issuing command "build --from extensions" rmdir /tmp/14500 make: *** [stamp/build] Error 1 * * ERROR: app-office/openoffice-3.1.0 failed. Got the same issues here (AMD64). ERROR: error 65280 occurred while making /var/tmp/portage/app-office/openoffice-3.1.0/work/ooo/build/ooo310-m11/extensions/source/plugin/base The problems of comments #16 and #17 are probably typo-related. #if !defined(_NPAPI_H_) && !defined(npapi_h_) is the correct line (!defined instead of !define after the boolean and). (In reply to comment #18) > The problems of comments #16 and #17 are probably typo-related. > > #if !defined(_NPAPI_H_) && !defined(npapi_h_) > > is the correct line (!defined instead of !define after the boolean and). > Sorry for the double-post, but I also realized, comment #16 was also editing the wrong file. Your options are to edit the xulrunner header so that it uses the old inclusion guard, changing it to #ifndef _NPAPI_H_ #define _NPAPI_H_ or to change the header in OOo to #if !defined(_NPAPI_H_) && !defined(npapi_h_) The second option is (slightly) preferred, both aren't optimal solutions, but both with cause OpenOffice to use your system xulrunner header over its own. (In reply to comment #19) > Sorry for the double-post, but I also realized, comment #16 was also editing > the wrong file. Your options are to edit the xulrunner header so that it uses > the old inclusion guard, changing it to > > #ifndef _NPAPI_H_ > #define _NPAPI_H_ > > or to change the header in OOo to > > #if !defined(_NPAPI_H_) && !defined(npapi_h_) > > The second option is (slightly) preferred, both aren't optimal solutions, but > both with cause OpenOffice to use your system xulrunner header over its own. > I tried the second option but it still doesn't work. It yields the same error as before. The diff I "injected" in the ebuild is as follows: unchanged: --- np_sdk/mozsrc/npapi.h 2006-02-09 15:04:20.000000000 +0100 +++ np_sdk/mozsrc/npapi.h 2009-07-06 22:17:36.856489103 +0200 @@ -42,7 +42,7 @@ * Netscape client plug-in API spec */ -#ifndef _NPAPI_H_ +#if !defined(_NPAPI_H_) && !defined(npapi_h_) #define _NPAPI_H_ #ifdef __OS2__ Did I patch the wrong file? (In reply to comment #20) > > I tried the second option but it still doesn't work. It yields the same error > as before. > > The diff I "injected" in the ebuild is as follows: > unchanged: > --- np_sdk/mozsrc/npapi.h 2006-02-09 15:04:20.000000000 +0100 > +++ np_sdk/mozsrc/npapi.h 2009-07-06 22:17:36.856489103 +0200 > @@ -42,7 +42,7 @@ > * Netscape client plug-in API spec > */ > > -#ifndef _NPAPI_H_ > +#if !defined(_NPAPI_H_) && !defined(npapi_h_) > #define _NPAPI_H_ > > #ifdef __OS2__ > > Did I patch the wrong file? > Pleas allow me to reply to myself. I did not patch the wrong file, but in another file in the same directory (npupp.h) there is another check for _NPAPI_H_ which, if false, includes "npapi.h". I patched that as well and I'm trying to compile Openoffice again. I will report again at the end of the compilation run. No luck. The proposed fix doesn't work for me. :-( I'll go with USE="-nsplugin" for the time being. (In reply to comment #22) > No luck. The proposed fix doesn't work for me. :-( > > I'll go with USE="-nsplugin" for the time being. > I didn't try the patch, but USE="-nsplugin" worked for me too. What does nsplugin do exactly in OpenOffice? I couldn't make out any differences for the first look. openoffice is one of three packages that still fail with xulrunner-1.9.1 Created attachment 197670 [details, diff]
oo patch to work with xulrunner 1.9.1
Seems like npapi.h from oo is loaded as first and npapi.h system-wide as 2nd, so we need to prevent loading system-wide npapi.h (look into build.log where duplicate definition is). By adding: cp -f "${FILESDIR}/oo.patch" "${S}/patches/hotfixes" || die to src_prepere section I was able to compile openoffice with nsplugin USE flag. After compilation I noticed that plugin is not visible in FF, so I had to create symlink (this is on amd64): ln -s /usr/lib64/openoffice/program/libnpsoplugin.so /usr/lib64/mozilla-firefox/plugins/libnpsoplugin.so After restarting FF I could see oo plugin on the list, but embedded oo documents shown in FF are still empty (dont' know why).. so plugin does not work for me.. :-( (In reply to comment #26) > After compilation I noticed that plugin is not visible in FF, so I had to > create symlink (this is on amd64): > > ln -s /usr/lib64/openoffice/program/libnpsoplugin.so > /usr/lib64/mozilla-firefox/plugins/libnpsoplugin.so > This part is really not necessary, you can activate the plugin through the OOo preferences, this will create a similar symlink in your firefox user settings. Found it, thanx. Replacing '#include "npapi.h"' with '#include <npapi.h>' (a few occurrences) also allows to compile openoffice with nsplugin USE flag.. Unfortunately it still doesn't show any content in the browser (blank page). *** Bug 278111 has been marked as a duplicate of this bug. *** *** Bug 278369 has been marked as a duplicate of this bug. *** @openoffice: Ping? Sorry was out of the country for quite some time, and just trying to get back to speed...(In reply to comment #31) > @openoffice: Ping? > Sorry was out of the country for quite some time, and just trying to get back to speed... (In reply to comment #32) > Sorry was out of the country for quite some time, and just trying to get back > to speed... > As a temporary solution, please fix the deps of openoffice[nsplugin] to pull in only 1.9.0*. 1.9.1 is going to be unmasked very soon. *** Bug 278700 has been marked as a duplicate of this bug. *** Just commited a new revision of OOo 3.1.0 which brings a bunch of changes, one them supporting xulrunner 1.9.1. Thanks everyone here, especially Marcin for providing the patch! btw: patch works fine for me, can even open OOo docs in the browser (after enabling the plugin in the OOo settings) Closing *** Bug 282868 has been marked as a duplicate of this bug. *** |