Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / February 2007

Tip: Looking for answers? Try searching our database.

C++ debug/release builds and project references

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Andrew Rowley - 01 Feb 2007 01:32 GMT
I am having trouble getting debug and release builds to work properly
with project references using C++ .NET and Visual Studio 2003.

I created a test solution, with a basic Windows form C++ project.
I then add a class library, and add a reference to this project in the
first project.

When I do a release build, I see the following in the output from the
DLL compile:
/OUT:"C:\Documents and Settings\Andrew\My Documents\Visual Studio
Projects\DependencyTest\Release\test.dll"

OK so far.

When the windows form app compiles, however, I see:
/FU "c:\Documents and Settings\Andrew\My Documents\Visual Studio
Projects\DependencyTest\Debug\test.dll"

Where does this "Debug" come from? Everywhere else in the output says
"Release".

Can anyone tell me what I am doing wrong? How can I use a debug
version of a DLL for a debug build, and a release version for the
release build?
--
Andrew Rowley
Bruno van Dooren [MVP VC++] - 01 Feb 2007 08:57 GMT
> I am having trouble getting debug and release builds to work properly
> with project references using C++ .NET and Visual Studio 2003.
[quoted text clipped - 20 lines]
> version of a DLL for a debug build, and a release version for the
> release build?

Hi,

How did you add the reference?
Did you select the DLL by browsing to it, or did your use the 'projects' tab
in the references dialog?

Also, if you open build->configuration manager
you can see how the debug / release builds are configured.
It could be possible that your solution release config is set to use the
release project setting for one project and the debug setting for another.

Signature

Kind regards,
   Bruno.
   bruno_nos_pam_van_dooren@hotmail.com
   Remove only "_nos_pam"

Andrew Rowley - 01 Feb 2007 10:16 GMT
Bruno van Dooren [MVP VC++] <bruno_nos_pam_van_dooren@hotmail.com>
wrote:

>How did you add the reference?
>Did you select the DLL by browsing to it, or did your use the 'projects' tab
>in the references dialog?

I used the projects tab in the references dialog.

>Also, if you open build->configuration manager
>you can see how the debug / release builds are configured.
>It could be possible that your solution release config is set to use the
>release project setting for one project and the debug setting for another.

The release configuration is set to release for both projects, and the
debug configuration is set to debug for both projects.

See my reply to Jeffery - it might be happening only when I change
from one to the other, and seems to be a problem in either direction.

I suspect it has been happening to me for a long time, but went
unnoticed because there was always a debug and release dll there. I
think it only started causing me problems when I used strong names,
and ran into problems with mismatched version numbers.

Regards

Andrew Rowley
--
Andrew Rowley

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.