Thanks, Luigi. However, I read the CMake 2.8 doc and tried to use function "ExternalProject_Add". When I ran cmake in the root of my project, I got the following error<div><br></div><div>Unknown CMake command "ExternalProject_Add"</div>
<div><br></div><div>I tried on both linux and mac and got the same error. And I am sure the version of the cmake is 2.8</div><div><br></div><div>Best,</div><div>Meng</div><div><br><br><div class="gmail_quote">On Sun, Feb 28, 2010 at 4:50 AM, Luigi Calori <span dir="ltr"><<a href="mailto:l.calori@cineca.it">l.calori@cineca.it</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Albert Z wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hello,<br>
Our project now uses a bunch of 3rd party libraries such as apr, protobuf, libcurl, etc. Almost all of these libraries use autoconf (<a href="http://configure.in" target="_blank">configure.in</a> <<a href="http://configure.in" target="_blank">http://configure.in</a>>) based build system. Since we have some modifications to most of the libraries, we have to integrate these libraries to our cmake build tree. What is the easiest way to integrate such a 3rd-party library to a cmake build with keeping the maximum portability?<br>
</blockquote>
Try to look at ExternalProject module<br>
<a href="http://www.cmake.org/cmake/help/cmake-2-8-docs.html#module:ExternalProject" target="_blank">http://www.cmake.org/cmake/help/cmake-2-8-docs.html#module:ExternalProject</a><br>
and page 10 of <a href="http://www.kitware.com/products/archive/kitware_quarterly1009.pdf" target="_blank">http://www.kitware.com/products/archive/kitware_quarterly1009.pdf</a><br>
<br>
I have used it (with some mods): it allow to automate download pactch,build and install)<br>
Anyway, curl have recently included a CMakeLists in its distribution. I have used it even if had to apply some patches.<br>
I am trying to collect some cmake build recipes for some libraries I need.<br>
If you are interested, grab the stuff at<br>
bzr branch <a href="http://3d.cineca.it/storage/bazaar_repo/CmakeDeps/lib" target="_blank">http://3d.cineca.it/storage/bazaar_repo/CmakeDeps/lib</a><br>
<br>
HTH<br>
<br>
Luigi<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
------------------------------------------------------------------------<div class="im"><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>
</div></blockquote><div><div></div><div class="h5">
<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>
</div></div></blockquote></div><br></div>