For Programmers: Free Programming Magazines  


Home > Archive > Visual Studio > November 2005 > How to get rid of automatic dependencies?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author How to get rid of automatic dependencies?
greg.corson@gmail.com

2005-11-16, 7:03 pm

I'm running into a problem where the project dependencies feature of
..net 2003 is adding unwanted files into my link. The project layout
looks like this...

Version 1 specific library -> makes v1.lib static library
Version 2 specific library -> makes v2.lib static library
Common to all versions library -> makes common.lib static library
Application

"Application" has build targets to build a version 1 application and a
version 2 application. The version 1 target should link the app with
v1.lib and common.lib, the version 2 target should link with v2.lib and
common.lib.

Because there is only one "project dependencies" (not one per build
target) I have to set "Application" to depend on all three libs. When
you do this, VC++ automatically adds all three libs to the linker line
which is NOT what I want. It needs to link with either v1.lib or
v2.lib but NOT both.

Anyone know a way to stop this? I thought "ignore import library"
would work, but this property isn't available for the librarian.

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com