VS2010 Build Fail with error: Cannot open 'PathToFile.rsp' - visual-studio-2010

I'm having a problem when trying to build my project and i don't know where to look.
The problem is that the build fails every time. it gives me the following error
Error messages on build
When I searched for those files I found that they weren't in that folder
The strangest thing is that if i build the same project on the visual studio, or if I run MSBuild from Visual Studio 2010 command line the project builds without problem. Also, I have configured another builder in another computer, and when I run the build there with the same Build definition it builds correctly. My guess is that it have to be some configuration that i'm missing, but I don't know where to look.
The computer is running Windows Server 2012

Related

Team Foundation Server build failure

I have following tools installed on my machine:
TFS 2017
Visual Studio 2017
MSBuild 14.0
In my application, I'm using some C#6 elements like string interpolation ($).
When I try to build it, controller says that it could not resolve the symbol.
Builds fail for both XAML and standard definitions.
In build logs, there's an information that it uses correct MSBuild 14.0 path: C:\Program Files (x86)\MSBuild\14.0\bin, but still failes to resolve C#6 elements.
I would really appreciate if you would help me with this problem, I've searched entire internet and found nothing :/
If you guys need any information, I'll be more than happy to provide it. Thank you.
TFS with XAML build is just using MSBuild to run the build. You could first try to use MSBuild command to run the build test locally, which will narrow down the issue.
If it works well on your dev machine and not works from a TFS server build. Very likely the environment problem.
To make sure the build successful, you should keep your build server environment the same with your local environment. Please double check this.
For trouble shooting, you could try to remote to your build agent, manually run your build and test on your build agent.
As for how to enable C#6, you could also refer this similar question, modify TFSBuildServiceHost.exe.config file which may do the trick. How do I enable C# 7 builds in Team Foundation Server 2015?
If you still get error, please include detail build failed logs here.

How to get output in team build in TFS

I started learning TFS Team build. I am having a basic doubt. I referred this
article. I followed the steps exactly and got succeeded. I created a Console Application and pushed in TFS using TeamServices. My doubt is when we build a Console application in visual studio we will get an exe in bin folder.
Same way in this team build how to get the output in my local machine ?
What is the difference between the local build using Visual studio and this team build ?
EDIT :
I added like this. Still I am not able to see the output in the RELEASE folder.
I got the result as success saying
Still I couldn't figure out the output - the exe produced as a result of build.
Am I doing anything wrong ?
Note : I have a requirement like what you explained in the answer. So why I am using TFS team build. Since I am new I am experimenting with a small example.
When to use a build system
Team Build does not replace Visual Studio build. Use Team Build when you have a complex / lengthy build, to easily integrate running unit tests as part of the build or to deploy assemblies to a server after the build is complete.
Most people will setup a TFS build definition to run as "Continous Integration" build, meaning that whenever a commit is checked in, a build occurs. The build would compile and run tests and if it fails all developers can be notified.
How to get to the build output
When using a build system like TFS build, the build is done on a remote machine. If you want to retrieve the output of the build, add a Publish Build Artifacts step to your build definition. Since the build happened on a remote machine, the remote machine does not have access to your local developer machine.
The artifacts (assemblies) will be available for download on the build summary page:

Visual Studio 2013 and TFS Build 2015: Devenv.exe unable to produce MSI file

