diff --git a/CMakeLists.txt b/CMakeLists.txt index 2787b4f8380..74488132bf7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1234,10 +1234,10 @@ if(WITH_PYTHON) # Do this before main 'platform_*' checks, # because UNIX will search for the old Python paths which may not exist. # giving errors about missing paths before this case is met. - if(DEFINED PYTHON_VERSION AND "${PYTHON_VERSION}" VERSION_LESS "3.10") + if(DEFINED PYTHON_VERSION AND "${PYTHON_VERSION}" VERSION_LESS "3.11") message( FATAL_ERROR - "At least Python 3.10 is required to build, but found Python ${PYTHON_VERSION}" + "At least Python 3.11 is required to build, but found Python ${PYTHON_VERSION}" ) endif() diff --git a/GNUmakefile b/GNUmakefile index bb98d49d906..3a55a1d7dbb 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -223,9 +223,6 @@ ifeq (, $(wildcard $(LIBDIR)/python/lib/python$(PY_LIB_VERSION))) PY_LIB_VERSION:=3.12 ifeq (, $(wildcard $(LIBDIR)/python/lib/python$(PY_LIB_VERSION))) PY_LIB_VERSION:=3.11 - ifeq (, $(wildcard $(LIBDIR)/python/lib/python$(PY_LIB_VERSION))) - PY_LIB_VERSION:=3.10 - endif endif endif endif diff --git a/build_files/cmake/platform/platform_win32.cmake b/build_files/cmake/platform/platform_win32.cmake index cb574b2dfd2..5d67879fc9e 100644 --- a/build_files/cmake/platform/platform_win32.cmake +++ b/build_files/cmake/platform/platform_win32.cmake @@ -555,11 +555,15 @@ endif() set(_PYTHON_VERSION "3.11") string(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${_PYTHON_VERSION}) -if(NOT EXISTS ${LIBDIR}/python/${_PYTHON_VERSION_NO_DOTS}) - set(_PYTHON_VERSION "3.10") - string(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${_PYTHON_VERSION}) + +# Enable for a short time when bumping to the next Python version. +if(FALSE) if(NOT EXISTS ${LIBDIR}/python/${_PYTHON_VERSION_NO_DOTS}) - message(FATAL_ERROR "Missing python libraries! Neither 3.11 nor 3.10 are found in ${LIBDIR}/python") + set(_PYTHON_VERSION "3.12") + string(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${_PYTHON_VERSION}) + if(NOT EXISTS ${LIBDIR}/python/${_PYTHON_VERSION_NO_DOTS}) + message(FATAL_ERROR "Missing python libraries! Neither 3.12 nor 3.11 are found in ${LIBDIR}/python") + endif() endif() endif() diff --git a/source/blender/python/intern/bpy_capi_utils.h b/source/blender/python/intern/bpy_capi_utils.h index 840b68953ac..9013b2932f2 100644 --- a/source/blender/python/intern/bpy_capi_utils.h +++ b/source/blender/python/intern/bpy_capi_utils.h @@ -10,8 +10,8 @@ #include -#if PY_VERSION_HEX < 0x030a0000 -# error "Python 3.10 or greater is required, you'll need to update your Python." +#if PY_VERSION_HEX < 0x030b0000 +# error "Python 3.11 or greater is required, you'll need to update your Python." #endif #ifdef __cplusplus