diff options
author | Simon Sapin <simon.sapin@exyr.org> | 2019-07-01 19:25:10 +0200 |
---|---|---|
committer | Simon Sapin <simon.sapin@exyr.org> | 2019-07-02 18:29:24 +0200 |
commit | 7c85dc09b59e653caf60cb18d3b3fdea2ba4d4ae (patch) | |
tree | dd03b42a0ee6a495c1c62df9fa49ccc55dffba95 /python/servo/post_build_commands.py | |
parent | d9dbcd52c3fc0f34d2f5cd4c20aaed794946eb80 (diff) | |
download | servo-7c85dc09b59e653caf60cb18d3b3fdea2ba4d4ae.tar.gz servo-7c85dc09b59e653caf60cb18d3b3fdea2ba4d4ae.zip |
Share more `./mach build` logic with mach check, doc, test-unit
Fixes #23659
Diffstat (limited to 'python/servo/post_build_commands.py')
-rw-r--r-- | python/servo/post_build_commands.py | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/python/servo/post_build_commands.py b/python/servo/post_build_commands.py index 61a575b2db1..b9dc9b080ef 100644 --- a/python/servo/post_build_commands.py +++ b/python/servo/post_build_commands.py @@ -236,7 +236,8 @@ class PostBuildCommands(CommandBase): @CommandArgument( 'params', nargs='...', help="Command-line arguments to be passed through to cargo doc") - def doc(self, params): + @CommandBase.build_like_command_arguments + def doc(self, params, **kwargs): env = os.environ.copy() env["RUSTUP_TOOLCHAIN"] = self.toolchain() rustc_path = check_output(["rustup" + BIN_SUFFIX, "which", "rustc"], env=env) @@ -264,11 +265,7 @@ class PostBuildCommands(CommandBase): else: copy2(full_name, destination) - params += ["--features", "canvas2d-azure"] - - returncode = self.call_rustup_run( - ["cargo", "doc", "--manifest-path", self.ports_glutin_manifest()] + params, - env=self.build_env()) + returncode = self.run_cargo_build_like_command("doc", params, **kwargs) if returncode: return returncode |