I ve one build which worked fine for monthes.
Now it creates in a project always a 32 bit (x86) executeable instead of any cpu . It is a .net 4.6.1 console application and as a result I get bad images exception when it try to load a assembly which is 64 bit compiled
Core Flags returns:
Version: 4.0.30319
CLR Header: 2.5
Corlags 0x20003 //Should be 0x1 for any cpui, shouldn’t it?
ILONLY: 1
32 bit req: 0
32 bitpref :1
signed : 0
To day i installed the latest updates ( including the .net security update) not sure wether this is realted to it.
the project definition says for all build types any cpu
the project thjen deploys with octodeploy. but this worked for monthes without problem
How can I define the build type in the msbuild action ? I attacedh you some screen shots in the screens.zip showing the build steps
__37319__0__screens.zip (40.579 KB)
I Also tried to add
Platform=“Any CPU”
to the properties tab but still same problem…
the log output for this project is:
Working Directory: D:\Continua\Agent\Ws\38112\Source\Web\src\SR.BusPortal.WebApi\SR.BusPortal.Worker
Executable: C:\Program Files (x86)\MSBuild\14.0\bin\amd64\MSBuild.exe
Arguments: /nologo /verbosity:normal “build” RunCodeAnalysis=false Platform=“Any CPU” outputpath=“D:\Continua\Agent\Ws\38112\Output” configuration=“Production” /noconsolelogger /nodeReuse:False /logger
one more thing i checked old verisons which were build they all have
32BITPREF : 0
Hi Haggy
It’s unlikely that a security update would have broken this, but then I have seen stranger things.
What are you setting the BuildMode variable to? This is used to specify your configuration. I notice you are building the csproj file rather than the sln, in this case you probably need to set the MSBuild property (on the properties tab of the msbuild action) :
Platform=“Any CPU”
When you build a solution, this is often part of the configuration name, or msbuild gets it from the solution configuration, when you build a csproj file you need to set it yourself.
Hi Vincent .
I tried both.
The buildmode is one that is set tu anycpu and the prefer 32 bit option off. I checked this via the vs ui and in the csproj. file it self.
When I locally build the project with this mode
bin\Production</OutputPath>
TRACE;CODE_ANALYSIS;PRODUCTION
true
3016
pdbonly
AnyCPU
true
prompt
…\SD_RuleSet.ruleset
false
value of the Buildmode Property is “Production”
here a more detailed log.
Working Directory: D:\Continua\Agent\Ws\38178\Source\Web\src\SR.BusPortal.WebApi\SR.BusPortal.Worker
Executable: C:\Program Files (x86)\MSBuild\14.0\bin\amd64\MSBuild.exe
Arguments: /nologo /verbosity:diagnostic “build” RunCodeAnalysis=false Platform=“Any CPU” outputpath=“D:\Continua\Agent\Ws\38178\Output” configuration=“Production” /noconsolelogger /nodeReuse:False /logger:ParallelLogger,“C:\Program Files\VSoft Technologies\ContinuaCI Agent\Continua.Modules.Builds.MSBuild.v40.dll” D:\Continua\Agent\Ws\38178\Source\Web\src\SR.BusPortal.WebApi\SR.BusPortal.Worker\SR.BusPortal.Worker.csproj
Environment Variables
RunOctoPack: true
OctoPackPublishPackageToHttp: http://srv04.green-parrot.net:8080/nuget/packages
OctoPackPublishApiKey: API-TOY3UMCH6KDA0STBL3OXB0K5RY0
OctoPackPackageVersion: 1.0.0.53
OctoPackEnforceAddingFiles: true
C:\Program Files (x86)\MSBuild\14.0\bin\amd64\MSBuild.exe /noconsolelogger /nologo /logger:ParallelLogger,C:\Program Files\VSoft Technologies\ContinuaCI Agent\Continua.Modules.Builds.MSBuild.v40.dll /nodeReuse:False /P:configuration=Production /target:build /verbosity:diagnostic D:\Continua\Agent\Ws\38178\Source\Web\src\SR.BusPortal.WebApi\SR.BusPortal.Worker\SR.BusPortal.Worker.csproj
Build started 13.04.2016 21:26:46.
Overriding target “GetFrameworkPaths” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “GetFrameworkPaths” from project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.NetFramework.CurrentVersion.targets”.
Overriding target “SatelliteDllsProjectOutputGroup” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “SatelliteDllsProjectOutputGroup” from project “C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.WinFx.targets”.
The target “BeforeGenerateProjectPriFile” listed in a BeforeTargets attribute at “C:\Program Files (x86)\MSBuild\Microsoft\NuGet\Microsoft.NuGet.targets (186,61)” does not exist in the project, and will be ignored.
Project “D:\Continua\Agent\Ws\38178\Source\Web\src\SR.BusPortal.WebApi\SR.BusPortal.Worker\SR.BusPortal.Worker.csproj” on node 1 (build target(s)).
Overriding target “GetFrameworkPaths” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “GetFrameworkPaths” from project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.NetFramework.CurrentVersion.targets”.
Overriding target “SatelliteDllsProjectOutputGroup” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “SatelliteDllsProjectOutputGroup” from project “C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.WinFx.targets”.
The target “BeforeGenerateProjectPriFile” listed in a BeforeTargets attribute at “C:\Program Files (x86)\MSBuild\Microsoft\NuGet\Microsoft.NuGet.targets (186,61)” does not exist in the project, and will be ignored.
Overriding target “GetFrameworkPaths” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “GetFrameworkPaths” from project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.NetFramework.CurrentVersion.targets”.
Overriding target “SatelliteDllsProjectOutputGroup” in project “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\Microsoft.Common.CurrentVersion.targets” with target “SatelliteDllsProjectOutputGroup” from project “C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.WinFx.targets”.
The target “BeforeGenerateProjectPriFile” listed in a BeforeTargets attribute at “C:\Program Files (x86)\MSBuild\Microsoft\NuGet\Microsoft.NuGet.targets (186,61)” does not exist in the project, and will be ignored.
Deferred Messages
Hi Haggy,
Set the Platform property as Platform=AnyCPU instead of Platform=“Any CPU” .
This should solve your problem. The odd thing however, is that we get the correct output in our tests with your project PropertyGroup settings and without the Platform property set in the action at all.
Can you send the full .csproj project file to support@finalbuilder and also let us know the MDBuild version number, e.g. “C:\Program Files (x86)\MSBuild\14.0\bin\amd64\MSBuild.exe” /version, so we can investigate further?
I sent you the project file
The resolved version of
“C:\Program Files (x86)\MSBuild\14.0\bin\amd64\MSBuild.exe” /version
Was: 14.0.25123.0
I tried now building with that any cpu setting and still some problem it is marked as prefer 32 bit