From d29f0bc8fa166117e62b1fa2969dd31f415fd887 Mon Sep 17 00:00:00 2001 From: Eduard-Mihai Burtescu Date: Fri, 10 Feb 2017 22:59:40 +0200 Subject: Automatically vendor Cargo deps when building the source tarballs. --- src/bootstrap/bootstrap.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/bootstrap/bootstrap.py') diff --git a/src/bootstrap/bootstrap.py b/src/bootstrap/bootstrap.py index 27255b69100..92a075ea9dc 100644 --- a/src/bootstrap/bootstrap.py +++ b/src/bootstrap/bootstrap.py @@ -294,6 +294,8 @@ class RustBuild(object): raise Exception("no cargo executable found at `%s`" % self.cargo()) args = [self.cargo(), "build", "--manifest-path", os.path.join(self.rust_root, "src/bootstrap/Cargo.toml")] + if self.use_locked_deps: + args.append("--locked") if self.use_vendored_sources: args.append("--frozen") self.run(args, env) @@ -440,6 +442,9 @@ def main(): rb.use_vendored_sources = '\nvendor = true' in rb.config_toml or \ 'CFG_ENABLE_VENDOR' in rb.config_mk + rb.use_locked_deps = '\nlocked-deps = true' in rb.config_toml or \ + 'CFG_ENABLE_LOCKED_DEPS' in rb.config_mk + if 'SUDO_USER' in os.environ and not rb.use_vendored_sources: if os.environ.get('USER') != os.environ['SUDO_USER']: rb.use_vendored_sources = True -- cgit 1.4.1-3-g733a5