diff options
Diffstat (limited to 'cli/build.rs')
-rw-r--r-- | cli/build.rs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/cli/build.rs b/cli/build.rs new file mode 100644 index 000000000..4d50d8a5f --- /dev/null +++ b/cli/build.rs @@ -0,0 +1,20 @@ +// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license. +// Run "cargo build -vv" if you want to see gn output. +mod gn { + include!("../gn.rs"); +} + +fn main() { + let build = gn::Build::setup(); + + let gn_target = if build.check_only { + // When RLS is running "cargo check" to analyze the source code, we're not + // trying to build a working executable, rather we're just compiling all + // rust code. Therefore, make ninja build only 'msg_generated.rs'. + "cli:msg_rs" + } else { + "cli:deno_deps" + }; + + build.run(gn_target); +} |