diff options
-rw-r--r-- | .gitlab-ci.yml | 14 | ||||
-rw-r--r-- | meson.build | 4 | ||||
-rwxr-xr-x | setup.py | 3 |
3 files changed, 7 insertions, 14 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index be27ed22..7f0149e0 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -51,20 +51,6 @@ pages: only: - master -python2-mingw32: - variables: - PYTHON: "python2" - MSYSTEM: "MINGW32" - CHERE_INVOKING: "yes" - <<: *mingw-defaults - -python2-mingw64: - variables: - PYTHON: "python2" - MSYSTEM: "MINGW64" - CHERE_INVOKING: "yes" - <<: *mingw-defaults - python3-mingw32: variables: PYTHON: "python3" diff --git a/meson.build b/meson.build index 9cdb1e96..e44f7be0 100644 --- a/meson.build +++ b/meson.build @@ -15,6 +15,10 @@ platform_version = '@0@.0'.format(pygobject_version_major) pymod = import('python') python = pymod.find_installation(get_option('python')) +if python.language_version().version_compare('< 3.0') and host_machine.system() == 'windows' + error('Python 2 on Windows no longer supported since 3.35. Use Python 3 instead.') +endif + python_dep = python.dependency() glib_version_req = '>= 2.48.0' @@ -1111,6 +1111,9 @@ class build_ext(du_build_ext): add_ext_compiler_flags(gi_cairo_ext, compiler) def run(self): + if os.name == "nt" and sys.version_info[0] == 2: + raise SystemExit("Python 2 on Windows no longer supported since 3.35. Use Python 3 instead.") + self._write_config_h() self._setup_extensions() du_build_ext.run(self) |