[CMake] Best way to 'pull through' dependencies of External projects?

Kent Williams nkwmailinglists at gmail.com
Thu Feb 14 10:45:12 EST 2013


The specific problem I'm trying to solve:

Build DCMTK library, along with libraries upon which it depends, for use by
ITK as a 'system library'

The problem: Setting up the External Projects is simple enough; the problem
is that the revision/configuration of TIFF -- 3.9.4 -- by default requires
ZLib.

DCMTK builds against this external TIFF library just fine.

What doesn't happen?  The TIFF's ZLib dependency doesn't get propogated to
builds that depend on DCMTK, so Zlib is not on the DCMTK library list.

This wouldn't be a problem if TIFF and DCMTK were proper CMake builds. If
they were when they export their libraries, find_package would carry along
the dependencies of the imported libraries.

There doesn't appear to be either an elegant or a quick & dirty solution to
this. The problem is that until DCMTK creates proper CMake config files
that clue in ITK to DCMTK's own dependencies, ITK's own CMake config files
will not reflect those dependencies.

Suggestions?

Oh, and by the way I am trying to get DCMTK to generate proper
configuration files for find_package(NO_MODULE):
https://github.com/InsightSoftwareConsortium/DCMTK/tree/AddProperConfig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130214/a5e51894/attachment.htm>


More information about the CMake mailing list