I left Eclipse to NetBeans for C/C++ development right after release v7 and it all seems a wise choice except that -std=C++11
flag in the current latest release, namely 7.2, is not recognized by gcc 4.6 (-std=C++0x
) or the previous. Since Ubuntu 12.04 ships with gcc 4.6 (which should be fair enough to use for my jobs in term of 11 features) and a fresh installation of gcc 4.7 might bring about complexity in maintenance of the system (well...I'm a person extremely simple, neat and clean), is there any work around?
Asked
Active
Viewed 2,869 times
2

Yang
- 777
- 1
- 10
- 19
1 Answers
7
Using the "C++ standard" option from NetBeans does not work. My solution is to do it manually. Add:
-std=c++0x
To the "Additional Options" in the Project > Settings > Build > C++ Compiler

Szymon Wygnański
- 10,642
- 6
- 31
- 44
-
Also checkout this link: http://mycomputeradventures.blogspot.com/2011/12/support-for-c0x-c11-in-netbeans.html – Szymon Wygnański Aug 13 '12 at 20:45