title: R error: installation of package had non-zero exit status
body: <p>I've set up a daily R script to update all packages automatically:</p>
  
  <pre><code>## ---- Automatically update all packages and their dependencies -------
      options(install.packages.compile.from.source = "always")
      options(repos = c(CRAN = "http://cran.rstudio.com"))
      update.packages(ask = FALSE, dependencies = TRUE)
  </code></pre>
  
  <p>However I'm getting the following warnings when the script ends:</p>
  
  <pre><code>Warning messages:
  1: In install.packages(update[instlib == l, "Package"], l, contriburl = contriburl,  :
    installation of package ‘agricolae’ had non-zero exit status
  2: In install.packages(update[instlib == l, "Package"], l, contriburl = contriburl,  :
    installation of package ‘brms’ had non-zero exit status
  3: In install.packages(update[instlib == l, "Package"], l, contriburl = contriburl,  :
    installation of package ‘gstat’ had non-zero exit status
  </code></pre>
  
  <p>Is there anything I can add/adapt in the code to fix those warnings?
  My sessioninfo() is:
      R version 3.6.2 (2019-12-12)
      Platform: x86_64-w64-mingw32/x64 (64-bit)
      Running under: Windows Server x64 (build 14393)</p>
  
  <pre><code>Matrix products: default
  
  locale:
  [1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252    LC_MONETARY=English_United States.1252 LC_NUMERIC=C                          
  [5] LC_TIME=English_United States.1252    
  
  attached base packages:
  [1] stats     graphics  grDevices utils     datasets  methods   base     
  
  loaded via a namespace (and not attached):
  [1] compiler_3.6.2 tools_3.6.2
  </code></pre>