Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread James Amundson
On 02/26/2010 09:15 AM, Bill Hoffman wrote: I am thinking that we should put python in the front of the list of names. Great. I have a detailed argument for why that's the right choice, but I'll spare everyone if the decision is already made. --Jim Amundson _

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread Marcus D. Hanwell
On Friday 26 February 2010 10:15:06 Bill Hoffman wrote: > Mathieu Malaterre wrote: > the windows one prefer python > > >>> over any of the named version ones... > >> > >> Or find both independently and compare their versions. OTOH, the problem > >> was the library/executable mismatch, so it doesn

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread Bill Hoffman
Mathieu Malaterre wrote: the windows one prefer python over any of the named version ones... Or find both independently and compare their versions. OTOH, the problem was the library/executable mismatch, so it doesn't matter which is found as long as the library matches the executable. +1 There

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread Mathieu Malaterre
On Fri, Feb 26, 2010 at 9:17 AM, Hendrik Sattler wrote: > Zitat von Bill Hoffman : > >> Noel O'Boyle wrote: >> >>> >>> Done. I've attached the result (off list). In summary it seems to be >>> searching for python2.6.exe first, instead of python.exe. >>> >> >> OK, so that is the problem >> >> I

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread Hendrik Sattler
Zitat von Bill Hoffman : Noel O'Boyle wrote: Done. I've attached the result (off list). In summary it seems to be searching for python2.6.exe first, instead of python.exe. OK, so that is the problem It looks for names in this order: NAMES python2.6 python2.5 python2.4 python2.3 pytho

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-26 Thread Michael Wild
On 25. Feb, 2010, at 22:39 , James Amundson wrote: > On 02/25/2010 12:29 PM, Bill Hoffman wrote: >> OK, so that is the problem >> >> It looks for names in this order: >> >> NAMES python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 >> python1.6 python1.5 python >> > Coinc

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread James Amundson
On 02/25/2010 12:29 PM, Bill Hoffman wrote: OK, so that is the problem It looks for names in this order: NAMES python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5 python Coincidently, I had a bug report that arose from the above ordering just this a

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Bill Hoffman
Noel O'Boyle wrote: Done. I've attached the result (off list). In summary it seems to be searching for python2.6.exe first, instead of python.exe. OK, so that is the problem It looks for names in this order: NAMES python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 p

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Noel O'Boyle
On 25 February 2010 18:41, David Cole wrote: > On Thu, Feb 25, 2010 at 1:29 PM, Bill Hoffman > wrote: >> >> Noel O'Boyle wrote: >> >>> >>> Done. I've attached the result (off list). In summary it seems to be >>> searching for python2.6.exe first, instead of python.exe. >>> >> >> OK, so that is th

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Bill Hoffman
David Cole wrote: Same problem as ever: when multiple versions are installed an automatic "find" 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. On the other hand, we should not have a version/

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread David Cole
On Thu, Feb 25, 2010 at 1:29 PM, Bill Hoffman wrote: > Noel O'Boyle wrote: > > >> Done. I've attached the result (off list). In summary it seems to be >> searching for python2.6.exe first, instead of python.exe. >> >> > OK, so that is the problem > > It looks for names in this order: > > NAMES

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Noel O'Boyle
On 25 February 2010 16:18, Bill Hoffman wrote: > Noel O'Boyle wrote: > >> >> Good question. It works: >> -- Found PythonInterp: C:/Python26/python.exe >> -- Found PythonLibs: C:/Python26/libs/python26.lib >> >> However, if I set the PATH to C:\Python26;C:\Cygwin\bin, the original >> problem reappe

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Bill Hoffman
Noel O'Boyle wrote: Good question. It works: -- Found PythonInterp: C:/Python26/python.exe -- Found PythonLibs: C:/Python26/libs/python26.lib However, if I set the PATH to C:\Python26;C:\Cygwin\bin, the original problem reappears. (It's also there if I have PATH=C:\Cygwin\bin;C:\Python26.) S

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Noel O'Boyle
On 25 February 2010 15:44, Bill Hoffman wrote: > Noel O'Boyle wrote: >> >> On 24 February 2010 22:20, Bill Hoffman wrote: >>> >>> Noel O'Boyle wrote: Hello all, With the following CMakeLists.txt on Windows... project("MyProject" NONE) find_package(PythonInterp)

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Bill Hoffman
Noel O'Boyle wrote: On 24 February 2010 22:20, Bill Hoffman wrote: Noel O'Boyle wrote: Hello all, With the following CMakeLists.txt on Windows... project("MyProject" NONE) find_package(PythonInterp) find_package(PythonLibs) Using CMake 2.6.4 (or CMake 2.8), I get -- Found PythonInterp: C:/

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-25 Thread Noel O'Boyle
On 24 February 2010 22:20, Bill Hoffman wrote: > Noel O'Boyle wrote: >> >> Hello all, >> >> With the following CMakeLists.txt on Windows... >> >> project("MyProject" NONE) >> find_package(PythonInterp) >> find_package(PythonLibs) >> >> Using CMake 2.6.4 (or CMake 2.8), I get >> >> -- Found PythonI

Re: [CMake] CMake finds the wrong Python interpreter on Windows

2010-02-24 Thread Bill Hoffman
Noel O'Boyle wrote: Hello all, With the following CMakeLists.txt on Windows... project("MyProject" NONE) find_package(PythonInterp) find_package(PythonLibs) Using CMake 2.6.4 (or CMake 2.8), I get -- Found PythonInterp: C:/Cygwin/bin/python2.5.exe -- Found PythonLibs: C:/Python26/libs/python2

[CMake] CMake finds the wrong Python interpreter on Windows

2010-02-24 Thread Noel O'Boyle
Hello all, With the following CMakeLists.txt on Windows... project("MyProject" NONE) find_package(PythonInterp) find_package(PythonLibs) Using CMake 2.6.4 (or CMake 2.8), I get -- Found PythonInterp: C:/Cygwin/bin/python2.5.exe -- Found PythonLibs: C:/Python26/libs/python26.lib instead of --