使用eclipse编译含有C++11特性的代码
2014-05-23 00:00
861 查看
up vote 95down vote accepted
[b]I foundthis article in the Eclipse forum, just followed those steps and it works for me. I am using Eclipse Indigo 20110615-0604 on Windows with a Cygwin setup.[/b]
Make a new C++ project Default options for everythingOnce created, right-click the project and go to "Properties"C/C++ Build -> Settings -> Tool Settings -> GCC C++ Compiler -> Miscellaneous -> Other Flags. Put -std=c++0x at the end . ... instead of GCC C++ Compiler I have also Cygwin compilerC/C++ General -> Paths and Symbols -> Symbols -> GNU C++. Click "Add..." and paste __GXX_EXPERIMENTAL_CXX0X__ (ensure to append and prepend two underscores) into "Name" and leave "Value" blank.Hit Apply, do whatever it asks you to do, then hit OK.
[b]There is a description of this in the Eclipse FAQ now as well:Eclipse FAQ/C++11 Features.[/b]
使用eclipse编译含有C++11特性的代码,总是出错。最后在stackoverflow找到了解决方法。
1. 右击项目,选择Properties。
2. C/C++ Build --> Settings --> Tool Settings --> GCC C++ Compiler --> Miscellanous。在右边的Other Flags中把 "-std=c++0x" 引号中的内容放到已有内容的后面。
2.C/C++ General -> Paths and Symbols -> Symbols -> GNU C++。点击Add,name栏复制__GXX_EXPERIMENTAL_CXX0X__,value为空。
3. OK。
原帖地址:http://stackoverflow.com/questions/9131763/eclipse-cdt-c11-c0x-support
[b]I foundthis article in the Eclipse forum, just followed those steps and it works for me. I am using Eclipse Indigo 20110615-0604 on Windows with a Cygwin setup.[/b]
Make a new C++ project Default options for everythingOnce created, right-click the project and go to "Properties"C/C++ Build -> Settings -> Tool Settings -> GCC C++ Compiler -> Miscellaneous -> Other Flags. Put -std=c++0x at the end . ... instead of GCC C++ Compiler I have also Cygwin compilerC/C++ General -> Paths and Symbols -> Symbols -> GNU C++. Click "Add..." and paste __GXX_EXPERIMENTAL_CXX0X__ (ensure to append and prepend two underscores) into "Name" and leave "Value" blank.Hit Apply, do whatever it asks you to do, then hit OK.
[b]There is a description of this in the Eclipse FAQ now as well:Eclipse FAQ/C++11 Features.[/b]
使用eclipse编译含有C++11特性的代码,总是出错。最后在stackoverflow找到了解决方法。
1. 右击项目,选择Properties。
2. C/C++ Build --> Settings --> Tool Settings --> GCC C++ Compiler --> Miscellanous。在右边的Other Flags中把 "-std=c++0x" 引号中的内容放到已有内容的后面。
2.C/C++ General -> Paths and Symbols -> Symbols -> GNU C++。点击Add,name栏复制__GXX_EXPERIMENTAL_CXX0X__,value为空。
3. OK。
原帖地址:http://stackoverflow.com/questions/9131763/eclipse-cdt-c11-c0x-support
相关文章推荐
- 使用eclipse编译含有C++11特性的代码
- 使用eclipse编译含有C++11特性的代码
- 使用eclipse编译含有C++11特性的代码
- 编译使用了C++11特性的代码
- Eclipse中使用NDK自动编译C++代码
- 【Eclipse】2、使用eclipse软件编译并执行代码
- 从事UNIX/LInux服务器编程最方便的代码编译工具------(eclipse for c/c++)、(FileZilla)、(Secure CRT) 这三种一定要一起使用 之3
- C++11新特性(五)看看外国佬写的代码move的使用
- Linux下使用Eclipse编译C/C++代码时遇到问题的说明
- 使用Eclipse 编译含有多个main函数的项目
- 跟Google学写代码--Chromium工程中禁止使用的C++11特性
- 从事UNIX/LInux服务器编程最方便的代码编译工具------(eclipse for c/c++)、(FileZilla)、(Secure CRT) 这三种一定要一起使用 之1
- 从事UNIX/LInux服务器编程最方便的代码编译工具------(eclipse for c/c++)、(FileZilla)、(Secure CRT) 这三种一定要一起使用 之4
- 从事UNIX/LInux服务器编程最方便的代码编译工具------(eclipse for c/c++)、(FileZilla)、(Secure CRT) 这三种一定要一起使用 之2
- 跟Google学写代码--Chromium工程中禁止使用的C++11特性
- eclipse使用tomcat进行部署时编译代码不一致的处理
- 使用eclipse编译jni代码遇到的问题记录
- 使用 Eclipse 平台共享代码
- 如何在Eclipse中使用ibatis的自动代码生成工具Abator