Added build steps to run_tests.py to run gyp before make
diff --git a/tools/run_tests/run_tests.py b/tools/run_tests/run_tests.py
index f82224f..de644b5 100755
--- a/tools/run_tests/run_tests.py
+++ b/tools/run_tests/run_tests.py
@@ -162,6 +162,9 @@
return ['buildtests_%s' % self.make_target]
return ['buildtests_%s' % self.make_target, 'tools_%s' % self.make_target]
+ def pre_build_steps(self):
+ return []
+
def build_steps(self):
return []
@@ -188,6 +191,9 @@
return [config.job_spec([binary], [binary])
for binary in gyp_test_paths(travis, config)]
+ def pre_build_steps(self):
+ return [['gyp', '--depth=.', 'grpc.gyp']]
+
def make_targets(self):
return gyp_test_paths(False)
@@ -206,6 +212,9 @@
return [config.job_spec(['tools/run_tests/run_node.sh'], None,
environ=_FORCE_ENVIRON_FOR_WRAPPERS)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['static_c', 'shared_c']
@@ -225,6 +234,9 @@
return [config.job_spec(['src/php/bin/run_tests.sh'], None,
environ=_FORCE_ENVIRON_FOR_WRAPPERS)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['static_c', 'shared_c']
@@ -254,6 +266,9 @@
shortname='py.test',
)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['static_c', 'grpc_python_plugin', 'shared_c']
@@ -284,6 +299,9 @@
return [config.job_spec(['tools/run_tests/run_ruby.sh'], None,
environ=_FORCE_ENVIRON_FOR_WRAPPERS)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['static_c']
@@ -315,6 +333,9 @@
environ=_FORCE_ENVIRON_FOR_WRAPPERS)
for assembly in assemblies]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
# For Windows, this target doesn't really build anything,
# everything is build by buildall script later.
@@ -342,6 +363,9 @@
return [config.job_spec(['src/objective-c/tests/run_tests.sh'], None,
environ=_FORCE_ENVIRON_FOR_WRAPPERS)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['grpc_objective_c_plugin', 'interop_server']
@@ -361,6 +385,9 @@
return [config.job_spec('tools/run_tests/run_sanity.sh', None),
config.job_spec('tools/run_tests/check_sources_and_headers.py', None)]
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['run_dep_checks']
@@ -379,6 +406,9 @@
def test_specs(self, config, travis):
return []
+ def pre_build_steps(self):
+ return []
+
def make_targets(self):
return ['static']
@@ -535,6 +565,11 @@
make_targets = list(set(itertools.chain.from_iterable(
l.make_targets() for l in languages)))
build_steps = []
+build_steps.extend(set(
+ jobset.JobSpec(cmdline, environ={'CONFIG': cfg})
+ for cfg in build_configs
+ for l in languages
+ for cmdline in l.pre_build_steps()))
if make_targets:
make_commands = itertools.chain.from_iterable(make_jobspec(cfg, make_targets) for cfg in build_configs)
build_steps.extend(set(make_commands))