On Tue, May 31, 2016 at 4:51 PM, Simon Sapin <[email protected]> wrote:
>> It is possible currently to do `cargo build --features
>> net/devices/nameoffeature` without polluting cargo.tomls,
>
> I think we can have something like this in components/servo/Cargo.toml :
>
> [features]
> no-bluetooth = ["net/devices/no-bluetooth"]
FWIW, with this diff:
djc@dochtman-dev servo $ git diff
diff --git a/components/servo/Cargo.toml b/components/servo/Cargo.toml
index a0ff462..3380450 100644
--- a/components/servo/Cargo.toml
+++ b/components/servo/Cargo.toml
@@ -23,6 +23,7 @@ default = ["glutin_app", "webdriver", "max_log_level"]
max_log_level = ["log/release_max_level_info"]
webdriver = ["webdriver_server"]
energy-profiling = ["profile_traits/energy-profiling"]
+bluetooth = ["net/devices/bluetooth"]
[profile.release]
opt-level = 3
I get an error:
djc@dochtman-dev servo $ ./mach build --dev --features ""
error: Package `net v0.0.1
(file:///home/djc/src/servo/components/net)` does not have these
features: `devices`
Build completed in 0:00:00
So not sure that actually works recursively?
I think having positive features ("bluetooth") is better than having
negative features ("no-bluetooth"), so I'm checking whether I can get
that to work cleanly. It looks like cargo doesn't really support it
cleanly...
Cheers,
Dirkjan
_______________________________________________
dev-servo mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-servo