views:

18

answers:

1

Hello

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...

+1  A: 

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:

<msbuild>
    <executable>C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe</executable>
    <workingDirectory>C:\svn\TRUNK\Project</workingDirectory>
    <projectFile>Solution.sln</projectFile>
    <buildArgs>/noconsolelogger /t:Rebuild /p:Configuration=Release</buildArgs>
    <timeout>900</timeout>
    <logger>C:\Program Files (x86)\CruiseControl.NET\server\ThoughtWorks.CruiseControl.MsBuild.dll</logger>
  </msbuild>

I suppose you might be able to do something similar using devenv, but I'm not sure.

TskTsk
Two devenv tasks is also permitted within the tasks block
Pedro