mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-11 15:40:31 +01:00
meson.build: require python 3.10, try python3.12
The commit created a problem on RHEL 9 where python 3.9 is the default,
which doesn't support the match keyword used by the commit.
Python 3.12 can be installed as another option, but then another problem
shows up that RHEL 9 lacks recent enough python3-mako that works with 3.12
(or at least that's my understanding of the issue), so we don't know yet
whether Mesa is even buildable on that.
Fixes: f2bb6103 - "vulkan/cmd_queue: Rework copy codegen"
Reviewed-by: Eric Engestrom <eric@igalia.com>
This commit is contained in:
parent
eb8883f3ef
commit
cc9df77220
2 changed files with 18 additions and 3 deletions
|
|
@ -36,7 +36,7 @@ you're willing to maintain support for other compiler get in touch.
|
|||
Third party/extra tools.
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
- `Python <https://www.python.org/>`__ - Python 3.9 or newer is required.
|
||||
- `Python <https://www.python.org/>`__ - Python 3.10 or newer is required.
|
||||
- Python package ``packaging`` is required on Python 3.12+:
|
||||
``pip install packaging``
|
||||
- `Python Mako module <https://www.makotemplates.org/>`__ - Python Mako
|
||||
|
|
|
|||
19
meson.build
19
meson.build
|
|
@ -1032,8 +1032,23 @@ if get_option('allow-kcmp') \
|
|||
pre_args += '-DALLOW_KCMP'
|
||||
endif
|
||||
|
||||
# On Windows, a venv has no versioned aliased to 'python'.
|
||||
prog_python = find_program('python3', 'python', version : '>= 3.9')
|
||||
# Find a python executable that meets our version requirement.
|
||||
# - On Windows, a venv has no versioned aliased to 'python'.
|
||||
# - On RHEL 9, python3 is 3.9, so we must use python3.12.
|
||||
python_version_req = '>= 3.10'
|
||||
python_exec_list = ['python3.16', 'python3.15', 'python3.14', 'python3.13',
|
||||
'python3.12', 'python3.11', 'python3.10', 'python3', 'python']
|
||||
|
||||
foreach p : python_exec_list
|
||||
prog_python = find_program(p, required : false, version : python_version_req)
|
||||
if prog_python.found()
|
||||
break
|
||||
endif
|
||||
endforeach
|
||||
|
||||
if not prog_python.found()
|
||||
error('Python ' + python_version_req + ' not found')
|
||||
endif
|
||||
|
||||
has_mako = run_command(
|
||||
prog_python, '-c',
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue