<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">I am using configure_file to copy files during the build process. I have a nested directory structure, that can be represented as:<blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">/rootdir<br> CMakeLists.txt<br> /test<br> CMakeLists.txt</blockquote><div><div><br></div><div>When processing rootdir/test/CMakeLists.txt, I have the following:</div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">#---------------------------</blockquote><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">get_filename_component( dir ${CMAKE_CURRENT_LIST_FILE} PATH )<br>configure_file( ${dir}/blessed.txt blessed.txt COPY_FILE )</blockquote><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">#---------------------------</blockquote><br><div>The intention is to copy the file "blessed.txt" from the source tree to the build tree prior to running a regression test.</div><div><br></div><div>On Mac, this works as I intend it to. The file "blessed.txt" is copied to the "test" subdirectory in the build tree.</div><div><br></div><div>On Linux, "blessed.txt" is copied to the top-level directory in the build tree, NOT to the "test" subdirectory.</div><div><br></div><div>Is this a bug, or am I doing something wrong?</div><div><br></div><div>James</div></div></body></html>