meson: simplify install_megadrivers.py invocation
authorEric Engestrom <eric.engestrom@intel.com>
Tue, 26 Mar 2019 10:55:37 +0000 (10:55 +0000)
committerEric Engestrom <eric.engestrom@intel.com>
Fri, 27 Dec 2019 22:43:34 +0000 (22:43 +0000)
Note: `find_program()` needs a shebang on scripts.

Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
bin/install_megadrivers.py
bin/meson.build
src/gallium/targets/dri/meson.build
src/gallium/targets/va/meson.build
src/gallium/targets/vdpau/meson.build
src/gallium/targets/xvmc/meson.build
src/mesa/drivers/dri/meson.build

index 470137e0c1dfc42d69e308c474a3c39db2f89464..0a28dd7c0c57c94c5475e8c8e4a2879a96ca502c 100644 (file)
@@ -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
index ec22e2e298971f3d0dc1d0c23c503ef6c5bcd4b4..000abef770966c4baecd0b47922f42c532a8c2cf 100644 (file)
@@ -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')
index f4645cfdcd78d84536cf135db56126d64747b6d3..954b2182ce446d1b98c571814204e0b06c76a28c 100644 (file)
@@ -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,
index 3cf68205bd5f8efd3d08ec001cdcda17d666821b..24d291c78a9f318057ddc5d67f9cb3bdfca3e04c 100644 (file)
@@ -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,
index 155d5005b44b4dc2e9ae0ebde8d721ae75eb9d02..2032fa096744de80fc17ddb74506a529f0ee6f04 100644 (file)
@@ -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,
index c107104bff295da19cde8f259bcb942f3add58f5..c1f20191b4bc2e7475e50cb81d3f0569b5c15306 100644 (file)
@@ -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,
index 1614744bdc54df1f2d39300b18ae78934fa88ac2..acf7d2eb128849bb88e828fbc36d3abcd6e5e726 100644 (file)
@@ -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,