[CMake] Visual Studio 7.1 and ADD_DEPENDENCIES
Salvatore Iovene
salvatore.iovene+cmake at googlemail.com
Wed Nov 14 12:38:06 EST 2007
On Nov 14, 2007 5:44 PM, Brandon Van Every <bvanevery at gmail.com> wrote:
> On Nov 14, 2007 7:12 AM, Salvatore Iovene
> <salvatore.iovene+cmake at googlemail.com> wrote:
> > Hi,
> > when I use CMake 2.4.7 to generate NMake Makefiles everything builds
> > fine, but if I generate Visual Studio 7.1 project files, and then open
> > the Visual Studio Solution, I notice that some things get linked just
> > for appearing as a dependency.
> >
> > ADD_DEPENDENCIES(my_lib my_otherlib), where both libs are STATIC,
> > will cause my_otherlib to be linked to my_lib even tho I didn't
> > explicitly request so using the TARGET_LINK_LIBRARY command. Is this a
> > bug or am I missing something?
>
> Perhaps a bug... but why are you specifying a dependency, if my_lib
> doesn't utilize my_otherlib?
It _does_ use it. But if do both ADD_DEPENDENCIES and
TARGET_LINK_LIBRARY I'll end up with many many warnings about symbols
already defined, and ignoring because linking twice, which is
annoying. So, perhaps a bug?
--
Salvatore Iovene
http://www.iovene.com/
Key Fingerprint: 5647 944D D5AD 2E87 00B4 7D54 2864 359D FF20 16D8
More information about the CMake
mailing list