2019-06-19 12:21:10 +00:00
|
|
|
use std::env::var;
|
|
|
|
|
|
|
|
fn main() {
|
2021-06-15 21:35:16 +00:00
|
|
|
if var("CARGO_FEATURE_LOGIND").ok().is_none() && var("CARGO_FEATURE_LIBSEAT").ok().is_none() {
|
|
|
|
println!("cargo:warning=You are compiling anvil without logind/libseat support.");
|
2019-06-19 12:21:10 +00:00
|
|
|
println!("cargo:warning=This means that you'll likely need to run it as root if you want to launch it from a tty.");
|
2021-06-15 21:35:16 +00:00
|
|
|
println!("cargo:warning=To enable logind support add `--feature logind` to your cargo invocation.");
|
2019-06-19 12:21:10 +00:00
|
|
|
println!("cargo:warning=$ cd anvil; cargo run --feature logind");
|
2021-06-15 21:35:16 +00:00
|
|
|
println!("cargo:warning=To enable libseat support add `--feature libseat` to your cargo invocation.");
|
|
|
|
println!("cargo:warning=$ cd anvil; cargo run --feature libseat");
|
2019-06-19 12:21:10 +00:00
|
|
|
}
|
|
|
|
}
|