Build failure on x86 linux: undefined reference to `__atomic_load'

Rene Engelhard rene at debian.org
Wed Sep 15 20:54:53 UTC 2021


Hi,

Am 15.09.21 um 02:34 schrieb Luke Benes:
> [DEP] LNK:Library/libsvllo.so
> [LNK] Library/libsvllo.so
> /usr/lib/gcc/i586-suse-linux/11/../../../../i586-suse-linux/bin/ld: /core/workdir/CxxObject/svl/source/misc/sharedstringpool.o: in function `libcuckoo::cuckoohash_map<_rtl_uString*, std::pair<rtl::OUString, rtl::OUString>, svl::(anonymous namespace)::HashFunction, svl::(anonymous namespace)::EqualsFunction, std::allocator<std::pair<_rtl_uString* const, std::pair<rtl::OUString, rtl::OUString> > >, 4u>::cuckoo_status libcuckoo::cuckoohash_map<_rtl_uString*, std::pair<rtl::OUString, rtl::OUString>, svl::(anonymous namespace)::HashFunction, svl::(anonymous namespace)::EqualsFunction, std::allocator<std::pair<_rtl_uString* const, std::pair<rtl::OUString, rtl::OUString> > >, 4u>::cuckoo_fast_double<std::integral_constant<bool, false>, std::integral_constant<bool, true> >(unsigned int)':
> sharedstringpool.cxx:(.text+0x14ec): undefined reference to `__atomic_load'
> /usr/lib/gcc/i586-suse-linux/11/../../../../i586-suse-linux/bin/ld: sharedstringpool.cxx:(.text+0x17f6): undefined reference to `__atomic_load'
> clang-12: error: linker command failed with exit code 1 (use -v to see invocation)
> make[1]: *** [/core/svl/Library_svl.mk:20: /core/instdir/program/libsvllo.so] Error 1
> make[1]: *** Waiting for unfinished jobs....
> make: *** [Makefile:288: build] Error 2

Hmm, trying to reproduce... It builds for me:

