FWIW, We build for both VS 2008 and VS 2010. I have taken the contents of the 
vcvarsall.bat file and made it a Properties file on the master. Then I use 
"Prepare an environment for the run" and set the "Properties File Path" to 
$JENKINS_HOME\usercontent\vs2010env.properties and click "load script and 
properties file form the master" and the environment is all setup for using the 
MSBuild build step.

From: jenkinsci-users@googlegroups.com 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of Mark Waite
Sent: Wednesday, September 04, 2013 9:45 PM
To: jenkinsci-users@googlegroups.com
Subject: Re: Help needed with MsBuild plugin

Isn't the message "error TRK0005: Failed to locate: "CL.exe". The system cannot 
find the file specified. " an indication that you may have failed to call 
vcvarsall.bat for your specific Visual Studio before starting the Jenkins slave 
agent on that machine?

I thought that Visual Studio used that technique to allow users to install 
multiple Visual Studio versions on a single machine, and then select which 
Visual Studio they want to use for a command line compile by invoking the 
corresponding vcvarsall.bat script for that Visual Studio version.

I don't think the MSBuild plugin is the right one to decide which Visual Studio 
version you want to run, though I guess it could be extended to have some form 
of list of alternative Visual Studio versions which it should attempt to 
configure before running the build.

Mark Waite

________________________________
From: "dhrutiben.pa...@wellsfargo.com<mailto:dhrutiben.pa...@wellsfargo.com>" 
<dhrutiben.pa...@wellsfargo.com<mailto:dhrutiben.pa...@wellsfargo.com>>
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Sent: Wednesday, September 4, 2013 9:42 AM
Subject: RE: Help needed with MsBuild plugin

I set MSBuild.exe at configure system location and for my jobs , I just use the 
command 'Execute Batch Command" and write my query.
It works for me so far.


From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of David Aldrich
Sent: Wednesday, September 04, 2013 8:23 AM
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

Do you use the MSBuild plugin or just specify a 'Windows batch command' build 
step?

Does your path variable on your slave include:

C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN;

?

From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of 
dhrutiben.pa...@wellsfargo.com<mailto:dhrutiben.pa...@wellsfargo.com>
Sent: 04 September 2013 16:14
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

Sorry David, but it is hard to understand your problem.

I am giving my code snippet so you can compare and check the difference.

Jenkins Job:

Execute windows batch command
                C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe 
/t:Rebuild /p:Configuration=%BuildType% /p:Platform="%BuildPlatform%" 
/verbosity:normal  %workspace%MyProj.sln


And check whether you have set up environment variables on your build server. 
E.g. C:\winodws\system32


From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of David Aldrich
Sent: Wednesday, September 04, 2013 8:07 AM
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

I think there is not much to say.

The master configuration sets the MSBuild path to:

C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe

The build step is:

MS Build file: MSVC\MyProj.sln
Command line arguments: /p:Configuration=" release" /p:useenv=true 
/flp:logfile=MyOutput.log;verbosity=diagnostic

David

From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of 
dhrutiben.pa...@wellsfargo.com<mailto:dhrutiben.pa...@wellsfargo.com>
Sent: 04 September 2013 15:54
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

Can you provide configuration settings for your job , if possible?
And what are the steps you are adding for MSBuild?

From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of David Aldrich
Sent: Wednesday, September 04, 2013 7:49 AM
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

Hi

Thanks for your reply.

Yes, I had already done that.

David


From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of 
dhrutiben.pa...@wellsfargo.com<mailto:dhrutiben.pa...@wellsfargo.com>
Sent: 04 September 2013 15:41
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: RE: Help needed with MsBuild plugin

Hi,

Did you set up MSBuild configuration globally?

I mean, go to Manage Jenkins--> Configure System , you need to add which 
version of MSBuild you going to use.

Try above and let us know whether it solved your problem or not.

From: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com> 
[mailto:jenkinsci-users@googlegroups.com] On Behalf Of David Aldrich
Sent: Wednesday, September 04, 2013 4:28 AM
To: jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>
Subject: Help needed with MsBuild plugin

Hi

I have used Jenkins for a long time but am now using the MSBuild plugin for the 
first time, because we are migrating some build jobs from VC2008 to VC2010.

I have added a 'MSBuild installation' in Jenkins with the following path:

C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe

In my job, I specify the following MSBuild command line arguments:

p:Configuration="My_release" /p:useenv=true 
/flp:logfile=MyOutput.log;verbosity=diagnostic

When I run the job I get this error:

error TRK0005: Failed to locate: "CL.exe". The system cannot find the file 
specified.

Visual C++ 2010 is installed on the build machine and CL.exe is definitely 
present.

I guess that MSBuild would typically be executed from a Visual Studio command 
prompt which would have the environment variables correctly set up.

Do I need to configure the path when running the MSBuild plugin from Jenkins?

Best regards

David

--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.

Click 
here<https://www.mailcontrol.com/sr/szJBvIn6!BrGX2PQPOmvUv46NwAC7+vkNuaJfGCF!6bqywAqgIaj3FrSOpIPaCACXdIc+sLA36AX!sYT9IPN0A==>
 to report this email as spam.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to