From c03c18ef5dac94e12a3032fe626dde7b3fee178f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timo=20R=C3=B6hling?= Date: Thu, 17 Nov 2022 21:07:46 +0100 Subject: [PATCH] New patch to prefer Python default version Now Python3_FIND_UNVERSIONED_NAMES is set to FIRST, so the default interpreter is checked first. Gbp-Dch: full --- .../0001-Prefer-default-Python-version.patch | 35 +++++++++++++++++++ debian/patches/series | 1 + 2 files changed, 36 insertions(+) create mode 100644 debian/patches/0001-Prefer-default-Python-version.patch create mode 100644 debian/patches/series diff --git a/debian/patches/0001-Prefer-default-Python-version.patch b/debian/patches/0001-Prefer-default-Python-version.patch new file mode 100644 index 000000000..28d742a25 --- /dev/null +++ b/debian/patches/0001-Prefer-default-Python-version.patch @@ -0,0 +1,35 @@ +From: =?utf-8?q?Timo_R=C3=B6hling?= +Date: Fri, 18 Nov 2022 17:29:27 +0100 +Subject: Prefer default Python version + +Forwarded: not-needed +--- + Modules/FindPython/Support.cmake | 2 +- + Modules/FindPythonInterp.cmake | 1 + + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/Modules/FindPython/Support.cmake b/Modules/FindPython/Support.cmake +index 7a127e4..8767908 100644 +--- a/Modules/FindPython/Support.cmake ++++ b/Modules/FindPython/Support.cmake +@@ -1436,7 +1436,7 @@ if (DEFINED ${_PYTHON_PREFIX}_FIND_UNVERSIONED_NAMES) + set (_${_PYTHON_PREFIX}_FIND_UNVERSIONED_NAMES ${${_PYTHON_PREFIX}_FIND_UNVERSIONED_NAMES}) + endif() + else() +- set (_${_PYTHON_PREFIX}_FIND_UNVERSIONED_NAMES LAST) ++ set (_${_PYTHON_PREFIX}_FIND_UNVERSIONED_NAMES FIRST) + endif() + + +diff --git a/Modules/FindPythonInterp.cmake b/Modules/FindPythonInterp.cmake +index 7ad3587..70f4446 100644 +--- a/Modules/FindPythonInterp.cmake ++++ b/Modules/FindPythonInterp.cmake +@@ -94,6 +94,7 @@ if(DEFINED PYTHONLIBS_VERSION_STRING) + endif() + # Search for the current active python version first + list(APPEND _Python_VERSIONS ";") ++list(APPEND _Python_VERSIONS "3") + list(APPEND _Python_VERSIONS ${_PYTHON_FIND_OTHER_VERSIONS}) + + unset(_PYTHON_FIND_OTHER_VERSIONS) diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 000000000..812333042 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1 @@ +0001-Prefer-default-Python-version.patch