3

我仍在尝试消除其中包含 cobol-Projects 的项目中对 cobol 编译器的需求。

是否可以创建以下构建行为:

如果配置为 Debug,则在 ExCobol.cblproj 上使用 ProjectReferences 如果配置为 DebugVB,则在 ExCobol.dll 上使用 FileReferences

什么时候是,如何实现?

我假设在项目文件中使用标签就可以了。

这真的消除了对 DebugVB 配置的 cobol 编译器的需要吗?

4

2 回答 2

5

关于条件“如何”,假设您有

<ProjectReference ...>...</ProjectReference>

或者

<Reference ...>...</Reference>

您想手动编辑 .proj 文件以包含两者

<ProjectReference Condition="'$(Configuration)'!='DebugVB'" ...>...</ProjectReference>
<Reference Condition="'$(Configuration)'=='DebugVB'" ...>...</Reference>
于 2009-12-09T09:40:47.483 回答
0

差点忘了这个问题:Brian 的回答对我来说非常有效。

并回答问题的第二部分:

如果您设置不同的配置,它确实消除了对每个机器上的 cobol 编译器的需要。

谢谢布赖恩。

于 2010-01-06T07:14:30.470 回答