Qt Creator 100% CPU during code edit

吃可爱长大的小学妹 提交于 2019-12-10 21:41:43

问题


I have Qt Creator project. It uses boost and Point Cloud library. When I edit file that contains includes from these libraries, Qt Creator hangs about 30 seconds after each code channge (line added, variable type changed etc.). TaskManager shows 100% CPU on my two-core procesor.

Please note: it is not during parsing or indexing, i.e. no green progress bar appears.

Qt Creator is 2.8.0.


回答1:


The only way I found is to disable boost and Eigen header parsing. To do it

  1. Exclude them from HEADERS section of .pro file
  2. Add these lines:

    QMAKE_CXXFLAGS += /I ../3rdparty/eigen /I ../3rdparty/boost /DCOMPILE_TIME

    Now Qt Creator will show you Unknow file warning, but compilation will be OK.



来源:https://stackoverflow.com/questions/19078732/qt-creator-100-cpu-during-code-edit

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!