Be careful with your use of $ENV{PROGRAMFILES} - it might not give you what you expect on a 64-bit computer. Since the CMake binary is by default 32-bit, you need some logic to make sure you&#39;re looking where you think you&#39;re looking.<br>
<br>See also:<br><a href="http://public.kitware.com/Bug/view.php?id=9992">http://public.kitware.com/Bug/view.php?id=9992</a> - related CMake bug with patch: contains some cmake script code to figure out what program files env var is appropriate to search given the *build type* (32-bit or 64-bit) regardless of the bit mode of the CMake executable itself.<br>
<a href="http://en.wikipedia.org/wiki/Environment_variable#System_path_variables">http://en.wikipedia.org/wiki/Environment_variable#System_path_variables</a> - explanation of the numerous ProgramFiles variables on a 64-bit system.<br>
<br>Ryan<br><br><div class="gmail_quote">On Wed, Jul 14, 2010 at 11:08 AM, Eric Noulard <span dir="ltr">&lt;<a href="mailto:eric.noulard@gmail.com">eric.noulard@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
2010/7/14 John Drescher &lt;<a href="mailto:drescherjm@gmail.com">drescherjm@gmail.com</a>&gt;:<br>
<div class="im">&gt; On Wed, Jul 14, 2010 at 11:15 AM, Verweij, Arjen &lt;<a href="mailto:VerweijA@tass-safe.com">VerweijA@tass-safe.com</a>&gt; wrote:<br>
&gt;&gt; Hi,<br>
&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;You seem to have a path using \ instead of /<br>
&gt;&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; Isn&#39;t that to be expected of a PATH setting on a Windows computer?<br>
&gt;&gt; Anyway, the path to the Visual Studio compiler is of the same format and cmake deals with it just fine.<br>
&gt;&gt;<br>
&gt;<br>
&gt; I use / for all paths inside my CMakeLists.txt files even on windows<br>
&gt; computers. If I am grabbing paths from the environment I use a string<br>
&gt; replace in the CMakeLists.txt<br>
&gt;<br>
&gt; string (REPLACE &quot;\\&quot; &quot;/&quot; PGM_FILES $ENV{PROGRAMFILES})<br>
<br>
</div>file(TO_CMAKE_PATH &quot;$ENV{PROGRAMFILES}&quot; PGM_FILES)<br>
<br>
should work as well.<br>
<br>
see the file command for details.<br>
<div class="im"><br>
<br>
--<br>
Erk<br>
Membre de l&#39;April - « promouvoir et défendre le logiciel libre » -<br>
<a href="http://www.april.org" target="_blank">http://www.april.org</a><br>
_______________________________________________<br>
</div><div><div></div><div class="h5">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>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Ryan Pavlik<br>HCI Graduate Student<br>Virtual Reality Applications Center<br>Iowa State University<br><br><a href="mailto:rpavlik@iastate.edu">rpavlik@iastate.edu</a><br>
<a href="http://academic.cleardefinition.com">http://academic.cleardefinition.com</a><br>Internal VRAC/HCI Site: <a href="http://tinyurl.com/rpavlik">http://tinyurl.com/rpavlik</a><br>