使用 CruiseControl.NET 指定目标平台
我正在设置我的第一个自动构建服务器...到目前为止,一切都进展顺利,CruiseControl.NET 正确地从 VisualSVN 中检查了所有必需文件并构建了解决方案...但是,这就是我的地方遇到问题...
首先设置构建服务器的一个重要原因是我需要使用我的项目/设置文件来定位 x86 和 x64。我无法找到执行此操作的方法。这是我到目前为止的配置文件(相关位):
<tasks>
<devenv>
<solutionfile>ProjectName.sln</solutionfile>
<configuration>Release</configuration>
<buildtype>Rebuild</buildtype>
<project>ProjectName</project>
<executable>C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.com</executable>
<buildTimeoutSeconds>600</buildTimeoutSeconds>
<version>VS2010</version>
</devenv>
</tasks>
它工作正常,但是我希望 CruiseControl.NET 构建它两次,一次针对目标平台 x86,一次针对 x64。我怎样才能做到这一点?
我怀疑我需要在配置块中添加一个附加参数,但是似乎没有任何效果,而且我(奇怪的是)无法找到具有此功能的示例...
感谢您的帮助...
I am in a proccess of setting up my very first automated build server ... Everything has went quite smoothly so far, CruiseControl.NET correctly checks out all the nececery files from VisualSVN and builds the solution ... However, this is where I encounter a problem...
A big reason for setting up a build server in the first place is because I need to target both, x86 and x64 with my projects/setup files. I am unable to find the way to do this. This is my configuration file so far (the relevant bit):
<tasks>
<devenv>
<solutionfile>ProjectName.sln</solutionfile>
<configuration>Release</configuration>
<buildtype>Rebuild</buildtype>
<project>ProjectName</project>
<executable>C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.com</executable>
<buildTimeoutSeconds>600</buildTimeoutSeconds>
<version>VS2010</version>
</devenv>
</tasks>
This works correctly, however I want CruiseControl.NET to build it two times, once for target platform x86 and once for x64. How can I do that?
I suspect I need to add an additional parameter in configuration block, however nothing seems to work and I was (oddly enough) unable to find an example with this feature...
Thanks for your help...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以尝试使用 msbuild 任务,它应该允许您做您想做的事情...只需向其传递适当的参数即可。首先,您必须在项目文件中设置配置,如此处。然后,您可以添加几个 msbuild 目标(每个要构建的配置一个),这与此类似:
我想您也许可以使用 devenv 执行类似的操作,但我不确定。
You could try using the msbuild task instead, which should allow you to do what you want to do... just pass in the appropriate parameters to it. First you will have to set up the configurations in you project file, as outlined here. Then you can add several msbuild targets (one for each configuration you want to build) , which will be similar to this one:
I suppose you might be able to do something similar using devenv, but I'm not sure.
请在此处查看答案:如何指定devenv 中的平台构建 CruiseControl.net
See an answer here: How to specify the platform in devenv build CruiseControl.net