<br><br><div class="gmail_quote">On Thu, May 28, 2009 at 7:16 AM, Tyler Roscoe <span dir="ltr"><<a href="mailto:tyler@cryptio.net">tyler@cryptio.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Wed, May 27, 2009 at 11:27:28PM -0500, Robert Dailey wrote:<br>
> From a CMakeLists.txt in my root source dir, I am calling:<br>
> include( ../cmake/common.cmake )<br>
><br>
> From common.cmake, I am calling:<br>
><br>
> include( BoostUtils.cmake )<br>
><br>
> BoostUtils.cmake and common.cmake are side-by-side in the same directory on<br>
> Windows. The second call to include() fails, because the working directory<br>
> is still set to the directory of the CMakeLists.txt, when I expect the<br>
<br>
</div>This is the behavior I would expect. include() is a lot like #include<br>
(or :r in vi); it's as though the contents of the included file were<br>
dropped into the middle of your CMakeLists.<br>
<br>
Ergo, I would write:<br>
<br>
> include( ../cmake/BoostUtils.cmake )</blockquote><div><br>have you tried using CMAKE_CURRENT_SOURCE_DIR or CMAKE_CURRENT_LIST_FILE+extracting the path, i.e.,<br><br> include( ${CMAKE_CURRENT_SOURCE_DIR}/BoostUtils.cmake )<br>
<br><br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
<br>
If you don't want to write ../cmake all the time, I'm pretty sure<br>
there's a variable that controls where CMake will look for things to<br>
include().<br>
<br>
tyler<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>Adolfo Rodríguez Tsouroukdissian<br><br>Robotics engineer<br>PAL ROBOTICS S.L<br><a href="http://www.pal-robotics.com">http://www.pal-robotics.com</a><br>Tel. +34.93.414.53.47<br>
Fax.+34.93.209.11.09<br>