crosvm/gpu_display
Daniel Verkamp 583a2963d3 gpu_display: rework build.rs for cross compilation
The #[cfg(unix)] and #[cfg(windows)] checks in build.rs are testing
properties of the build system, not the target system, which is
inappropriate for cross compilation scenarios. This will matter when
cross compiling from Linux for Windows, as an example.

Use the appropriate Cargo environment variables to test target
properties instead:
https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-build-scripts

BUG=None
TEST=cargo build
TEST=tools/run_tests --target=host --build-target=mingw64 --build-only

Change-Id: If1ac479ae519fe69168cead68b9ee44bac56f851
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3840955
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Dennis Kempin <denniskempin@google.com>
2022-08-19 22:43:07 +00:00
..
examples Reformat imports 2022-07-28 00:15:50 +00:00
protocol health-check: Add check for newline at ends of files 2022-08-18 00:17:04 +00:00
src health-check: Add check for newline at ends of files 2022-08-18 00:17:04 +00:00
build.rs gpu_display: rework build.rs for cross compilation 2022-08-19 22:43:07 +00:00
Cargo.toml devices: enable tests 2022-06-23 00:26:06 +00:00