We are in the process of upgrading our TFS 2013 server to TFS 2015. In that regard I have run into an issue when trying to perform an application build on a build agent with the new version, using our XAML template build script (which was created in TFS 2013).
Most of our solutions use the above-mentioned template when we build them. The solutions (sadly, still) use setup projects (.vdproj) to generate an MSI package for the application. To build the setup project, and produce an MSI, for a given application; we call the devenv.exe (in our case, it points to Visual Studio 2013) in our template build script:
C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe /Build "Release|Any CPU" "d:\<path_to_solution>\solution.sln" /Out c:\temp\out.log
However, on our new build agent no MSI is produced, and calling devenv.exe yields neither any output, nor any error messages. If I try to call devenv.com, however, it starts building, but still no MSI is being produced.
When things start to build using devenv.com It seems like it is completely disregarding the setup project (I have checked the build configurations, and the setup project is checked for build on the "Release|Any CPU" configuration).
I have looked at build logs, build process activity logs, and I have also tried to perform the steps manually on the build agent, but I haven't been able to find anything that could point me in the direction as to what might be causing the issue.
Does anyone have an idea what could be the reason for this? Could it be an issue with TFS Build 2015? The only difference between the old setup, and the new - as far as I can tell - is the following:
VS 2013 was installed on C: rather than D: on the new build agent, i.e. the path to devenv would be different, but that should not matter as long as the build script is looking in the right place, and finds it...
We use a different drop location than what we used for the old setup
Appreciate any help and suggestions I can get.
Problem solved, and everything is now building successfully. I did not do a good enough job of looking at the diff between the setup we had on the build agent we used for TFS Build 2013 vs. the one we set up for TFS Build 2015.
Firstly, to be able to build setup projects in VS 2013, one needs to install the Visual Studio 2013 Installer Projects extension on the build agent.
However, there are some bugs with this extension that often causes building setup projects to yield the following error message: "An error occurred while validating. HRESULT = '8000000A'". This error can be fixed by modifying the registry, as described in this SO post.
Building the setup projects using devenv.exe, however, still doesn't work. I have not been able to figure out why, yet.
Use the Vnext build in TFS 2015 to build .vdproj. You just need to add one additional build step i.e "command line" then call devenv.com to build.
Such that,
tool :
C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.com
arguments :
HelloWorldTestInstaller\HelloWorldTestInstaller.vdproj /build release
This will help you.

Error MSB4025: The project file could not be loaded. Could not find file (project file name).metaproj

We have just upgraded a build server to TFS 2013, and Visual Studio 2013, and are running into problems. We have a MSBuild (.proj) file that triggers the generation of a solution (.sln) file using CMake, and then a sub-MSBuild step that builds this solution. The CMake part finishes without issues, but when MSBuild tries to build it, we get the following error from all the projects in the solution:
Error MSB4025: The project file could not be loaded. Could not find file (project file name).metaproj
The metaproj files are not present next to the projects, but as I understand it, these files are never stored to disk but kept in memory instead. The exact same sources still build fine on our 2012 build server, as well as locally using Visual Studio 2013. The only changes we have done are to generate 2013 solutions, and set the ToolVersion to 12.0 for the "bootstrap" MSbuild file.
I was using the old DefaultTemplate.11.1.xaml build process template for building the project on the build server. I gave up on trying to make it work with that template, and converted to the new TfVcTemplate.12.xaml instead, and that solved the issue.
I still don't know what caused the original issue, but determined that it was not caused by CMake, as it could be replicated without CMake in the equation.

Problem building a Setup project

I'm working on a tool to simplify an application's deployment. Hence I'm aiming to automate the build of the setup project.
The Situation:
When I use Visual Studio to build the setup project this, creates the msi and exe files and concludes successfully. The problem occurs when I run a command in the command prompt, I keep getting this error "ERROR: Cannot find outputs of project output group '(unable to determine name)'"
The command for the command prompt is:
C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE>devenv "C:\Project's Directory\Project.Setup.vdproj" /Build
Can anyone help me with it.
I'm really stuck.
EDIT: The solution to my problem was to create a solution which contains the setup project and the project which is actually the output project of the setup project.
C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE>devenv "C:\Project's Directory\Project.Setup.sln" /Build
Thanks to everyone.
You can't do this.
The issue is that you have defined your inputs to the setup project as outputs from the other projects in the solution. You have to build the entire solution to use this method.
You can do this but you have to manually link all the files you want into your setup project. It is a bit more tricky but just as doable.
I suspect that you have a setup project that is referencing the output of another project. in this case you need to use
devenv [solutionname] /build
the reason you are getting the error is because visual studio has not compiled the referenced project.
side note: if you are trying to automate a build in vs 2005 or later I would investigate wix as it is easier to automate using msbuild.

Resources