When I try to build LO 7.1.3.2 I get this build error: /an/duyum/etki/ld: /libreoffice-7.1.3.2/libreoffice-7.1.3.2/workdir/CxxObject/xmloff/source/core/xmlimp.o: in function `SvXMLImport::SetAutoStyles(SvXMLStylesContext*)': xmlimp.cxx:(.text+0x8ec0): undefined reference to `non-virtual thunk to cppu::WeakImplHelper<com::sun::star::xml::sax::XFastAttributeList, com::sun::star::util::XCloneable>::acquire()' collect2: error: ld returned 1 exit status make[1]: *** [/libreoffice-7.1.3.2/libreoffice-7.1.3.2/xmloff/Library_xo.mk:20: /libreoffice-7.1.3.2/libreoffice-7.1.3.2/instdir/program/libxolo.so] Error 1 make[1]: *** Waiting for unfinished jobs.... make: *** [Makefile:274: build] Error 2 I've tried to add these lines into the xmloff/source/core/xmlimp.cxx file: template class uno::Reference< io::XInputStream > ; template class ::cppu::WeakImplHelper< css::io::XInputStream >; I still get the same error. Any ideas how to fix this? I'm compiling with gcc-11.1.0 on custom musl based distribution(similar to void linux/alpine linux).
Created attachment 172260 [details] build log Here is the complete build log until the error occurs.
Is there a reason why you aren't building master branch? (where it's likely already fixed) Not sure what the best procedure is, Stephan you tend to deal with similar build issues, can you please advise if something like this should be handled in libreoffice-7-1?
I at least can't remember having seen this issue before. (If I had seen it with a recent GCC version, I would have fixed it at least on the LO master branch.) You can check whether the issue happens to not show up on the master branch, but generally you're on your own trying to fix this issue, it appears.
Hello Ali, Please try with a master build and give us feedback. Setting this to NEEDINFO meanwhile.
I get the same compilation error with the master branch: /an/duyum/etki/ld: /libreoffice-7.2.0.0.alpha1/libreoffice-7.2.0.0.alpha1/workdir/CxxObject/xmloff/source/core/xmlimp.o: in function `SvXMLImport::SetAutoStyles(SvXMLStylesContext*)': xmlimp.cxx:(.text+0x8d96): undefined reference to `non-virtual thunk to cppu::WeakImplHelper<com::sun::star::xml::sax::XFastAttributeList, com::sun::star::util::XCloneable>::acquire()' collect2: error: ld returned 1 exit status make[1]: *** [/libreoffice-7.2.0.0.alpha1/libreoffice-7.2.0.0.alpha1/xmloff/Library_xo.mk:20: /libreoffice-7.2.0.0.alpha1/libreoffice-7.2.0.0.alpha1/instdir/program/libxolo.so] Error 1 make[1]: *** Waiting for unfinished jobs.... make: *** [Makefile:285: build] Error 2 I managed to build LO 6.4.7.2 without issues though.
[Automated Action] NeedInfo-To-Unconfirmed
Alpine Linux developers have a workaround patch for LO 6 that I have adopted to LO 7 with some additions. There is a hint on "utl::OInputStreamWrapper" that might confuse ld. Here is the bug report: https://gitlab.alpinelinux.org/alpine/aports/-/issues/12109
Created attachment 172646 [details] gcc 10 patch This patch worked before on LO 7.1 with gcc 10 and some other updates. Now the same patch is not enough to build LO 7.2.
building with clang gives me this error without the gcc patch: I/O warning : failed to load external entity "file:///libreoffice-7.1.4.1/libreoffice-7.1.4.1/external/tarballs/libreoffice-help-7.1.4.1/helpcontent2/source/text/swriter/guide/standard_template.xhp" I/O warning : failed to load external entity "file:///libreoffice-7.1.4.1/libreoffice-7.1.4.1/workdir/HelpTranslatePartTarget/tr/helpcontent2/source/text/swriter/guide/standard_template.xhp" I/O warning : failed to load external entity "file:///libreoffice-7.1.4.1/libreoffice-7.1.4.1/workdir/HelpTranslatePartTarget/sv/helpcontent2/source/text/swriter/guide/standard_template.xhp" [build CXX] test/source/diff/diff.cxx I/O warning : failed to load external entity "file:///libreoffice-7.1.4.1/libreoffice-7.1.4.1/workdir/HelpTranslatePartTarget/pt-BR/helpcontent2/source/text/swriter/guide/standard_template.xhp" I/O warning : failed to load external entity "file:///libreoffice-7.1.4.1/libreoffice-7.1.4.1/workdir/HelpTranslatePartTarget/en-GB/helpcontent2/source/text/swriter/guide/standard_template.xhp" [build CXX] test/source/callgrind.cxx [build CXX] test/source/xmltesttools.cxx [build CXX] test/source/htmltesttools.cxx [build CXX] test/source/screenshot_test.cxx [build CXX] test/source/unoapi_property_testers.cxx [build CXX] test/source/helper/form.cxx [build CXX] test/source/helper/shape.cxx [build CXX] test/source/helper/transferable.cxx [build BIN] tools [build LNK] Library/libsotlo.so [build LNK] Library/libi18nutil.so ld.lld: error: undefined symbol: non-virtual thunk to cppu::WeakImplHelper<com::sun::star::io::XInputStream>::acquire() >>> referenced by ucbstorage.cxx >>> /libreoffice-7.1.4.1/libreoffice-7.1.4.1/workdir/CxxObject/sot/source/sdstor/ucbstorage.o:(UCBStorage_Impl::Init()) clang-12: error: linker command failed with exit code 1 (use -v to see invocation) make[1]: *** [/libreoffice-7.1.4.1/libreoffice-7.1.4.1/sot/Library_sot.mk:20: /libreoffice-7.1.4.1/libreoffice-7.1.4.1/instdir/program/libsotlo.so] Error 1 make[1]: *** Waiting for unfinished jobs.... make: *** [Makefile:282: build] Error 2
I have been successfully built LO 7.1.4.1 with clang using the gcc 10 patch.
(In reply to Ali Haydar Çalışkan from comment #10) > I have been successfully built LO 7.1.4.1 with clang using the gcc 10 patch. Closing as RESOLVED NOTOURBUG For further issues in the build process, please use the development mailing list < https://wiki.documentfoundation.org/Development/Mailing_List >