Linux C++ programs build with GCC link against libgcc_s.so.1
and libstdc++.so.6
libraries, each of which contains multiple ABIs: newer versions contain ABIs from previous version plus new ones. GCC ABI policy document says programs build against older runtime should be able to be run with the new runtime. So, theoretically, older binaries should be runnable on new systems.
If I have a system with an older runtime and don't want to go through the trouble of upgrading GCC on this system, can I manually replace the above mentioned libraries with new ones? In theory all old executables that link against it should work (including GCC itself), but it feels like a kludge.
Is it safe to do so?