我想以一致的方式为我的解决方案中的所有项目定义包含、链接和二进制输出的路径。
解决方案文件夹和项目已经创建。是否有一种自动化的方式来设置相关输出目录并同时包含所有项目的目录,或者最好是在解决方案级别?
比如我现在的目录结构是这样的。
repository (solution)
├─ README.md
├─ dependencies (solution folder)
│ └─ name (several projects)
│ ├─ *.h, *.cpp
│ └─ binary (*.dll or *.lib)
│ ├─ debug
│ └─ release
├─ managers (solution folder)
│ └─ name (several projects)
│ ├─ *.h, *.cpp
│ └─ binary (*.dll or *.lib)
│ ├─ debug
│ └─ release
├─ system (project)
│ ├─ *.h, *.cpp
│ └─ binary (*.dll or *.lib)
│ ├─ debug
│ └─ release
├─ modules (solution folder)
│ └─ name (several projects)
│ ├─ *.h, *.cpp
│ ├─ binary
│ │ ├─ debug
│ │ └─ release
│ └─ *.jpg, *.3ds, ... (assets)
└─ application (project)
├─ *.cpp
└─ binary (*.exe)
├─ debug
└─ release
最佳答案
您要找的是属性(property)经理。
参见 GUI to include a .prop file in a VS 2010 project?了解如何联系属性(property)经理。
您可以创建自己的属性集并将其包含在所有项目中。一旦您更改了“全局属性集”中的某些内容,所有项目都将更改。
编辑: 关于属性(property)经理如何工作的另一个链接:http://msdn.microsoft.com/en-us/library/ms173410%28v=vs.90%29.aspx
关于c++ - 为 Visual Studio 解决方案中的所有项目设置目录结构?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20053855/