Tidyverse install error

Mac OS 10.13.6
R 3.3.3
RStudio 1.0.136

Tried to install tidyverse, but failed several times.
Can anyone help me?

====

> install.packages("tidyverse")
also installing the dependencies ‘ps’, ‘processx’, ‘fansi’, ‘rlang’, ‘callr’, ‘pillar’, ‘dbplyr’, ‘modelr’, ‘reprex’, ‘tibble’, ‘tidyr’


  There are binary versions available but the source versions are later:
           binary source needs_compilation
processx  2.0.0.1  3.2.0              TRUE
rlang       0.1.6  0.2.2              TRUE
callr       1.0.0  3.0.0             FALSE
pillar      1.0.1  1.3.0             FALSE
dbplyr      1.1.0  1.2.2             FALSE
modelr      0.1.1  0.1.2             FALSE
tibble      1.3.4  1.4.2              TRUE
tidyr       0.7.2  0.8.1              TRUE
tidyverse   1.1.1  1.2.1             FALSE

Do you want to install from sources the packages which need compilation?
y/n: y
Packages which are only available in source form, and may need compilation of C/C++/Fortran: ‘ps’
  ‘fansi’
Do you want to attempt to install these from sources?
y/n: y
installing the source packages ‘ps’, ‘processx’, ‘fansi’, ‘rlang’, ‘callr’, ‘pillar’, ‘dbplyr’, ‘modelr’, ‘reprex’, ‘tibble’, ‘tidyr’, ‘tidyverse’

trying URL '(omitted)'
Content type 'application/x-gzip' length 242390 bytes (236 KB)
==================================================
downloaded 236 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 97959 bytes (95 KB)
==================================================
downloaded 95 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 243661 bytes (237 KB)
==================================================
downloaded 237 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 325128 bytes (317 KB)
==================================================
downloaded 317 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 36365 bytes (35 KB)
==================================================
downloaded 35 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 103104 bytes (100 KB)
==================================================
downloaded 100 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 263687 bytes (257 KB)
==================================================
downloaded 257 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 118432 bytes (115 KB)
==================================================
downloaded 115 KB

trying URL ''(omitted)''
Content type 'application/x-gzip' length 357008 bytes (348 KB)
==================================================
downloaded 348 KB

trying URL '(omitted)'
Content type 'application/x-gzip' length 109808 bytes (107 KB)
==================================================
downloaded 107 KB

trying URL '(omitted)'
Content type 'application/x-gzip' length 377859 bytes (369 KB)
==================================================
downloaded 369 KB

trying URL '(omitted)'
Content type 'application/x-gzip' length 61647 bytes (60 KB)
==================================================
downloaded 60 KB

Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
* installing *source* package ‘ps’ ...
** package ‘ps’ successfully unpacked and MD5 sums checked
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘ps’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/ps’
Warning in install.packages :
  installation of package ‘ps’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
* installing *source* package ‘fansi’ ...
** package ‘fansi’ successfully unpacked and MD5 sums checked
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘fansi’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/fansi’
Warning in install.packages :
  installation of package ‘fansi’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
* installing *source* package ‘rlang’ ...
** package ‘rlang’ successfully unpacked and MD5 sums checked
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘rlang’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/rlang’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/rlang’
Warning in install.packages :
  installation of package ‘rlang’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘ps’ is not available for package ‘processx’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/processx’
Warning in install.packages :
  installation of package ‘processx’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘fansi’ is not available for package ‘pillar’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/pillar’
Warning in install.packages :
  installation of package ‘pillar’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘processx’ is not available for package ‘callr’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/callr’
Warning in install.packages :
  installation of package ‘callr’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘pillar’ is not available for package ‘tibble’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/tibble’
Warning in install.packages :
  installation of package ‘tibble’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘tibble’ is not available for package ‘dbplyr’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/dbplyr’
Warning in install.packages :
  installation of package ‘dbplyr’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘callr’ is not available for package ‘reprex’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/reprex’
Warning in install.packages :
  installation of package ‘reprex’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependency ‘tibble’ is not available for package ‘tidyr’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/tidyr’
Warning in install.packages :
  installation of package ‘tidyr’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependencies ‘tibble’, ‘tidyr’ are not available for package ‘modelr’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/modelr’
Warning in install.packages :
  installation of package ‘modelr’ had non-zero exit status
Warning in strptime(xx, f <- "%Y-%m-%d %H:%M:%OS", tz = tz) :
  unknown timezone 'zone/tz/2018e.1.0/zoneinfo/America/Los_Angeles'
ERROR: dependencies ‘dbplyr’, ‘modelr’, ‘reprex’, ‘tibble’, ‘tidyr’ are not available for package ‘tidyverse’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/tidyverse’
Warning in install.packages :
  installation of package ‘tidyverse’ had non-zero exit status

The downloaded source packages are in
	‘/private/var/folders/vj/_7m7f4jx1hv6q976wc7v7s240000gn/T/RtmpF7ZWry/downloaded_packages’

The xcrun error often means you have to update Xtools on your machine:

3 Likes