diff --git a/R/load.R b/R/load.R index a32df207..f65eb79a 100644 --- a/R/load.R +++ b/R/load.R @@ -64,6 +64,16 @@ #' behavior when loading an installed package with [library()], and can #' be useful for checking for missing exports. #' +#' # Controlling the debug compiler flags +#' +#' `load_all()` delegates to [pkgbuild::compile_dll()] to perform the actual +#' compilation, during which by default some debug compiler flags are +#' appended. If you would like to produce an optimized build instead, +#' you can opt out by setting the `pkg.build_extra_flags` +#' option or the `PKG_BUILD_EXTRA_FLAGS` environment variable to `FALSE`. +#' For further details see the Details section in [pkgbuild::compile_dll()]. +#' +#' #' @param path Path to a package, or within a package. #' @param reset `r lifecycle::badge("deprecated")` This is no longer supported #' because preserving the namespace requires unlocking its environment, which @@ -122,7 +132,7 @@ load_all <- function(path = ".", warn_conflicts = TRUE) { if (!isTRUE(reset)) { lifecycle::deprecate_warn( - when = "1.3.5", + when = "1.3.5", what = "load_all(reset)", details = "`reset = FALSE` is no longer supported." ) diff --git a/man/load_all.Rd b/man/load_all.Rd index 2c2c7bf2..6c76c6c2 100644 --- a/man/load_all.Rd +++ b/man/load_all.Rd @@ -124,6 +124,15 @@ be useful for checking for missing exports. } } +\section{Controlling the debug compiler flags}{ +\code{load_all()} delegates to \code{\link[pkgbuild:compile_dll]{pkgbuild::compile_dll()}} to perform the actual +compilation, during which by default some debug compiler flags are +appended. If you would like to produce an optimized build instead, +you can opt out by setting the \code{pkg.build_extra_flags} +option or the \code{PKG_BUILD_EXTRA_FLAGS} environment variable to \code{FALSE}. +For further details see the Details section in \code{\link[pkgbuild:compile_dll]{pkgbuild::compile_dll()}}. +} + \examples{ \dontrun{ # Load the package in the current directory