Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
google
GitHub Repository: google/crosvm
Path: blob/main/media/libvda/build.rs
5394 views
1
// Copyright 2019 The ChromiumOS Authors
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
fn main() {
6
// libvda is only avalable on chromeos build.
7
// To enable clippy checks with this feature enabled upstream we will just skip
8
// linking the library, allowing the crate to be compiled, but not linked.
9
println!("cargo:rerun-if-env-changed=CROSVM_BUILD_VARIANT");
10
if std::env::var("CROSVM_BUILD_VARIANT").unwrap_or_default() == "chromeos" {
11
pkg_config::probe_library("libvda").unwrap();
12
println!("cargo:rustc-link-lib=dylib=vda");
13
}
14
}
15
16