title: MSBuild: Building asp.net 4.0 web sites: .metaproj -files
body: <p>I have a solution-file with ASP.NET Web Sites.</p>
  
  <p>When I build the solution with .NET 4.0 Beta 2 using</p>
  
  <blockquote>
    <p>"c:\WINDOWS\Microsoft.NET\Framework\v4.0.21006\MSBuild.exe" d:\MyPath\MySolution.sln</p>
  </blockquote>
  
  <p>Everything works fine, no errors. Then I try to build the same solution with CruiseControl .NET task (msbuild-script ran by a service), the same solution fails with:</p>
  
  <blockquote>
    <p>D:\MyPath\MyWebSite.metaproj (,): errorMSB4025: The project file could not be loaded. Could not find file 'D:\MyPath\MyWebSite.metaproj'.</p>
  </blockquote>
  
  <p>Of course, there is no file like that. I guess *.metaproj is a .csproj-like msbuild-file generated dynamically for web sites...</p>
  
  <p>But I don't know how to fix the error... I tried to google metaproj-files with no luck. I did try to make the file manually, I inserted a &lt;Project&gt; with &lt;Task Name="Rebuild"&gt; and the compilation didn't raise any errors, but I guess the site didn't compile. </p>
  
  <p>The same machine has .NET 3.5 and .NET 4.0 projects and environment variables for both frameworks.</p>