Dear All,

On Tue, Aug 01, 2023 at 11:57:09AM +0200, Peter Kovacs wrote:

> hello Don,
> 
> were you able to look into this, or the freeBsd volunteer.
> 
> I can try to put together a report for gcc if you still like that to be
> done.

If you can carve out the necessary bits, and only them, and reproduce
the problem, then it would be great IMHO.

Don, do we know if clang compiles correctly?

For what it's worth, I tried to work around this bug in this PR for AOO41X:
https://github.com/apache/openoffice/pull/198

> Am 01.04.23 um 20:12 schrieb Arrigo Marchiori:
> > Hello Don, All,
> > 
> > On Wed, Mar 29, 2023 at 11:58:06PM -0700, Don Lewis wrote:
> > 
> > > A FreeBSD user is trying to unbreak the ppc64 build and ran into an
> > > issue with the sot module.  I dig into it pretty deeply and it looks to
> > > me like a gcc bug.  It's reproducable in amd64.  It seems to affect
> > > gcc10, gcc11, and gcc12 builds.  The build failure does not happen with
> > > gcc9.
> > > 
> > > It is not limited to FreeBSD.  I get the same failure on Debian
> > > bullseye:
> > >   cc --version
> > > cc (Debian 10.2.1-6) 10.2.1 20210110
> > > Copyright (C) 2020 Free Software Foundation, Inc.
> > > This is free software; see the source for copying conditions.  There is NO
> > > warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR 
> > > PURPOSE.
> > > 
> > > [ build LNK ] Library/libsot.so
> > > /usr/bin/ld: 
> > > /home/dl/aoo/openoffice/main/solver/4111/unxlngx6.pro/workdir/CxxObject/sot/source/sdstor/ucbstorage.o:
> > >  in function `UCBStorage_Impl::Init()':
> > > ucbstorage.cxx:(.text+0x72b4): undefined reference to `non-virtual thunk 
> > > to cppu::WeakImplHelper1<com::sun::star::io::XInputStream>::acquire()'
> > > collect2: error: ld returned 1 exit status
> > > 
> > > 
> > > The problem appears to be that gcc is getting confused when compiling
> > > line 1884 of ucbstorage.cxx.  It ends up trying to call the thunk to the
> > > acquire() method of a non-existent class.  That thunk isn't defined, so
> > > the linker bombs on the undefined symbol.
> > I reproduced it with OpenSUSE Linux Leap 15.4, using the provided gcc-10.
> > 
> > However, the problem seems to be at line 1879:
> > 
> > > > com::sun::star::uno::Reference < ::com::sun::star::io::XInputStream > 
> > > > xInputStream( pHelper );
> > It seems to compile if we split it as follows:
> > 
> > > > com::sun::star::uno::Reference < ::com::sun::star::io::XInputStream > 
> > > > xInputStream;
> > > > xInputStream = pHelper;
> > This _should_ work as it is how method
> > Reference<XInputStream> UCBStorageStream_Impl::GetXInputStream()
> > does: it returns an instance of Reference<XInputStream> on which
> > it calls calls operator= with a OInputStreamWrapper
> > 
> > I have no idea how to test this, though.
> > 
> > Can you please verify if the above restores compilation?
> > 
> > Best regards,

-- 
Arrigo

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org

Reply via email to