chrisvander opened a new issue, #16843: URL: https://github.com/apache/datafusion/issues/16843
### Describe the bug [This commit](https://github.com/apache/datafusion/commit/3c4e39ac0cf83bd8ead45722a5873bac731b53f1) introduces a non-optional dependency on `zstd`, which in turn relies on `zstd-safe` and `zstd-sys`, which uses C++ compilation through the `cc` crate and requires clang. This breaks our WebAssembly build with no option to opt-out to the clang call, even if we're not using compression. We began using trunk to fix a different issue, and plan to switch back to major releases with version 49.0.0. Note that the official Rust Docker images do not include the tooling to build with Clang, either. Build failure looks like this: ``` 11.20 warning: zstd-sys@2.0.15+zstd.1.5.7: Compiler family detection failed due to error: ToolNotFound: failed to find tool "clang": No such file or directory (os error 2) 11.20 warning: zstd-sys@2.0.15+zstd.1.5.7: Compiler family detection failed due to error: ToolNotFound: failed to find tool "clang": No such file or directory (os error 2) 11.20 warning: zstd-sys@2.0.15+zstd.1.5.7: Compiler family detection failed due to error: ToolNotFound: failed to find tool "clang": No such file or directory (os error 2) 11.20 warning: zstd-sys@2.0.15+zstd.1.5.7: Compiler family detection failed due to error: ToolNotFound: failed to find tool "clang": No such file or directory (os error 2) 11.20 error: failed to run custom build command for `zstd-sys v2.0.15+zstd.1.5.7` 11.20 note: To improve backtraces for build dependencies, set the CARGO_PROFILE_RELEASE_BUILD_OVERRIDE_DEBUG=true environment variable to enable debug information generation. 11.20 11.20 Caused by: 11.20 process didn't exit successfully: `/app/target/release/build/zstd-sys-f761fb7845587b14/build-script-build` (exit status: 1) 11.20 --- stdout 11.20 cargo:rerun-if-env-changed=ZSTD_SYS_USE_PKG_CONFIG 11.20 cargo:rustc-cfg=feature="std" 11.20 cargo:rerun-if-changed=wasm-shim/stdlib.h 11.20 cargo:rerun-if-changed=wasm-shim/string.h 11.20 OUT_DIR = Some(/app/target/wasm32-unknown-unknown/release/build/zstd-sys-8eb71b94f934d217/out) 11.20 OPT_LEVEL = Some(3) 11.20 TARGET = Some(wasm32-unknown-unknown) 11.20 HOST = Some(aarch64-unknown-linux-gnu) 11.20 cargo:rerun-if-env-changed=CC_wasm32-unknown-unknown 11.20 CC_wasm32-unknown-unknown = None 11.20 cargo:rerun-if-env-changed=CC_wasm32_unknown_unknown 11.20 CC_wasm32_unknown_unknown = None 11.20 cargo:rerun-if-env-changed=TARGET_CC 11.20 TARGET_CC = None 11.20 cargo:rerun-if-env-changed=CC 11.20 CC = None 11.20 cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT 11.20 cargo:warning=Compiler family detection failed due to error: ToolNotFound: failed to find tool "clang": No such file or directory (os error 2) ``` ### To Reproduce _No response_ ### Expected behavior The recommended solution would be to put `zstd` behind a feature flag. We're careful about what dependencies we're using and, for the future, if there are any non-pure Rust dependencies that may make WebAssembly or Docker builds a problem, keep them behind feature flags. ### Additional context _No response_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org