Within paraview we wish to build hdf5, which is now cmake based, so we
ADD_SUBDIRECTORY(blah) and hdf5 is compiled nicely with lib targets added to
the build.
Some settings (like lib names) are needed by the host project, so we want to
SET(HDF5_CONFIG ${ParaView_BINARY_DIR}/Utilities/hdf5-1.8/HDF5-config.cmake)
INCLUDE(${HDF5_CONFIG})
But this file - which is generated for us by cmake and placed in the build tree
- has contents like
# Create imported target vtkhdf5
ADD_LIBRARY(vtkhdf5 SHARED IMPORTED)
And naturally if I include this inside the host project build - it complains
that vtkhdf5 can't be added as an imported library as it is already a target in
the main build - created when I did add_subdirectoy for the hdf5 source.
Is there a similar functionality, other than the 'old style' configure_file
command to generate a bunch of settings that can be picked up by the host
project. I had the impression that the new project import/export/install stuff
was designed to make this sort of thing more automated, but I think I'm missing
a piece of the puzzle.
thanks
JB
--
John Biddiscombe, email:biddisco @ cscs.ch
http://www.cscs.ch/
CSCS, Swiss National Supercomputing Centre | Tel: +41 (91) 610.82.07
Via Cantonale, 6928 Manno, Switzerland | Fax: +41 (91) 610.82.82
_______________________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake