Thanks for the response on this, I was able to get this to work (to
degrees) with libtiff and Jasper as well as other non CMake-a-fied
projects. I have run into another issue where I wish to use
configure_file to generate a CMakeLists.txt file in the directory where
ExternalProject_add dumps the source and looks for the CMakeLists.txt
file. <br>
<br>
The problem is that I cannot configure_file at CMakeLists.txt.config
file into a CMakeLists.txt file in the source directory where
ExternalProject_Add will later look for it as ExternalProject_Add
removes the file and generates the error:<br>
<br>
CMake Error: The source directory
"D:/projects/glade/branches/glade_win_x64/source/libtiff" does not
appear to contain CMakeLists.txt.<br>
<br>
Clicking the Generate button in CMake creates the CMakeLists.txt file
and the ExternalProject_Add works just fine, but requires going back and
clicking generate in CMake<br>
<br>
I think my options are currently to run patch (not as powerful as
configure_file) using PATCH_COMMAND which as I recall is not in on Win
boxes and for which I have used GNUWin32 or possibly the
CONFIGURE_COMMAND. Maybe I should recursively call CMake to
configure_file the CMakeLists.txt file? <br>
<br>
Thanks,<br>
<br>
Brian<br><br><div class="gmail_quote">On Sun, Jun 17, 2012 at 2:10 PM, David Cole <span dir="ltr"><<a href="mailto:david.cole@kitware.com" target="_blank">david.cole@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
You could use:<div><span style="border-collapse:collapse;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="border-collapse:collapse;color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px"> BUILD_COMMAND nmake /f <a href="http://makefile.vc/" style="color:rgb(17,85,204)" target="_blank">makefile.vc</a></span></div>
<div><font color="#222222" face="arial, sans-serif"><span style="border-collapse:collapse"> BUILD_IN_SOURCE 1<br></span></font><br></div><div>in your ExternalProject_Add call.</div>
<div><br></div><div>"nmake" is already available from within the Visual Studio environment.</div><div><br></div><div>Of
course, if your project is cross-platform, you'll have to
conditionalize this so that it only happens when using a Visual Studio
or NMake generator.</div>
<div><br></div><div><br></div><div>HTH,</div><div>David</div><br>
</blockquote></div><br>