Forked from
CMake / CMake
21407 commits behind, 1 commit ahead of the upstream repository.
Dimitri John Ledkov
authored
RISCV64 port on Linux requires -latomic to be linked, as some funcationality required by C/C++ may not be available in hardware, requiring a runtime implementation. Although, some compilers try to add -latomic, it may or may not work under CMake and --as-needed linking. This is similar to how some Android toolchain files specify -latomic as well. Tested on Ubuntu, with this patch fixes failure to build from source of rocksdb, mariadb-10.3, opendht and probably other projects on RISCV64 without modifying their CMake configuration. Fixes: #20895