diff --git a/meson-test-installed-bin.patch b/meson-test-installed-bin.patch new file mode 100644 index 0000000..71ffb1b --- /dev/null +++ b/meson-test-installed-bin.patch @@ -0,0 +1,32 @@ +--- a/run_tests.py ++++ b/run_tests.py +@@ -54,18 +54,10 @@ def get_meson_script(): + Also used by run_unittests.py to determine what meson to run when not + running in-process (which is the default). + ''' +- # Is there a meson.py next to the mesonbuild currently in use? +- mesonbuild_dir = Path(mesonbuild.__file__).resolve().parent.parent +- meson_script = mesonbuild_dir / 'meson.py' +- if meson_script.is_file(): +- return str(meson_script) +- # Then if mesonbuild is in PYTHONPATH, meson must be in PATH +- mlog.warning('Could not find meson.py next to the mesonbuild module. ' +- 'Trying system meson...') + meson_cmd = shutil.which('meson') +- if meson_cmd: ++ if meson_cmd and os.path.isfile(meson_cmd): + return meson_cmd +- raise RuntimeError('Could not find {!r} or a meson in PATH'.format(meson_script)) ++ raise RuntimeError('Could not find a meson in PATH') + + def get_backend_args_for_dir(backend, builddir): + ''' +@@ -244,7 +236,7 @@ if __name__ == '__main__': + env['COVERAGE_PROCESS_START'] = '.coveragerc' + env['PYTHONPATH'] = os.pathsep.join([td] + env.get('PYTHONPATH', [])) + if not cross: +- returncode += subprocess.call(mesonlib.python_command + ['run_meson_command_tests.py', '-v'], env=env) ++ #returncode += subprocess.call(mesonlib.python_command + ['run_meson_command_tests.py', '-v'], env=env) + returncode += subprocess.call(mesonlib.python_command + ['run_unittests.py', '-v'], env=env) + returncode += subprocess.call(mesonlib.python_command + ['run_project_tests.py'] + sys.argv[1:], env=env) + else: