MAC 下用GCC编译报错:“Undefined symbols for architecture x86_64: ”

解决方法:

因为GCC编译的时候没有链接C++ standard library, 因此在编译的时候要加入符号 -lstdc++

使用命令:

 gcc myprog.c -o myprog -lstdc++

原文地址:https://www.cnblogs.com/bubbler/p/4911685.html