Commits

Neal Richardson authored b57b9553271
ARROW-8103: [R] Make default Linux build more minimal The status quo is that on Linux, R package installation will result in a shell package that tells you to install C++ libraries and reinstall, unless you either (1) have already installed system packages or a dev build, or (2) set an environment variable (either `LIBARROW_DOWNLOAD=true`, or `NOT_CRAN=true` also works because many R users have that set locally already), in which case installation will look for a binary to download and fall back to downloading and building C++ from source. This patch changes the default behavior when no system packages are found: instead of building without Arrow C++, it will attempt to download and build the C++ dependencies from source, with optional features (compression libraries _but not jemalloc_) turned off. Setting an environment variable `LIBARROW_MINIMAL=false` will turn on those optional features, or they can be toggled individually with cmake-flavored env vars too (e.g. `ARROW_WITH_SNAPPY=ON`). If `LIBARROW_DOWNLOAD=true` or `NOT_CRAN=true` are set, as before it will look for a binary to download, and if not found, it will build from source with `LIBARROW_MINIMAL=false`. In sum, this means that we will always be attempting to build the C++ libs from source on CRAN (and thus on everyone's Linux machines, assuming they don't already have Arrow C++ libs), as minimally as we can while still resulting in a fully functional `arrow` package. The fallback shell package that doesn't do anything should only happen if the C++ build fails for some reason, which we have found to be highly unlikely now that we've eliminated the flex and bison dependencies--having enough of a C++ toolchain for R and Rcpp is sufficient. Closes #6647 from nealrichardson/build-on-cran Authored-by: Neal Richardson <neal.p.richardson@gmail.com> Signed-off-by: Neal Richardson <neal.p.richardson@gmail.com>