Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如果标志在没有 makefile 的情况下可用,我可以强制 g++ 编译器使用来自 x.cpp 的特定标志吗?
我想要那个g++ x.cpp并且g++ -std=c++0x x.cpp有相同的结果
g++ x.cpp
g++ -std=c++0x x.cpp
有点。
你不能在里面设置flags x.cpp,但是你可以设置pragma。
x.cpp
这是来自 gcc 在线文档的可用编译指示列表。