I am attempting to build my AX7 Solution using MSBuild. I am using Jenkins to build it.
I am using the MSBuild.exe from "C:\Windows\Microsoft.NET\Framework\v4.0.30319".
I am using the following command line arguments: /t:Build /p:Configuration="Release" /v:n
I am getting the following errors (In a Solution that builds normally in Visual Studio). Any ideas? Are there any command line arguments or environment variables I need to set? Am I using the wrong MSBuild? Should I be using the Framework64 version?
13:38:49 Building solution configuration "Release|Any CPU".
13:38:49 Project "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\PrecisionForms.AX7.sln" (1) is building "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationSuite.BT_DPA\ApplicationSuite.BT_DPA.rnrproj.metaproj" (2) on node 1 (default targets).
13:38:49 Project "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationSuite.BT_DPA\ApplicationSuite.BT_DPA.rnrproj.metaproj" (2) is building "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationFoundation.BT_DPA\ApplicationFoundation.BT_DPA.rnrproj" (3) on node 1 (default targets).
13:38:49 Project file contains ToolsVersion="12.0". This toolset may be unknown or missing, in which case you may be able to resolve this by installing the appropriate version of MSBuild, or the build may have been forced to a particular ToolsVersion for policy reasons. Treating the project as if it had ToolsVersion="4.0". For more information, please see http://go.microsoft.com/fwlink/?LinkId=291333.
13:38:49 PrepareForBuild:
13:38:49 Creating directory "Bin\".
13:38:49 Creating directory "obj\Debug\".
13:38:49 C:\Program Files (x86)\MSBuild\Microsoft\Dynamics\AX\Microsoft.Dynamics.Framework.Tools.BuildTasks.targets(55,5): error MSB4062: The "CopyReferencesTask" task could not be loaded from the assembly Microsoft.Dynamics.Framework.Tools.BuildTasks, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35. Could not load file or assembly 'Microsoft.Dynamics.Framework.Tools.BuildTasks, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask. [C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationFoundation.BT_DPA\ApplicationFoundation.BT_DPA.rnrproj] 13:38:49 Done Building Project "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationFoundation.BT_DPA\ApplicationFoundation.BT_DPA.rnrproj" (default targets) -- FAILED.
13:38:49 Done Building Project "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\ApplicationSuite.BT_DPA\ApplicationSuite.BT_DPA.rnrproj.metaproj" (default targets) -- FAILED.
13:38:49 Done Building Project "C:\Program Files (x86)\Jenkins\workspace\AX Connector for New Dynamics AX\Projects\UpgradedSolution\PrecisionForms.AX7.sln" (Build target(s)) -- FAILED.
13:38:49
13:38:49 Build FAILED.