Build error on Raspbian, "undefined reference to `__atomic_load_8'"

1,605 views
Skip to first unread message

Jens Alfke

unread,
Apr 8, 2022, 3:30:22 PM4/8/22
to Cap'n Proto
I'm building CapnP 0.9.1 from source on a new Raspberry Pi 4 running Raspbian (because apt only has version 0.7.) 

tar zxf capnproto-c++-0.9.1.tar.gz
cd capnproto-c++-0.9.1
./configure
make -j6 check
sudo make install

Everything went fine until the final "sudo make install" step:

...
libtool: link: g++ -I./src -I./src -DKJ_HEADER_WARNINGS -DCAPNP_HEADER_WARNINGS -DCAPNP_INCLUDE_DIR=\"/usr/local/include\" -pthread -O2 -DNDEBUG -pthread -DKJ_HAS_ZLIB -pthread -o .libs/capnp src/capnp/compiler/module-loader.o src/capnp/compiler/capnp.o  ./.libs/libcapnpc.so ./.libs/libcapnp-json.so ./.libs/libcapnp.so ./.libs/libkj.so -lpthread -pthread
/usr/bin/ld: ./.libs/libcapnp.so: undefined reference to `__atomic_load_8'
/usr/bin/ld: ./.libs/libcapnp.so: undefined reference to `__atomic_store_8’

I’m guessing the missing symbols are CPU intrinsics for 64-bit atomic operations. Could this have something to do with the fact that Raspbian is still running in 32-bit on a 64-bit CPU?

—Jens

Kenton Varda

unread,
Apr 8, 2022, 4:49:25 PM4/8/22
to Jens Alfke, Cap'n Proto

--
You received this message because you are subscribed to the Google Groups "Cap'n Proto" group.
To unsubscribe from this group and stop receiving emails from it, send an email to capnproto+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/capnproto/D31A68E1-75DA-404E-99D4-74A02525A562%40mooseyard.com.
Reply all
Reply to author
Forward
0 new messages