]> git.lyx.org Git - lyx.git/blobdiff - CMakeLists.txt
es.po: updates by Ignacio
[lyx.git] / CMakeLists.txt
index e10ab3d8326dcaad151600c172fb70f50d902f82..39880f24ef63f35da39e8fcf29e4d7167fdd5a89 100644 (file)
@@ -640,24 +640,25 @@ foreach(_spell "ASPELL" "Enchant" "Hunspell")
   endif()
 endforeach()
 
+if(NOT LYX_PYTHON_EXECUTABLE)
+       find_package(PythonInterp 2.7 QUIET)
+       if(PYTHONINTERP_FOUND)
+         if(PYTHON_VERSION_STRING VERSION_GREATER 2.8)
+               unset(PYTHONINTERP_FOUND)
+         endif()
+       endif()
 
-find_package(PythonInterp 2.7 QUIET)
-if(PYTHONINTERP_FOUND)
-  if(PYTHON_VERSION_STRING VERSION_GREATER 2.8)
-    unset(PYTHONINTERP_FOUND)
-  endif()
-endif()
+       if(NOT PYTHONINTERP_FOUND AND NOT GNUWIN32_DIR)
+         unset(PYTHON_EXECUTABLE CACHE)
+         unset(PYTHON_VERSION_MAJOR)
+         unset(PYTHON_VERSION_MINOR)
+         unset(PYTHON_VERSION_STRING)
+         find_package(PythonInterp 3.3 REQUIRED)
+       endif()
 
-if(NOT PYTHONINTERP_FOUND AND NOT GNUWIN32_DIR)
-  unset(PYTHON_EXECUTABLE CACHE)
-  unset(PYTHON_VERSION_MAJOR)
-  unset(PYTHON_VERSION_MINOR)
-  unset(PYTHON_VERSION_STRING)
-  find_package(PythonInterp 3.3 REQUIRED)
+       set(LYX_PYTHON_EXECUTABLE ${PYTHON_EXECUTABLE} CACHE FILEPATH "Python to be used by LyX")
 endif()
 
-set(LYX_PYTHON_EXECUTABLE ${PYTHON_EXECUTABLE} CACHE FILEPATH "Python to be used by LyX")
-
 if(LYX_NLS)
        find_package(LyXGettext)
        if(LYX_PYTHON_EXECUTABLE AND GETTEXT_FOUND)