https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96657
--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jonathan Wakely <r...@gcc.gnu.org>: https://gcc.gnu.org/g:6c0c7fc6236470a533675cd3cd1ebb1cc3dd112c commit r11-8198-g6c0c7fc6236470a533675cd3cd1ebb1cc3dd112c Author: Jonathan Wakely <jwak...@redhat.com> Date: Wed Apr 14 20:48:54 2021 +0100 libstdc++: Move atomic functions to libsupc++ [PR 96657] The changes for PR libstdc++/64735 mean that libsupc++ function might now depend on the __exchange_and_add and __atomic_add functions defined in config/cpu/*/atomicity.h which is not compiled into libsupc++. This causes a link failure for some targets when trying to use libsupc++ without the rest of libstdc++. This patch simply moves the definitions of those functions into libsupc++ so that they are available there. libstdc++-v3/ChangeLog: PR libstdc++/96657 * libsupc++/Makefile.am: Add atomicity.cc here. * src/c++98/Makefile.am: Remove it from here. * libsupc++/Makefile.in: Regenerate. * src/c++98/Makefile.in: Regenerate. * testsuite/18_support/exception_ptr/96657.cc: New test.