file(DOWNLOAD ...) works with "ftp:" urls.<div><br></div><div>For example, the following script works for me (with CMake 2.8.6):</div><div><br></div><div><div> get_filename_component(dir "${CMAKE_CURRENT_LIST_FILE}" PATH)</div>
<div><br></div><div> file(DOWNLOAD</div><div> "<a href="ftp://ftp.cs.brown.edu/pub/benchmark.ps.Z">ftp://ftp.cs.brown.edu/pub/benchmark.ps.Z</a>"</div><div> "${dir}/benchmark.ps.Z"</div><div> )</div>
<div><br></div><div>I found a small file on the first server mentioned by google when searching for "public anonymous ftp server"</div><div><br></div><div><br></div><div>HTH,</div><div>David</div><div><br></div>
<br><div class="gmail_quote">On Thu, Dec 29, 2011 at 6:01 PM, Robert Dailey <span dir="ltr"><<a href="mailto:rcdailey@gmail.com">rcdailey@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I don't think I've seen a way to use CMake to download files from an FTP server. For certain third party libraries, I'd like to store them on an FTP server and use CMAKE_COMMAND to invoke CMake.exe from within a cmake script to download the files from that FTP server.<div>
<br></div><div>Is it possible to add this functionality? Could anyone recommend a workaround?<br clear="all"><div><br></div><div>---------</div><span class="HOEnZb"><font color="#888888">Robert Dailey<br>
</font></span></div>
<br>--<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></div>