[CMake] Re: [Dart] ADD_TEST using a Python script

Andy Cedilnik andy.cedilnik at kitware.com
Fri Jul 15 11:49:19 EDT 2005


Hi Anton,

Ok, I set the PYTHONINTERP_FOUND and I added the Python 2.4.

As far as /bin /usr/bin.. goes, they are in the path and FIND_PROGRAM
does look in the path.

       Andy

Anton Deguet wrote:

>Hi Andy,
>
>You were right, I just had to replace the \ by /.  I'll never get used
>to these.
>
>I took a quick look at the FindPythonInterp.cmake and I have a couple of
>remarks:
>
>- PYTHONINTERP_FOUND doesn't seem to be set by anyone, but it is
>mentioned in the comments.
>
>- For Windows, I believe you are missing the register key for Python 2.4
>path.
>
>- Would this work on unix as well? I didn't see the usual /usr,
>/usr/local ....
>
>
>Anton
>
>
>
>
>
>On Fri, 2005-07-15 at 08:30, Andy Cedilnik wrote:
>  
>
>>Hi Anton,
>>
>>I'll add FindPython.cmake.
>>
>>As far as the tests goes, could you make sure that the path to your
>>python files is a unix style path '/' and not '\'.
>>
>>       Andy
>>
>>Anton Deguet wrote:
>>
>>    
>>
>>>Andy,
>>>
>>>Thank you for the info.  I thought of using the Python executable but I
>>>couldn't find it defined in one of the CMake modules and I was hoping I
>>>wouldn't have to locate it myself.
>>>
>>>The solution works partially, i.e. on Windows the first test runs but
>>>not the others (it works fine on Linux).  The Dart test file is
>>>generated by Python and contains multiple lines of ADD_TEST.  Do you
>>>know what CMake/CTest is using for its end of line?  FYI, I attached the
>>>generated file.
>>>
>>>Anton
>>>
>>>
>>>PS: Would it be possible to add a PYTHON_EXECUTABLE somewhere in the
>>>CMake modules?  Either add it to FindPythonLibs.cmake or create a
>>>FindPython.cmake to keep the libs and executables separated.
>>> 
>>>
>>>      
>>>
>>>>>ADD_TEST("Python: vctFixedSizeVectorTest.TestInt6" c:/Python24/python.exe c:\users\anton\cisst\Msvc7.1\tests\bin\Release\cisstVectorTests.py -t vctFixedSizeVectorTest.vctFixedSizeVectorTest.TestInt6)
>>>>>     
>>>>>
>>>>>          
>>>>>


-- 
Andy Cedilnik
Kitware Inc.



More information about the CMake mailing list