none
Project converted from VS2008 to VS2010 causes circular build error. RRS feed

  • Question

  • I have project that was converted from Visual Studio 2008 to Visual Studio 2010. The executable was created but the following error:

    C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.Targets(3051,5): error MSB4006: There is a circular dependency in the target dependency graph involving target "GetCopyToOutputDirectoryItems".

    James


    james
    Sunday, March 27, 2011 2:36 AM

All replies

  • Hi James,

     

    Thanks for your post.

    Could you please let me know which version of VS do you use?

    I think it is a known issue due to

     http://connect.microsoft.com/VisualStudio/feedback/details/534361/better-error-message-for-output-circular-dependency#details 

    I'm not sure if it is fixed in later version.

    If you don't use VS2010 RC version, is it possible to send me a reproducible sample, I can try to find some workarounds.

     Best Regards,

    Ziwei Chen

     

     

     

     

     


    Ziwei Chen [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Monday, March 28, 2011 5:51 AM
  • I apologize, I should have said that this is Visual Studio 2010 sp1.

    James Osburn


    james
    Monday, March 28, 2011 4:09 PM
  • Thanks for your feedback.

    But is it possible to provide a sample to reproduce?

    You can send it to me via email

    tlef22 AT yahoo.com.cn

    Looking forward to your reply.


    Ziwei Chen [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Tuesday, March 29, 2011 3:46 AM
  • I had the same problem and it went away when I removed a call to MSBUILD inside one of my targets.
    Thursday, April 14, 2011 8:07 AM
  • I have the same problem,please tell me what did you remove?
    Saturday, September 17, 2011 9:20 AM
  • The error comes from Visual Studio. There is nothing wrong with your project. (It built before you upgraded to Visual Studio 2010. Right?)

    Despite the problem within Visual Studio, here is a workaround:
    1. Bring up project properties.
    2. Click on "Common Properties" in left panel.
    3. Click on "Framework and References".
    4. Look under "Build Properties" in right panel.
    5. Change the "Copy Local" flag from "True" to "False".
    6. Click on "OK" button.
    7. Rebuild project.
    • Proposed as answer by mirageservo Monday, July 30, 2012 11:46 AM
    Sunday, October 2, 2011 11:34 PM
  • The error comes from Visual Studio. There is nothing wrong with your project. (It built before you upgraded to Visual Studio 2010. Right?)

    Despite the problem within Visual Studio, here is a workaround:
    1. Bring up project properties.
    2. Click on "Common Properties" in left panel.
    3. Click on "Framework and References".
    4. Look under "Build Properties" in right panel.
    5. Change the "Copy Local" flag from "True" to "False".
    6. Click on "OK" button.
    7. Rebuild project.
    Thanks Rich, it worked fopr me
    Tuesday, February 14, 2012 7:02 AM
  • Hi,

    please i have the same problem, I'm trying to convert a  project  from Visual C++ 2005 to Visual C++ 2010 express and the the following error occurs:

     error MSB4006: There is a circular dependency in the target dependency graph involving target "GetCopyToOutputDirectoryItems". I changed "Copy Local" flag to false, but the error is still there.

    Could some personne help me??

    Best regards,

    Fred

    Tuesday, June 19, 2012 7:49 AM
  • I could not find Common properties in left hand panel, therefore couldn't find any of the rest. I am using Visual Studio 2010 so why would it be different?
    Friday, September 7, 2012 9:53 AM
  • Link no longer works :'(
    Friday, September 7, 2012 9:54 AM
  • Thanks,

    Yuu saved my skin!

    Wednesday, August 13, 2014 12:18 PM
  • Look for error project name. Then check current project assembly name and check reference for the same assembly name. Remove it and rebuild.

    Monday, January 25, 2016 9:23 AM
  • Thanks very much mirageservo,

    Your explanation was easy to follow, the fix worked perfectly. Its a shame that (as usual) not a single piece of information, even remotely related to anything useful came from a Microsoft employee.

    Microsoft - FAIL.

    Thursday, January 28, 2016 11:55 AM