• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3998
  • Last Modified:

msbuild v3.5 error - Could not load file or assembly 'Microsoft.Build.Engine'

I have upgrade our Build Server from Msbuild v2.0.50727 to v3.5. On attempting to build any project I get the following error (please see detailed output from msbuild in the "Code section".)

MSBUILD : error MSB1021: Cannot create an instance of the logger. Could not load file or assembly 'Microsoft.Build.Engine' or one of its dependencies. The system cannot find the file specified.

Is it because msbuild is attempting to use v2.0.50727 that we get the error below?
Note: VS 2008 builds the project without any errors.

C:\Program Files\CruiseControl.NET\server>msbuild sample.proj /p:Configuration=Debug /l:FileLogger,Microsoft.Build.Engine,verbosity=detailed;logfile=sample.Debug.log
Microsoft (R) Build Engine Version 3.5.30729.1
[Microsoft .NET Framework, Version 2.0.50727.3053]
Copyright (C) Microsoft Corporation 2007. All rights reserved.
 
MSBUILD : error MSB1021: Cannot create an instance of the logger. Could not load file or assembly 'Microsoft.Build.Engine' or one of its dependencies. The system cannot find the file specified.

Open in new window

0
DasDirector
Asked:
DasDirector
  • 2
1 Solution
 
DasDirectorAuthor Commented:
Note - I would like to mention that the projects builds in case I do not specify the logger option to msbuild. The problems happens in case I attempt to use the logger option, it seems in that case msbuild cannot resolve the file Microsoft.Build.engine.dll
I also noted that the .NET Reflector tool from Lutz cannot resolve the Microsoft.Build.engine.dll automatically for msbuild v3.5.
0
 
DasDirectorAuthor Commented:
I believe that I corrected this problem as follows - I copied msbuild.exe and msbuild.exe.config from the windows\framwork folder to \Program Files\Reference Assemblies\Microsoft\Framework\v3.5.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now