[CMake] Which variable stores all (sub) directories added sofar?

Rolf Eike Beer eike at sf-mail.de
Thu May 19 06:47:14 EDT 2011


Am Donnerstag, 19. Mai 2011, 12:22:32 schrieb J.S. van Bethlehem:
> Hello,
> 
> Given that CMake errs when you try to some sub-directory twice using
> add_subdirectory() I presume there is some variable that stores a list
> of the directories that were added to the build sofar. But I can't find
> the name of the variable. Does it exists (well... better would be: is it
> visible to users) and if so, what is it called?

I don't know the answer to your question, but:

I use a global property to store the absolute path of all subdirectories added 
by a macro. If this macro encounters that the requested subdirectory is 
already in the list it simply does nothing.

Eike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20110519/6c87a17f/attachment.pgp>


More information about the CMake mailing list