[build DEP] LNK:Library/libsvllo.so
[build LNK] Library/libsvllo.so
S=/home/rene/LibreOffice/git/master && I=$S/instdir && W=$S/workdir && 
mkdir -p $W/Dep/LinkTarget/Library/ && RESPONSEFILE=/tmp/gbuild.rt7Maz
&&
LD_LIBRARY_PATH=${LD_LIBRARY_PATH:+$LD_LIBRARY_PATH:}"$I/program:$I/program"  
$W/LinkTarget/Executable/concat-deps ${RESPONSEFILE} >
$W/Dep/LinkTarget/Library/libsvllo.so.d.tmp && rm -f ${RESPONSEFILE}
mv
/home/rene/LibreOffice/git/master/workdir/Dep/LinkTarget/Library/libsvllo.so.d.tmp
/home/rene/LibreOffice/git/master/workdir/Dep/LinkTarget/Library/libsvllo.so.d
S=/home/rene/LibreOffice/git/master && I=$S/instdir && W=$S/workdir && 
/usr/bin/ccache i686-linux-gnu-g++ -pthread -shared -Wl,-z,noexecstack  
-Wl,-z,origin '-Wl,-rpath,$ORIGIN' -Wl,-rpath-link,$I/program 
-Wl,-z,defs -Wl,-rpath-link,/lib:/usr/lib -Wl,-z,combreloc 
-Wl,--hash-style=gnu  -Wl,-Bsymbolic-functions
-L$W/LinkTarget/StaticLibrary -L$I/sdk/lib  -L$I/program  -L$I/program
-Wl,-z,relro  $W/CxxObject/svl/source/config/asiancfg.o
$W/CxxObject/svl/source/config/cjkoptions.o
$W/CxxObject/svl/source/config/ctloptions.o
$W/CxxObject/svl/source/config/itemholder2.o
$W/CxxObject/svl/source/config/languageoptions.o
$W/CxxObject/svl/source/crypto/cryptosign.o
$W/CxxObject/svl/source/filepicker/pickerhistory.o
$W/CxxObject/svl/source/items/aeitem.o
$W/CxxObject/svl/source/items/cenumitm.o
$W/CxxObject/svl/source/items/cintitem.o
$W/CxxObject/svl/source/items/custritm.o
$W/CxxObject/svl/source/items/flagitem.o
$W/CxxObject/svl/source/items/globalnameitem.o
$W/CxxObject/svl/source/items/grabbagitem.o
$W/CxxObject/svl/source/items/ilstitem.o
$W/CxxObject/svl/source/items/imageitm.o
$W/CxxObject/svl/source/items/intitem.o
$W/CxxObject/svl/source/items/int64item.o
$W/CxxObject/svl/source/items/itemiter.o
$W/CxxObject/svl/source/items/itempool.o
$W/CxxObject/svl/source/items/itemprop.o
$W/CxxObject/svl/source/items/IndexedStyleSheets.o
$W/CxxObject/svl/source/items/itemset.o
$W/CxxObject/svl/source/items/lckbitem.o
$W/CxxObject/svl/source/items/legacyitem.o
$W/CxxObject/svl/source/items/macitem.o
$W/CxxObject/svl/source/items/poolcach.o
$W/CxxObject/svl/source/items/poolio.o
$W/CxxObject/svl/source/items/poolitem.o
$W/CxxObject/svl/source/items/ptitem.o
$W/CxxObject/svl/source/items/rectitem.o
$W/CxxObject/svl/source/items/rngitem.o
$W/CxxObject/svl/source/items/sitem.o
$W/CxxObject/svl/source/items/slstitm.o
$W/CxxObject/svl/source/items/srchitem.o
$W/CxxObject/svl/source/items/stringio.o
$W/CxxObject/svl/source/items/stritem.o
$W/CxxObject/svl/source/items/style.o
$W/CxxObject/svl/source/items/stylepool.o
$W/CxxObject/svl/source/items/visitem.o
$W/CxxObject/svl/source/items/whiter.o
$W/CxxObject/svl/source/misc/PasswordHelper.o
$W/CxxObject/svl/source/misc/adrparse.o
$W/CxxObject/svl/source/misc/documentlockfile.o
$W/CxxObject/svl/source/misc/msodocumentlockfile.o
$W/CxxObject/svl/source/misc/filenotation.o
$W/CxxObject/svl/source/misc/fstathelper.o
$W/CxxObject/svl/source/misc/getstringresource.o
$W/CxxObject/svl/source/misc/gridprinter.o
$W/CxxObject/svl/source/misc/inethist.o
$W/CxxObject/svl/source/misc/inettype.o
$W/CxxObject/svl/source/misc/lngmisc.o
$W/CxxObject/svl/source/misc/lockfilecommon.o
$W/CxxObject/svl/source/misc/ownlist.o
$W/CxxObject/svl/source/misc/sharecontrolfile.o
$W/CxxObject/svl/source/misc/sharedstring.o
$W/CxxObject/svl/source/misc/sharedstringpool.o
$W/CxxObject/svl/source/misc/strmadpt.o
$W/CxxObject/svl/source/misc/urihelper.o
$W/CxxObject/svl/source/notify/SfxBroadcaster.o
$W/CxxObject/svl/source/notify/broadcast.o
$W/CxxObject/svl/source/notify/hint.o
$W/CxxObject/svl/source/notify/isethint.o
$W/CxxObject/svl/source/notify/listener.o
$W/CxxObject/svl/source/notify/lstner.o
$W/CxxObject/svl/source/numbers/currencytable.o
$W/CxxObject/svl/source/numbers/numfmuno.o
$W/CxxObject/svl/source/numbers/numuno.o
$W/CxxObject/svl/source/numbers/supservs.o
$W/CxxObject/svl/source/numbers/zforfind.o
$W/CxxObject/svl/source/numbers/zforlist.o
$W/CxxObject/svl/source/numbers/zformat.o
$W/CxxObject/svl/source/numbers/zforscan.o
$W/CxxObject/svl/source/svsql/converter.o
$W/CxxObject/svl/source/undo/undo.o
$W/CxxObject/svl/source/uno/pathservice.o
$W/CxxObject/svl/unx/source/svdde/ddedummy.o      -Wl,--start-group
$W/LinkTarget/StaticLibrary/libdtoa.a -lcurl -licuuc -lxml2 -lnss3
-lnssutil3 -lsmime3 -lssl3 -lplds4 -lplc4 -lnspr4  -lnss3 -lnssutil3
-lsmime3 -lssl3 -lplds4 -lplc4 -lnspr4  -lnss3 -lnssutil3 -lsmime3
-lssl3 -lplds4 -lplc4 -lnspr4  -lnss3 -lnssutil3 -lsmime3 -lssl3 -lplds4
-lplc4 -lnspr4   -Wl,--end-group -Wl,--no-as-needed -lbasegfxlo
-lcomphelper -luno_cppu -luno_cppuhelpergcc3 -li18nlangtag -li18nutil
-ljvmfwklo -luno_sal -luno_salhelpergcc3 -lsotlo -ltllo -lucbhelper
-lutllo  -o $I/program/libsvllo.so
S=/home/rene/LibreOffice/git/master && I=$S/instdir && W=$S/workdir && 
i686-linux-gnu-readelf -d $I/program/libsvllo.so | grep SONAME >
$W/LinkTarget/Library/libsvllo.so.exports.tmp; i686-linux-gnu-nm 
--dynamic --extern-only --defined-only --format=posix
$I/program/libsvllo.so | cut -d' ' -f1-2 >>
$W/LinkTarget/Library/libsvllo.so.exports.tmp && if cmp -s
$W/LinkTarget/Library/libsvllo.so.exports.tmp 
$W/LinkTarget/Library/libsvllo.so.exports; then rm
$W/LinkTarget/Library/libsvllo.so.exports.tmp; else mv
$W/LinkTarget/Library/libsvllo.so.exports.tmp 
$W/LinkTarget/Library/libsvllo.so.exports && touch -r
$I/program/libsvllo.so  $W/LinkTarget/Library/libsvllo.so.exports; fi

