From dcba7731e6056b6cad03064f90a97cf206e68a75 Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Tue, 26 Mar 2019 10:55:37 +0000 Subject: [PATCH] meson: simplify install_megadrivers.py invocation Note: `find_program()` needs a shebang on scripts. Signed-off-by: Eric Engestrom Reviewed-by: Dylan Baker --- bin/install_megadrivers.py | 3 ++- bin/meson.build | 1 + src/gallium/targets/dri/meson.build | 3 +-- src/gallium/targets/va/meson.build | 3 +-- src/gallium/targets/vdpau/meson.build | 3 +-- src/gallium/targets/xvmc/meson.build | 3 +-- src/mesa/drivers/dri/meson.build | 3 +-- 7 files changed, 8 insertions(+), 11 deletions(-) diff --git a/bin/install_megadrivers.py b/bin/install_megadrivers.py index 470137e0c1d..0a28dd7c0c5 100644 --- a/bin/install_megadrivers.py +++ b/bin/install_megadrivers.py @@ -1,5 +1,6 @@ +#!/usr/bin/env python3 # encoding=utf-8 -# Copyright © 2017-2018 Intel Corporation +# Copyright 2017-2018 Intel Corporation # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal diff --git a/bin/meson.build b/bin/meson.build index ec22e2e2989..000abef7709 100644 --- a/bin/meson.build +++ b/bin/meson.build @@ -20,3 +20,4 @@ git_sha1_gen_py = files('git_sha1_gen.py') symbols_check = find_program('symbols-check.py') +install_megadrivers_py = find_program('install_megadrivers.py') diff --git a/src/gallium/targets/dri/meson.build b/src/gallium/targets/dri/meson.build index f4645cfdcd7..954b2182ce4 100644 --- a/src/gallium/targets/dri/meson.build +++ b/src/gallium/targets/dri/meson.build @@ -110,8 +110,7 @@ foreach d : [[with_gallium_kmsro, [ endforeach meson.add_install_script( - prog_python.path(), - join_paths(meson.source_root(), 'bin/install_megadrivers.py'), + install_megadrivers_py.path(), libgallium_dri.full_path(), dri_drivers_path, gallium_dri_drivers, diff --git a/src/gallium/targets/va/meson.build b/src/gallium/targets/va/meson.build index 3cf68205bd5..24d291c78a9 100644 --- a/src/gallium/targets/va/meson.build +++ b/src/gallium/targets/va/meson.build @@ -65,8 +65,7 @@ foreach d : [[with_gallium_r600, 'r600'], endforeach meson.add_install_script( - prog_python.path(), - join_paths(meson.source_root(), 'bin/install_megadrivers.py'), + install_megadrivers_py.path(), libva_gallium.full_path(), va_drivers_path, va_drivers, diff --git a/src/gallium/targets/vdpau/meson.build b/src/gallium/targets/vdpau/meson.build index 155d5005b44..2032fa09674 100644 --- a/src/gallium/targets/vdpau/meson.build +++ b/src/gallium/targets/vdpau/meson.build @@ -71,8 +71,7 @@ foreach d : [[with_gallium_r300, 'r300'], endforeach meson.add_install_script( - prog_python.path(), - join_paths(meson.source_root(), 'bin/install_megadrivers.py'), + install_megadrivers_py.path(), libvdpau_gallium.full_path(), vdpau_drivers_path, vdpau_drivers, diff --git a/src/gallium/targets/xvmc/meson.build b/src/gallium/targets/xvmc/meson.build index c107104bff2..c1f20191b4b 100644 --- a/src/gallium/targets/xvmc/meson.build +++ b/src/gallium/targets/xvmc/meson.build @@ -60,8 +60,7 @@ foreach d : [[with_gallium_r600, 'r600'], [with_gallium_nouveau, 'nouveau']] endforeach meson.add_install_script( - prog_python.path(), - join_paths(meson.source_root(), 'bin/install_megadrivers.py'), + install_megadrivers_py.path(), libxvmc_gallium.full_path(), xvmc_drivers_path, xvmc_drivers, diff --git a/src/mesa/drivers/dri/meson.build b/src/mesa/drivers/dri/meson.build index 1614744bdc5..acf7d2eb128 100644 --- a/src/mesa/drivers/dri/meson.build +++ b/src/mesa/drivers/dri/meson.build @@ -74,8 +74,7 @@ if _dri_drivers != [] ) meson.add_install_script( - prog_python.path(), - join_paths(meson.source_root(), 'bin/install_megadrivers.py'), + install_megadrivers_py.path(), libmesa_dri_drivers.full_path(), dri_drivers_path, _dri_link, -- 2.30.2