diff --git a/ep/build-velox/src/build-velox.sh b/ep/build-velox/src/build-velox.sh index 31109ed919..3e279bf680 100755 --- a/ep/build-velox/src/build-velox.sh +++ b/ep/build-velox/src/build-velox.sh @@ -115,9 +115,12 @@ function compile { if [[ "$(uname)" == "Darwin" ]]; then CXX_FLAGS="$CXX_FLAGS -Wno-inconsistent-missing-override -Wno-macro-redefined" if [[ -n "${INSTALL_PREFIX:-}" && "${INSTALL_PREFIX:-}" != "/usr/local" && "${INSTALL_PREFIX:-}" != /usr/local/* ]]; then - # Some prefix-installed deps only publish loose headers (e.g. xsimd), so - # keep the prefix include dir on the compiler command line. - CXX_FLAGS="$CXX_FLAGS -I${INSTALL_PREFIX}/include" + # Add the dependency prefix as a system include: this finds deps that only + # publish loose headers (e.g. xsimd) and demotes warnings in vendored + # dependency headers (abseil's __is_trivially_relocatable, arrow's vendored + # date.h literal operators) to non-fatal system-header warnings under + # -Werror on recent clang. + CXX_FLAGS="$CXX_FLAGS -isystem ${INSTALL_PREFIX}/include" fi fi