The problem is that you're compiling C++ code and not C. C++ needs a runtime support library, the native GCC library is called libstdc++ and you need to link with that.
It's very easy to do: Use the g++
(arm-linux-gnueabihf-g++
in your case) frontend program to link as well as compile., it will automatically add the C++ runtime library. Or add it manually to your linker command.