1 # Python testing directory, 'demo' is not very explicit ...
3 #-----------------------------------------------------------------------------
4 # DOH! python is not found by default
5 FIND_PROGRAM(PYTHON_EXECUTABLE
6 NAMES python python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5
8 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.4\\InstallPath]
9 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.3\\InstallPath]
10 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.2\\InstallPath]
11 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.1\\InstallPath]
12 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.0\\InstallPath]
13 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\1.6\\InstallPath]
14 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\1.5\\InstallPath]
16 MARK_AS_ADVANCED(PYTHON_EXECUTABLE)
19 ADD_TEST(Python-PrintDict ${PYTHON_EXECUTABLE}
20 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintDict.py
22 ADD_TEST(Python-PrintFile ${PYTHON_EXECUTABLE}
23 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintFile.py
25 ADD_TEST(Python-PrintDicomDir ${PYTHON_EXECUTABLE}
26 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintDicomDir.py
28 ELSE(PYTHON_EXECUTABLE)
29 MESSAGE(FATAL_ERROR "You requested testing for python, but python was not
31 ENDIF(PYTHON_EXECUTABLE)
33 #-----------------------------------------------------------------------------
34 # Copy all the demo directory content to the cmake bin
35 # Without it, tests can't be launched
37 ${GDCM_SOURCE_DIR}/gdcmPython/demo/gdcmConfigDemo.py.in
38 ${GDCM_BINARY_DIR}/gdcmPython/demo/gdcmConfigDemo.py
42 ${GDCM_SOURCE_DIR}/gdcmPython/demo/PrintFile.py.in
43 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintFile.py
47 ${GDCM_SOURCE_DIR}/gdcmPython/demo/PrintDicomDir.py.in
48 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintDicomDir.py
52 ${GDCM_SOURCE_DIR}/gdcmPython/demo/PrintDict.py.in
53 ${GDCM_BINARY_DIR}/gdcmPython/demo/PrintDict.py
56 #-----------------------------------------------------------------------------
60 ADD_TEST(Python-VTK-Reader ${PYTHON_EXECUTABLE}
61 ${GDCM_BINARY_DIR}/gdcmPython/demo/vtkGdcmReader.py
63 ADD_TEST(Python-VTK-Writer ${PYTHON_EXECUTABLE}
64 ${GDCM_BINARY_DIR}/gdcmPython/demo/vtkGdcmWriter.py
66 ENDIF(PYTHON_EXECUTABLE)
69 ${GDCM_SOURCE_DIR}/gdcmPython/demo/vtkGdcmReader.py.in
70 ${GDCM_BINARY_DIR}/gdcmPython/demo/vtkGdcmReader.py
74 ${GDCM_SOURCE_DIR}/gdcmPython/demo/vtkGdcmWriter.py.in
75 ${GDCM_BINARY_DIR}/gdcmPython/demo/vtkGdcmWriter.py