unable to install android-studio - error in studio.sh

Heyho,

i followed these instructions to install android-studio Android Studio Installation Guide, but got the following error when start studio.sh:

No protocol specified

Start Failed: Failed to initialize graphics environment

java.awt.AWTError: Can't connect to X11 window server using ':0' as the value of the DISPLAY variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at sun.awt.X11GraphicsEnvironment.access$200(X11GraphicsEnvironment.java:65)
at sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:115)
at java.security.AccessController.doPrivileged(Native Method)
at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:74)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:103)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:82)
at sun.awt.X11.XToolkit.(XToolkit.java:128)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at java.awt.Toolkit$2.run(Toolkit.java:860)
at java.awt.Toolkit$2.run(Toolkit.java:855)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:854)
at com.intellij.ui.AppUIUtil.updateFrameClass(AppUIUtil.java:161)
at com.intellij.idea.StartupUtil.prepareAndStart(StartupUtil.java:100)
at com.intellij.idea.MainImpl.start(MainImpl.java:20)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.intellij.ide.plugins.PluginManager.lambda$start$0(PluginManager.java:76)
at java.lang.Thread.run(Thread.java:745)

Does anybody know, what to do?

Better use the AUR package. The tutorial was written quite some time ago and updated for small modifications, yet it might need another update.
https://aur.archlinux.org/packages/android-studio
Depending on what DE you are using, you might need an AUR helper for that, or use the Pamac build command.
sudo pacman -S trizen base-devel
then
trizen -S android-studio

Hello,

Please provide more info: Dump your inxi -Fxzc0 here and bookmark it

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.