Installation of RStudio impossible in Ubuntu 19.04 - Dependency issue

@Cleophee Welcome! That is a super frustrating error.

Don't be discouraged because there is no "very easy solution" to this. Each Ubuntu release has different default versions of system libraries, which can make it difficult to install RStudio. For this reason, the RStudio team only supports the LTS releases. Since you are attempting to use the binary built for Ubuntu Bionic (18.04), this will require some troubleshooting.

I did some investigating, and here are my thoughts/suggestions.

I was able to build RStudio in the Docker image ubuntu:19.04 using the following steps:

apt update && apt upgrade -y
export DEBIAN_FRONTEND=noninteractive
apt install -y \
  gdebi r-base wget
wget https://download1.rstudio.org/desktop/bionic/amd64/rstudio-1.2.1335-amd64.deb
gdebi rstudio-1.2.1335-amd64.deb

Did you follow a similar strategy?

And even though it successfully installed, I received error message when running rstudio --help. Following the advice in Installation error: cannot find libsmime3.so - #3 by kevinushey and Qt platform plugin not found at startup with RPM on CentOS 7 · Issue #4610 · rstudio/rstudio · GitHub, I was able to install the missing libraries with:

apt install -y \
  libasound2 \
  libnss3 \
  libegl1-mesa \
  libxkbcommon-x11-0 \
  libgl1-mesa-glx \
  libxtst6

However, I still got a Qt error, but this was likely due to missing X11 libraries in the Docker image (i.e. this shouldn't affect your Ubuntu Dekstop installation):

rstudio --help
qt.qpa.xcb: could not connect to display 
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, xcb.

Aborted (core dumped)

Another guess for your issue is that you have a separate package installed that depends on a different versions of libclang-8-dev. You can view reverse dependencies with apt-cache rdepends. For example, in the Docker container, the only package that depends on libclang-8-dev and libclang-dev is RStudio.

$ apt-cache rdepends --recurse --installed libclang-8-dev
libclang-8-dev
Reverse Depends:
  libclang-dev
libclang-dev
Reverse Depends:
  rstudio
rstudio
Reverse Depends:

When you run the above on your machine, do you find other installed pacakges?