On Thu, Feb 25, 2010 at 1:29 PM, Bill Hoffman <span dir="ltr">&lt;<a href="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">Noel O&#39;Boyle wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Done. I&#39;ve attached the result (off list). In summary it seems to be<br>
searching for python2.6.exe first, instead of python.exe.<br>
<br>
</blockquote>
<br></div>
OK, so that is the problem....<br>
<br>
It looks for names in this order:<br>
<br>
NAMES python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5 python<br>
<br>
<br>
It will prefer python2.6 over python in the PATH, and it has no way of knowing or caring if one is cygwin or not.  I don&#39;t think there is much we can do about this.<br>
<br>
I should have noticed this:<br>
C:/Python26/python.exe<div class="im"><br>
C:/Cygwin/bin/python2.5.exe<br>
<br>
<br></div>
I suppose one fix could be to to have the windows one prefer python over any of the named version ones...<div><div></div><div class="h5"><br><br></div></div></blockquote><div><br></div><div>Same problem as ever: when multiple versions are installed an automatic &quot;find&quot; result cannot be relied upon to choose the right one. In that case, caller should set PYTHON_EXECUTABLE explicitly prior to doing the find call.</div>
<div><br></div><div>On the other hand, we should not have a version/path mismatch between python exes and libs and headers. We should consistently find one first, and then find the other stuff relative to that. Or leave that other stuff set as NOTFOUND if there are no libs/headers relative to the exe.</div>
<div><br></div><div>This should be as easy as changing which Qt is found: change QT_QMAKE_EXECUTABLE and other stuff gets re-found. Same logic should apply here: change PYTHON_EXECUTABLE and other stuff should be re-found...</div>
<div><br></div><div><br></div><div>David</div><div><br></div></div>