I am working on Installshield and TFS (VSTS 2008) and now I want to build Installshield 2011 Project along with build definition.
For this I have created build.proj file which contains build definitions to build .sln projects which is working fine.
Now at end of Build definition file I have added like this :
<Target Name="AfterCompile">
I have added the reference of Installshield project, so that after building Visual Studio projects start building Installshield projects at the end:
<Exec Command=""$(DevEnvDir)\Common7\IDE\devenv" E:\Sw\Manual_Build_TFS_R3\Setup.isproj /Build"/>
Earlier I have used VSINSTALLDIR in palce of DevEnvDir still error will come which says
Task "Exec"
Command:
"\Common7\IDE\devenv" E:\Sw\Manual_Build_TFS_R3\Setup.isproj /Build
The system cannot find the path specified.
E:\BuildSource\Temp\BuildType\TFSBuild.proj(444,5): error MSB3073: The command ""\Common7\IDE\devenv" E:\Sw\Manual_Build_TFS_R3\Setup.isproj /Build" exited with code 3.
Done executing task "Exec" -- FAILED.
Done building target "AfterCompile" in project "TFSBuild.proj" -- FAILED.
Done Building Project "E:\BuildSource\Temp\BuildType\TFSBuild.proj" (EndToEndIteration target(s)) -- FAILED.
Build FAILED.
"E:\BuildSource\Temp\BuildType\TFSBuild.proj" (EndToEndIteration target) (1) ->
(AfterCompile target) ->
E:\BuildSource\Temp\BuildType\TFSBuild.proj(444,5): error MSB3073: The command ""\Common7\IDE\devenv" E:\Sw\Manual_Build_TFS_R3\Setup.isproj /Build" exited with code 3.
0 Warning(s)
1 Error(s)
I am new to this VSTS and TFS build configurations.
We use something like this:
Command=""%programfiles%\Microsoft Visual Studio 8\Common7\IDE\devenv" ..."
Would that work for you?
-- EDIT --
Another thought that came to mind is the suggestion that you consider WIX instead of InstallShield. WIX projects work really well within MSBuild.
I can't think of any valid reason that the path to your InstallShield project should be hard-coded as it appears in your question.
Can you build the *.isproj file from the command line with MSBuild? If so, then you could just add it to your solution and set it up to only build for a new solution configuration that you use in your TFS build.
Related
I am receiving the above error when trying to run my build. I have looked at the other answers to this question and have ensured that the project does build in VS2019, that my solution paths are correct and that I have checked the clean box in my Visual Studio Build Task. I'm at a loss and was hoping that someone will see something I am missing. Here is the error log I receive:
2019-12-05T16:51:51.4631828Z ##[section]Starting: Build solution
CONSurvey
2019-12-05T16:51:51.4635684Z
============================================================================== 2019-12-05T16:51:51.4635853Z Task : Visual Studio build
2019-12-05T16:51:51.4636005Z Description : Build with MSBuild and set
the Visual Studio version property
2019-12-05T16:51:51.4636138Z Version : 1.151.2
2019-12-05T16:51:51.4636254Z Author : Microsoft Corporation
2019-12-05T16:51:51.4636405Z Help : More
Information
2019-12-05T16:51:51.4636579Z
2019-12-05T16:51:53.3057099Z
[command]"E:\tfs-agents\DHSS_VSTS_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.151.2\ps_modules\MSBuildHelpers\vswhere.exe" -version [16.0,17.0) -latest -format json
2019-12-05T16:51:53.6381113Z ##[command]"C:\Program Files
(x86)\Microsoft Visual
Studio\2019\Enterprise\MSBuild\Current\Bin\msbuild.exe"
"E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln" /nologo /nr:false
/t:"Clean" /fl
/flp:"logfile=E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln.log;verbosity=diagnostic"
/dl:CentralLogger,"E:\tfs-agents\DHSS_VSTS_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.151.2\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=99b4b9b2-7001-494c-962a-5d5532ebc121|SolutionDir=E:\tfs-agents\DHSS_VSTS_work\233\s"*ForwardingLogger,"E:\tfs-agents\DHSS_VSTS_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.151.2\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll"
/p:UseWPP_CopyWebApplication=true /p:PipelineDependsOnBuild=false
/p:DeployOnBuild=true;OutDir="E:\tfs-agents\DHSS_VSTS_work\233\a"
/p:platform="any cpu" /p:configuration="release"
/p:VisualStudioVersion="16.0"
/p:_MSDeployUserAgent="VSTS_15c81635-e2c4-41a0-95f6-2d0b2f6cbc4d_build_129_0"
2019-12-05T16:51:53.7934752Z MSBUILD : error MSB1009: Project file
does not exist.
2019-12-05T16:51:53.7973651Z Switch:
E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln
2019-12-05T16:51:53.9286545Z ##[error]Process 'msbuild.exe' exited
with code '1'.
2019-12-05T16:51:53.9661712Z ##[command]"C:\Program Files
(x86)\Microsoft Visual
Studio\2019\Enterprise\MSBuild\Current\Bin\msbuild.exe"
"E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln" /nologo /nr:false
/fl
/flp:"logfile=E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln.log;verbosity=diagnostic"
/dl:CentralLogger,"E:\tfs-agents\DHSS_VSTS_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.151.2\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=1029b97a-fe32-4d73-b976-928576336049|SolutionDir=E:\tfs-agents\DHSS_VSTS_work\233\s"*ForwardingLogger,"E:\tfs-agents\DHSS_VSTS_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.151.2\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll"
/p:UseWPP_CopyWebApplication=true /p:PipelineDependsOnBuild=false
/p:DeployOnBuild=true;OutDir="E:\tfs-agents\DHSS_VSTS_work\233\a"
/p:platform="any cpu" /p:configuration="release"
/p:VisualStudioVersion="16.0"
/p:_MSDeployUserAgent="VSTS_15c81635-e2c4-41a0-95f6-2d0b2f6cbc4d_build_129_0"
2019-12-05T16:51:54.1134908Z MSBUILD : error MSB1009: Project file
does not exist.
2019-12-05T16:51:54.1135166Z Switch:
E:\tfs-agents\DHSS_VSTS_work\233\s\CONSurvey.sln
2019-12-05T16:51:54.1648429Z ##[error]Process 'msbuild.exe' exited
with code '1'.
2019-12-05T16:51:54.2165236Z ##[section]Finishing: Build solution
CONSurvey
Edit: Yes, the solution file is there. It is not missing.
MSBUILD: error MSB1009: Project file does not exist on Azure Devops TFS
The cause of this issue usually comes from two aspects, one is the issue with the build definition settings, and the other is the issue of your project/solution itself.
For the build definition settings, you need to check if you omitted the actual solution file in the Solution text box instead of a solution path. For example,
The following shows just the folder path and this setting produces the error:
This is the correct setting with the solution file to build:
This setting has been a source of confusion due to the heading on the dialog to select the Path and not say select the Path to the Solution file.
For the ssue of your project/solution itself, since we do not have your solution/projects, we could not point directly to the issue. But you could build solution in the local machine without Azure devops, then check if you still have this issue.
Note: If you can build it success in you local machine, make sure you have check all required files to the source control.
Hope this helps.
I am very much new in TFS framework, and now i am creating build from last 3 days, all steps passes but fail # Build Solution with error:
[error]Process 'msbuild.exe' exited with code '1'.fails.png
My versions are:
TFS version: Version 15.105.25910.0
VS version: Microsoft Visual Studio Enterprice 2017 (15.9.4)
Can anyone from community tell me whats going wrong with my build.
Build Error:
2018-12-29T11:48:37.1011337Z ##[section]Starting: Build solution
*.sln 2018-12-29T11:48:43.4372323Z ##[command]"C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe"
"\localhost\ARM-Drop1\1\s\LetsGo1\LetsGo1.sln" /nologo /nr:false
/dl:CentralLogger,"\localhost\ARM-Drop1_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.0.45\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=f568d794-328b-48cf-a753-e603bc019eed|SolutionDir=\localhost\ARM-Drop1\1\s\LetsGo1"ForwardingLogger,"\localhost\ARM-Drop1_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.0.45\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll"
/p:VisualStudioVersion="14.0"
/p:_MSDeployUserAgent="TFS_29388952-19c1-40f9-b321-9389f9ab526b_build_17_287"
2018-12-29T11:48:43.5382020Z MSBUILD : error MSB1021: Cannot create an
instance of the logger. Could not load file or assembly
'file://\localhost\ARM-Drop1_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.0.45\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll'
or one of its dependencies. The system cannot find the file specified.
2018-12-29T11:48:43.5392017Z Switch:
CentralLogger,\localhost\ARM-Drop1_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.0.45\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll;RootDetailId=f568d794-328b-48cf-a753-e603bc019eed|SolutionDir=\localhost\ARM-Drop1\1\s\LetsGo1
2018-12-29T11:48:43.7011531Z **##[error]Process 'msbuild.exe' exited
with code '1'. 2018-12-29T11:48:43.7871273Z ##[section]Finishing:
Build solution **.sln
I have resolved this bug, as I had done lot of changes into the solution file and the build definition in order to resolve the issues but no luck, so the quickest way I have in my mind is to delete the build definition plus uninstall the agent and again reconfigure it with appropriate agent capability and create new build definition and its all work as expected and the build definition got succeeded.
I have a solution containing a web application and multiple database projects. While using the old XAML definition, I can compile and generate the database deployment files in TFS. With the new definition introduced in TFS 2015, I can only generate the web application deployment files.
Here are parts of the log -
2016-10-28T22:14:48.6892904Z Build started 10/28/2016 4:14:48 PM.
2016-10-28T22:14:48.8883071Z 1>Project "E:\TFS\agent\_work\1\s\Test.Client.sln" on node 1 (default targets).
2016-10-28T22:14:48.8893071Z 1>ValidateSolutionConfiguration:
2016-10-28T22:14:48.8903071Z Building solution configuration "release|any cpu".
2016-10-28T22:14:49.0633142Z ##[warning]E:\TFS\agent\_work\1\s\..\Databases\Test\Test.DB.Test.sqlproj.metaproj(0,0): Warning MSB4046: Error reading project file "..\Databases\Test\Test.DB.Test.sqlproj": Could not find a part of the path 'E:\TFS\agent\_work\1\Databases\Test\Test.DB.Test.sqlproj'.
2016-10-28T22:14:49.0643150Z 1>Project "E:\TFS\agent\_work\1\s\Test.Client.sln" (1) is building "E:\TFS\agent\_work\1\s\..\Databases\Test\Test.DB.Test.sqlproj.metaproj" (2) on node 1 (default targets).
2016-10-28T22:14:49.0693159Z 2>E:\TFS\agent\_work\1\s\..\Databases\Test\Test.DB.Test.sqlproj.metaproj : warning MSB4046: Error reading project file "..\Databases\Test\Test.DB.Test.sqlproj": Could not find a part of the path 'E:\TFS\agent\_work\1\Databases\Test\Test.DB.Test.sqlproj'.
2016-10-28T22:14:49.0823182Z 2>Done Building Project "E:\TFS\agent\_work\1\s\..\Databases\Test\Test.DB.Test.sqlproj.metaproj" (default targets).
I could not find much information on the new build definition. Anyone can help?
Thanks
We figured out what is wrong with this. Our database projects are in another folder. We need to map the server path with the local path in the Build's repository. After added this, the database project can be built.
First double check the difference of your two definitions XAML and vNext.
And check the file path E:\TFS\agent\_work\1\s\..\Databases\Test\Test.DB.Test.sqlproj on the build agent, if there are the corresponding file.
And try to build your database project directly instead of building the whole solution to see if there are some useful info for troubleshooting.
Update
Tips:
You can also build MSBuild project (.*proj) files.
If you are building a customized MSBuild project file, we recommend you use the MSBuild step instead of the Visual Studio Build step.
Source Link: Visual Studio Build
I'm trying to do a teambuild for a VS2015 solution with TFS2013.
On the buildserver VS2015 is installed and I changed the buildtemplate so msbuild has an argument \tv:14.0, but when a start a build I get the following error:
C:\Program Files
(x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets (96):
Invalid static method invocation syntax:
"[Microsoft.Build.Utilities.ToolLocationHelper]::GetPlatformSDKDisplayName($(TargetPlatformIdentifier),
$(TargetPlatformVersion))". Method
'Microsoft.Build.Utilities.ToolLocationHelper.GetPlatformSDKDisplayName'
not found. Static method invocation should be of the form:
$([FullTypeName]::Method()), e.g. $([System.IO.Path]::Combine(a,
b)).
The buildserver has been restarted but I still get the error.
I also checked this thread: Build failed in TFS but no real answer was given there. Is there anyone that knows how to solve this.
I was experiencing the exact same error. I determined that TFS2013 was the RTM version so we installed TFS2013 Update 5. Now if I run using the *.12.xaml process template with the /tv:14.0 /p:VisualStudioVersion=14.0 parameters the build succeeds. I have also made a copy of the *.12.xaml build process and named it *.14.xaml and changed the Run MSBuild steps ToolVersion property to "14.0" and this build works as well, without the parameters.
You need to customize the build process template by finding all the Run MSBuild for Project MSBuild activity, then set the ToolVersion to "14.0" and set ToolPath to target to MSBuild14 (by default: "C:\Program Files (x86)\MSBuild\14.0\Bin"). After that, check in the build process template and re-queue the build.
Check the solutions here:TFS 2013 building .NET 4.6 / C# 6.0
I have a build-machine and I have made simple changes recently to run editbin.exe tool with LARGEADDRESSAWARE parameter right after each building. The tool is located in C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin (of course, the path can be another). And I have added new target to the build.proj file:
<Exec command=""$(VSInstallDir)\VC\bin\editbin.exe" /LARGEADDRESSAWARE "Manager.exe""/>
If I run MS Build locally on the build machine it works properly. Good! But after any checkin build is not able to be completed with the following error:
The command ""\VC\bin\editbin.exe"" exited with code 3. As I understand TFS build does not apply the value of $(VSInstallDir) macros (C:\Program Files (x86)\Microsoft Visual Studio 12.0\ in my case). Any suggesting?
To resolve the problem I did the next: In VS build config: Process->Build process parameters->5. Advances->MSBuild arguments added /p:VSInstallDir = Value