aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/vs2010backend.py
diff options
context:
space:
mode:
authorNirbheek Chauhan <nirbheek@centricular.com>2017-03-25 08:07:46 +0530
committerNirbheek Chauhan <nirbheek@centricular.com>2017-03-28 00:55:01 +0530
commit27f5f0a9633b310f537f09ba0fdd79d86fcb962a (patch)
treef785006e3f80095df05d09bf3b7aa50f0def82fe /mesonbuild/backend/vs2010backend.py
parent53795d89df48ca722b018ff8720669deb6209be4 (diff)
downloadmeson-27f5f0a9633b310f537f09ba0fdd79d86fcb962a.zip
meson-27f5f0a9633b310f537f09ba0fdd79d86fcb962a.tar.gz
meson-27f5f0a9633b310f537f09ba0fdd79d86fcb962a.tar.bz2
Export MESONINTROSPECT to postconf/install/run_command scripts
Points to the `mesonintrospect.py` script corresponding to the currently-running version of Meson. Includes a test for all three methods of running scripts/commands. Closes https://github.com/mesonbuild/meson/issues/1385
Diffstat (limited to 'mesonbuild/backend/vs2010backend.py')
-rw-r--r--mesonbuild/backend/vs2010backend.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/mesonbuild/backend/vs2010backend.py b/mesonbuild/backend/vs2010backend.py
index 82c6463..5ec49ad 100644
--- a/mesonbuild/backend/vs2010backend.py
+++ b/mesonbuild/backend/vs2010backend.py
@@ -24,7 +24,7 @@ from .. import mlog
from .. import compilers
from ..build import BuildTarget
from ..compilers import CompilerArgs
-from ..mesonlib import MesonException, File
+from ..mesonlib import MesonException, File, get_meson_script
from ..environment import Environment
def split_o_flags_args(args):
@@ -379,8 +379,10 @@ class Vs2010Backend(backends.Backend):
customstep = ET.SubElement(action, 'PostBuildEvent')
cmd_raw = [target.command] + target.args
cmd = [sys.executable, os.path.join(self.environment.get_script_dir(), 'commandrunner.py'),
- self.environment.get_build_dir(), self.environment.get_source_dir(),
- self.get_target_dir(target)]
+ self.environment.get_build_dir(),
+ self.environment.get_source_dir(),
+ self.get_target_dir(target),
+ get_meson_script(self.environment, 'mesonintrospect')]
for i in cmd_raw:
if isinstance(i, build.BuildTarget):
cmd.append(os.path.join(self.environment.get_build_dir(), self.get_target_filename(i)))
@@ -1123,11 +1125,8 @@ if %%errorlevel%% neq 0 goto :VCEnd'''
postbuild = ET.SubElement(action, 'PostBuildEvent')
ET.SubElement(postbuild, 'Message')
# FIXME: No benchmarks?
- meson_py = self.environment.get_build_command()
- (base, ext) = os.path.splitext(meson_py)
- mesontest_py = base + 'test' + ext
test_command = [sys.executable,
- mesontest_py,
+ get_meson_script(self.environment, 'mesontest'),
'--no-rebuild']
if not self.environment.coredata.get_builtin_option('stdsplit'):
test_command += ['--no-stdsplit']