google / shaderc-rs

Rust bindings for the shaderc library.
https://docs.rs/shaderc
Apache License 2.0
261 stars 64 forks source link

Don't try to build shaderc native library when building for docs.rs #130

Closed chyyran closed 1 year ago

chyyran commented 1 year ago

This fixes Windows cross-compile builds for crates that depend on shaderc-rs.

example failed build: https://docs.rs/crate/librashader/0.1.0-beta.3/builds/721331

When the DOCS_RS environment variable is found don't even bother to build the native library since it is only needed for docs. It also saves time for Linux docs.rs builds that really have no need to link to the native library either.

google-cla[bot] commented 1 year ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

chyyran commented 1 year ago

CLA signed @googlebot