I just suffer a problem that the all the things works well on my ubuntu.
However, I want to get things work on my mac, bad thing happens.
it shows the following errors
cc1plus: error: unrecognized command line option "-std=c++0x"
I am total new to mac stuff, I got the xcode 4 installed.
I guess there must be c++0x, but I wonder how can i configure it with waf.
Thanks a lot!!
I’m guessing you’re using GCC supplied with Xcode. That’d be GCC 4.2.1, a rather old version that won’t be updated by Apple in the foreseeable future.
You have essentially two options:
Xcode ships Clang/LLVM besides GCC, so you could use Clang/LLVM instead. That
-std=c++0xoption is recognised by Clang/LLVM but C++0x is not as fully supported as in recent versions of GCC. The LLVM project keeps a page listing their current C++0x support status.Use a more recent version of GCC. You can either compile it locally or install it via one the open source package managers available on Mac OS X: MacPorts, Fink, Homebrew. I don’t really know if and which versions of GCC they’re able to build, so check with them first.