diff options
author | Simon Sapin <simon.sapin@exyr.org> | 2017-02-05 14:45:00 +0100 |
---|---|---|
committer | Simon Sapin <simon.sapin@exyr.org> | 2017-02-05 14:45:00 +0100 |
commit | e273ecce4ca3f90d75a7b185de5e03af97da5d96 (patch) | |
tree | 3d01d5b78f9cbba7235624f8c3c247cd20efd20e | |
parent | 97cc71b661111d3c0b16b8daeb9aee675c09e237 (diff) | |
download | servo-e273ecce4ca3f90d75a7b185de5e03af97da5d96.tar.gz servo-e273ecce4ca3f90d75a7b185de5e03af97da5d96.zip |
Option configuration to enable incremental compilation.
https://internals.rust-lang.org/t/incremental-compilation-beta/4721
-rw-r--r-- | python/servo/command_base.py | 3 | ||||
-rw-r--r-- | servobuild.example | 7 |
2 files changed, 10 insertions, 0 deletions
diff --git a/python/servo/command_base.py b/python/servo/command_base.py index e80c9cb018b..8149a705014 100644 --- a/python/servo/command_base.py +++ b/python/servo/command_base.py @@ -270,6 +270,7 @@ class CommandBase(object): self.config["build"].setdefault("debug-mozjs", False) self.config["build"].setdefault("ccache", "") self.config["build"].setdefault("rustflags", "") + self.config["build"].setdefault("incremental", False) self.config.setdefault("android", {}) self.config["android"].setdefault("sdk", "") @@ -427,6 +428,8 @@ class CommandBase(object): env["PATH"] = "%s%s%s" % (os.pathsep.join(extra_path), os.pathsep, env["PATH"]) env["CARGO_HOME"] = self.config["tools"]["cargo-home-dir"] + if self.config["build"]["incremental"]: + env["CARGO_INCREMENTAL"] = "1" if extra_lib: if sys.platform == "darwin": diff --git a/servobuild.example b/servobuild.example index a037c80a863..1cf444f57aa 100644 --- a/servobuild.example +++ b/servobuild.example @@ -38,15 +38,22 @@ rustc-with-gold = true # or Set "mode = release" or use `mach build --release` for optimized build. # Defaults to prompting before building #mode = "dev" + # Set "android = true" or use `mach build --android` to build the Android app. android = false + # Set "debug-mozjs" or use `mach build --debug-mozjs` to build a debug spidermonkey. debug-mozjs = false + # Set to the path to your ccache binary to enable caching of compiler outputs #ccache = "/usr/local/bin/ccache" + # Any optional flags that will be added to $RUSTFLAGS #rustflags = "" +# Enable rustc’s incremental compilation +#incremental = false + # Android information [android] # Defaults to the value of $ANDROID_SDK, $ANDROID_NDK, $ANDROID_TOOLCHAIN, $ANDROID_PLATFORM respectively |