'How can I install tidyverse on Archlinux?

I'm running since a few days archlinux and installed R-Studio today. I'm not able to install the tidyverse packages.

Error in library(tidyverse) : there is no package called ‘tidyverse’
Calls: .First -> library
Execution halted
Warning in install.packages :
  installation of package ‘tidyverse’ had non-zero exit status

I found a few solutions for Ubuntu or Debian, but no solution for archlinux.

I's seems that you need for Ubuntu or Debian libxml2-dev libcurl4-openssl-dev libssl-dev but I can't find em for archlinux.

I hope someone can help me.



Solution 1:[1]

Arch linux does not separate the dev packages. Hence, you can install the libraries directly, using:

yay -S ibxml2 libcurl4-openssl libssl 

Solution 2:[2]

Okey, I found a solution for this specific Problem. I just started r-studio as sudo and was able to install "tidyverse".

I still have problems to install other packages that cant be solved with running as sudo for example psych. I'm not sure which libs are missing.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 felipecrp
Solution 2 alex