Hi Brad,

>> +    if (!cmSystemTools::FileIsFullPath(i->c_str())) {
>> +      *i = std::string(makefile.GetCurrentSourceDirectory()) + "/" + *i;
>
> Perhaps we should issue a diagnostic here.  In principle the caller
> should always provide a full path.  If they use a genex to do it then
> they are on their own.

I don't really mind. The reason I did it like this was mainly that the
docs for install(DIRECTORY) mention: "Directory names given as
relative paths are interpreted with respect to the current source
directory.". If we can have consistent and documented behavior without
needing to issues warning or error messages, wouldn't it be better to
do so? Additionally, the same 'fix' could also be applied to
install(FILES), which in the docs currently explicitly states that
"However, if any item begins in a generator expression it must
evaluate to a full path".

Please let me know what you decide and I'll prepare a new patch.

Thanks,
Yves
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to