FWIW:

$ g++ -v; dpkg -l libc6
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/i686-linux-gnu/10/lto-wrapper
Target: i686-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian
10.3.0-10' --with-bugurl=file:///usr/share/doc/gcc-10/README.Bugs
--enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,m2
--prefix=/usr --with-gcc-major-version-only --program-suffix=-10
--program-prefix=i686-linux-gnu- --enable-shared
--enable-linker-build-id --libexecdir=/usr/lib
--without-included-gettext --enable-threads=posix --libdir=/usr/lib
--enable-nls --enable-bootstrap --enable-clocale=gnu
--enable-libstdcxx-debug --enable-libstdcxx-time=yes
--with-default-libstdcxx-abi=new --enable-gnu-unique-object
--disable-vtable-verify --enable-plugin --enable-default-pie
--with-system-zlib --enable-libphobos-checking=release
--with-target-system-zlib=auto --enable-objc-gc=auto
--enable-targets=all --enable-multiarch --disable-werror
--with-arch-32=i686 --with-multilib-list=m32,m64,mx32 --enable-multilib
--with-tune=generic --enable-checking=release --build=i686-linux-gnu
--host=i686-linux-gnu --target=i686-linux-gnu
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 10.3.0 (Debian 10.3.0-10)
Desired=Unknown/Install/Remove/Purge/Hold
|
Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
ii  libc6:i386     2.32-3       i386         GNU C Library: Shared librarie

(and system-cuckoo of course, but given that that one isn't patched...)


Maybe i586 vs. i686?

Regards,


Rene



More information about the LibreOffice mailing list