简体   繁体   English

在Clion中更改默认的cmakelists.txt

[英]Changing default cmakelists.txt in clion

If i want for example to add extra flags, or to change to the c compiler. 如果我想例如添加额外的标志,或更改为C编译器。 Is it even possible? 可能吗? Thanks in advance 提前致谢

You can change almost all parameters of project in CLion. 您可以在CLion中更改项目的几乎所有参数。 For example, to change c++ compiler you write: 例如,要更改c ++编译器,请编写:

set(CMAKE_CXX_COMPILER *path_to_your_compiler*)

You can find all required information in cmake documentation or just by properly googling what exactly you want. 您可以在cmake文档中找到所有必需的信息,也可以通过适当地完全搜索所需的内容来找到它们。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM