[CMake] Resolution of dependencies for Subversion

Philip Lowman philip at yhbt.com
Sun Sep 27 10:13:14 EDT 2009


On Sun, Sep 27, 2009 at 4:50 AM, SF Markus Elfring <
elfring at users.sourceforge.net> wrote:

> > If you're asking if the module should find "svn.exe" if all you need
> > is the subversion libraries, the answer is it doesn't have to. Once
> > COMPONENTS have been specified the module can require the user
> > specify one to find executables as well. FindImageMagick is a good
> > example of this. It maintains backwards compatibility if COMPONENTS
> > is not specified but otherwise requires each component that is to be
> > searched for to be explicitly named regardless of it it is a program
> > or a library.
>
> Thanks for your explanation.
>
> Can it be avoided to copy and paste source code from other configuration
> scripts into the discussed update candidate?
> Does a base class exist which provides the common functionality for path
> searching and variable setting?
>

There are no classes in CMake script, only functions and macros.  Searching
for include directories and libraries is accomplished via the find_path and
find_library commands, respectively.  If a find modules has to call
find_library more than once typically a function is employed via a foreach
loop.


> How many instructions have the available files got in common so that more
> configuration code can be moved into base functions?
>

Most find modules are fairly simple but many of them have their quirks.  I
don't think there's a tremendous opportunity available to generalize what
they do if you're asking, but it certainly is possible.  The solution could
also be in the form of new higher-level CMake commands.

-- 
Philip Lowman
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20090927/3b3dccdf/attachment.htm>


More information about the CMake mailing list