What files belong to a build target in CDT managed build?

不羁的心 提交于 2019-12-20 03:13:02

问题


In CDT's managed builder, how are individual files assigned to build configurations?

Specifically, how can I:

  • indicate that configuration A has to build and link sources from folders A and B, while configuraion B shall use folders A and C,
  • include sources (not headers) from a referenced project (or just any external source files?) to be also built and linked as a part of a given project?

回答1:


  • 1st point, assuming there are 3 folders A,B & C containing .cpp files, try this :
    select folder C in the 'project explorer' pane, right-click > exclude from build... > check configuration A > ok
    select folder B, right-click > exclude from build... > check configuration B > ok
    This way configuration A will ignore .cpp files from folder C and configuration B will ignore folder B.
  • 2nd point : maybe you could use import > general > file system to import source from an external folder into your project ?


来源:https://stackoverflow.com/questions/4401201/what-files-belong-to-a-build-target-in-cdt-managed-build

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