[Cmake] Problems with Library Dependencies

Bernhard Zach bzach at hyperwave.com
Wed, 7 Apr 2004 08:01:55 +0200


Are there plans for changing this behavior?

We would really need such a feature, because our source is too big to build
it all in one Makefile.

At least a FIND_LIBRARY/ADD_DEPENDENCIES combination should work.

Thanks for your help,
Bernhard

-----Original Message-----
From: cmake-admin at www.cmake.org [mailto:cmake-admin at www.cmake.org] On Behalf
Of William A. Hoffman
Sent: Tuesday, April 06, 2004 1:57 PM
To: Bernhard Zach; cmake at www.cmake.org
Subject: Re: [Cmake] Problems with Library Dependencies

CMake only depends on libraries that it can build.   You can
link other libraries, but right now it does not depend on them.
So, if there is not an ADD_LIBRARY in the project, the library
will not be in the DEPEND_LIBS.

-Bill


At 04:17 AM 4/6/2004, Bernhard Zach wrote:
>Hi all,
>I hope somebody could help me:
>
>It seems that the Makefile generators have Problems to generate correct
>Library dependencies. 
>The line in the Makefile looks like this:
>myprog_DEPEND_LIBS =
>
>In my CMakeLists.txt:
>FIND_LIBRARY(LibFile mylib ${path1} ${path2})
># do some error checking here...
>
># link the library with absolute path to my binarie
>TARGET_LINK_LIBRARIES (myprog ${LibFile})
>
>The only way I got something in my "myprog_DEPEND_LIBS" is, when the
"mylib"
>is build at the same time (both dirs with SUBDIR-Command)
>
>I've tried it under Linux and Windows(nmake).
>I also played with the ADD_DEPENDENCIES-Command with no result.
>
>Did I misunderstood something from the Cmake-concept?
>
>Thanks for some help,
>Bernhard
>
>_______________________________________________
>Cmake mailing list
>Cmake at www.cmake.org
>http://www.cmake.org/mailman/listinfo/cmake 

_______________________________________________
Cmake mailing list
Cmake at www.cmake.org
http://www.cmake.org/mailman/listinfo/cmake