jonkeane commented on a change in pull request #11001:
URL: https://github.com/apache/arrow/pull/11001#discussion_r698472411
##########
File path: r/tools/nixlibs.R
##########
@@ -82,7 +91,7 @@ download_binary <- function(os = identify_os()) {
# * `TRUE` (not case-sensitive), to try to discover your current OS, or
# * some other string, presumably a related "distro-version" that has binaries
# built that work for your OS
-identify_os <- function(os = Sys.getenv("LIBARROW_BINARY",
Sys.getenv("LIBARROW_DOWNLOAD"))) {
+identify_os <- function(os = Sys.getenv("LIBARROW_BINARY",
Sys.getenv("TEST_OFFLINE_BUILD"))) {
Review comment:
If I'm following the logic here correctly, if `LIBARROW_BINARY` is
unset, this will only attempt to identify the OS when `TEST_OFFLINE_BUILD` is
`TRUE`. Is that what we want here?
##########
File path: r/R/install-arrow.R
##########
@@ -137,3 +136,64 @@ reload_arrow <- function() {
message("Please restart R to use the 'arrow' package.")
}
}
+
+
+#' Download all optional Arrow dependencies
+#'
+#' @param deps_dir Directory to save files into. Will be created if necessary.
+#' Defaults to the value of `ARROW_THIRDPARTY_DEPENDENCY_DIR`, if that
+#' environment variable is set.
+#'
+#' @return `deps_dir`, invisibly
+#'
+#' This function is used for setting up an offline build. If it's possible to
+#' download at build time, don't use this function. Instead, let `cmake`
+#' download them for you.
+#' If the files already exist in `deps_dir`, they will be re-downloaded and
+#' overwritten. Do not put other files in this directory.
+#' These saved files are only used in the build if `ARROW_DEPENDENCY_SOURCE`
+#' is `BUNDLED` or `AUTO`.
+#' https://arrow.apache.org/docs/developers/cpp/building.html#offline-builds
+#'
+#' Steps for an offline install with optional dependencies:
+#' - Install the `arrow` package on a computer with internet access
+#' - Run this function
+#' - Copy the saved dependency files to a computer without internet access
+#' - Create a environment variable called `ARROW_THIRDPARTY_DEPENDENCY_DIR`
that
+#' points to the folder.
+#' - Install the `arrow` package on the computer without internet access
+#' - Run [arrow_info()] to check installed capabilities
Review comment:
Super minor, but an attempt to clarify which steps happen on which
machines. We could also make subheadings if the parentheticals are too clunky
since it's the first two steps on one computer and the rest on the other.
```suggestion
#' - Install the `arrow` package (on a computer with internet access)
#' - Run this function (on a computer with internet access)
#' - Copy the saved dependency files to the computer without internet access
#' - Create a environment variable called `ARROW_THIRDPARTY_DEPENDENCY_DIR`
that
#' points to the folder. (on the computer without internet access)
#' - Install the `arrow` package (on the computer without internet access)
#' - Run [arrow_info()] to check installed capabilities (on the computer
without internet access)
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]