[CMake] Modules with additional files

Johannes Wienke jwienke at techfak.uni-bielefeld.de
Wed Dec 29 14:27:07 EST 2010


Hey again,

Am 29.12.2010 20:23 schrieb Johannes Wienke:
> Am 29.12.2010 19:53 schrieb Michael Jackson:
>> I don't understand what you mean by a "module". If you are in a CMakeLists.txt or *.cmake file that is being parsed by CMake then you have access to CMAKE_CURRENT_LIST_FILE. I think I am missing something about your particular setup. Maybe some more details would help us. 
> 
> Confusing, I thought I checked this twice that CMAKE_CURRENT_LIST_*
> always only points to CMakeLists.txt files, but it works perfectly. ;)
> 
> Thanks alot, I must have been really tired. ;)

Ok, now I understand my original problem: In one of these modules there
is a function defined which originally used CMAKE_CURRENT_LIST_DIR. When
this function is used, CMAKE_CURRENT_LIST_DIR is set to the list file of
the function caller. Somehow I would have expected this behavior only
for macros and not for functions. Is this intended?

Johannes

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <http://www.cmake.org/pipermail/cmake/attachments/20101229/8b1bd2a9/attachment.pgp>


More information about the CMake mailing list