Jump to content
  • Advertisement
Sign in to follow this  
Bagpuss

Compiler Issue (MS Vis Studio)

This topic is 4978 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

OK, I have somehow managed to break my program. I had a fully working program (Project A) with a number of classes I put in just as placeholders, so I wouldnt forget to add them later. (They were irrelevant for what I was working on) In another Project (Project B) I hve 2 classes that I would like to use in Project A to replace the placeholder classes. I have added these to the files section of Visual studio, and changed the location of the headers to point to my other project. (I dont want to copy them in to the project folder, as Im maintaining 2 versions of the same classes then) But when I go to compile, I get the error message "The Source Files d:\\Source\ProjectA\foo.cpp and D:\\Source\ProjectB\foo.cpp are both configured to produce the output d:\\Source\ProjectB\foo.obj. Project cannot be built" I have had a good louck amogst all the settings and cannot find out where to change this. I didnt link Project B into a, just referenced the 2 .h files. Before I give in and just copy the class files over to my new project and have to maintain 2 sets of code, can anyone tell me where / how to fix this. Thansk, Bp

Share this post


Link to post
Share on other sites
Advertisement
Simple: you can only have one copy of foo.cpp in your project. Did you forget to remove foo.cpp from project A before adding the one from project b?

Share this post


Link to post
Share on other sites
thanks for the reply. Yes, all copies of the old files are still there, but renamed _oldFoo and _oldBar.

Hmm, its a mystery

Bp

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!