I’m trying to build 3.30.0 from source on a Raspbian bullseye system (I need a newer version of CMake than is supplied with bullseye, which is 3.18), and it fails with “undefined reference to `__atomic_store_8’”. I understand that this is probably a linker issue, but I have no idea how to fix it. Can someone provide some guidance?
Issue 21174 seems quite relevant, although that issue is about compiling user projects, not CMake itself. Potentially we need to add a try_compile() to CMake’s own CMakeLists.txt files to handle detection of whether to link libatomic or not.