View previous topic :: View next topic |
Author |
Message |
penguin_herder n00b
Joined: 19 Jul 2018 Posts: 4
|
Posted: Thu Jul 19, 2018 12:01 pm Post subject: android studio refuses to work |
|
|
Hello
I'm trying to get Android Studio to work but it simply refuses to cooperate and I'm slowly running out of ideas.
emerge android-studio worked perfectly fine
Then I run `android-studio` from the console which brings up the first run wizard.
The first small issue is with downloading all the necessary plugins - it seems to work fine, however after everything has finished downloading the window becomes frozen, only `kill pid` helps.
After the kill, when trying to run android-studio again, the wizard shows up again, but it doesn't require me to download anything, everything goes smoothly until I get to this window and this error.
https://ibb.co/gWQCUJ
At this point I can create a new project and fiddle with the configuration, but I cannot open an existing project and therefore I cannot write anything. Even if I create a new project, all the files are created but no actual IDE comes up and every time I'm left with the same error.
Code: | java.lang.Error: Incomplete or corrupted installation - "/prebuilts/studio/jdk/linux" directory does not exist
|
It seems like a trivial error but I'm a bit lost.
Code: | andrzej@zorro ~ $ eselect java-vm list
Available Java Virtual Machines:
[1] oracle-jdk-bin-1.8 system-vm user-vm
andrzej@zorro ~ $ echo $JAVA_HOME
/home/andrzej/.gentoo/java-config-2/current-user-vm
andrzej@zorro ~ $ echo $JDK_HOME
/home/andrzej/.gentoo/java-config-2/current-user-vm
andrzej@zorro ~ $ cd .gentoo/java-config-2/
andrzej@zorro ~/.gentoo/java-config-2 $ ls -l
total 0
lrwxrwxrwx 1 andrzej andrzej 32 Jul 19 18:58 current-user-vm -> /usr/lib/jvm//oracle-jdk-bin-1.8
andrzej@zorro ~/.gentoo/java-config-2 $ cd current-user-vm/
andrzej@zorro ~/.gentoo/java-config-2/current-user-vm $ ls -l
total 20
drwxr-xr-x 2 root root 4096 May 29 15:47 bin
drwxr-xr-x 3 root root 4096 May 29 15:47 include
drwxr-xr-x 6 root root 4096 May 29 15:47 jre
drwxr-xr-x 3 root root 4096 May 29 15:47 lib
drwxr-xr-x 4 root root 4096 May 29 15:47 man
|
let me know if you need any other output
google recommended deleting jdk.table.xml file, as well as manually editing it. Neither helped.
thanks |
|
Back to top |
|
|
pilla Bodhisattva
Joined: 07 Aug 2002 Posts: 7729 Location: Underworld
|
Posted: Thu Jul 19, 2018 1:54 pm Post subject: |
|
|
Have you taken a look at the wiki entry here? It looks like there is some homework to do before installing Android Studio on Gentoo. _________________ "I'm just very selective about the reality I choose to accept." -- Calvin |
|
Back to top |
|
|
penguin_herder n00b
Joined: 19 Jul 2018 Posts: 4
|
Posted: Thu Jul 19, 2018 2:11 pm Post subject: |
|
|
I have.
I have enabled virtualisation in bios, compiled kernel with kvm-intel module, added myself to a kvm group and double checked /dev/kvm permissions.
I have also installed qemu, but from what I understand it was unnecessary as android-studio downloads it's own qemu binaries.
All these steps, as well as the troubleshooting section in the article you linked, focus on issues with emulator and virtual devices, however I can't get this far. I can't get the actual IDE working properly.
Here comes an entry from the android-studio logs
Code: | 2018-07-19 13:00:26,002 [.0_172-b11] ERROR - intellij.openapi.progress.Task - java.lang.Error: Incomplete or corrupted installation - "/prebuilts/studio/jdk/linux" directory does not exist
java.lang.RuntimeException: java.lang.Error: Incomplete or corrupted installation - "/prebuilts/studio/jdk/linux" directory does not exist
at com.intellij.openapi.application.impl.LaterInvocator.invokeAndWait(LaterInvocator.java:181)
at com.intellij.openapi.application.impl.ApplicationImpl.invokeAndWait(ApplicationImpl.java:661)
at com.android.tools.idea.ui.ApplicationUtils.invokeWriteActionAndWait(ApplicationUtils.java:39)
at com.android.tools.idea.welcome.wizard.deprecated.InstallComponentsPath$SetPreference.apply(InstallComponentsPath.java:377)
at com.android.tools.idea.welcome.wizard.deprecated.InstallComponentsPath$SetPreference.apply(InstallComponentsPath.java:364)
at com.android.tools.idea.welcome.install.InstallOperation$FunctionWrapper.perform(InstallOperation.java:182)
at com.android.tools.idea.welcome.install.InstallOperation.execute(InstallOperation.java:69)
at com.android.tools.idea.welcome.install.InstallOperation$OperationChain.perform(InstallOperation.java:156)
at com.android.tools.idea.welcome.install.InstallOperation.execute(InstallOperation.java:69)
at com.android.tools.idea.welcome.install.InstallOperation$OperationChain.perform(InstallOperation.java:154)
at com.android.tools.idea.welcome.install.InstallOperation.execute(InstallOperation.java:69)
at com.android.tools.idea.welcome.install.InstallOperation$OperationChain.perform(InstallOperation.java:154)
at com.android.tools.idea.welcome.install.InstallOperation.execute(InstallOperation.java:69)
at com.android.tools.idea.welcome.wizard.deprecated.InstallComponentsPath.runLongOperation(InstallComponentsPath.java:252)
at com.android.tools.idea.welcome.wizard.deprecated.ConsolidatedProgressStep.doLongRunningOperation(ConsolidatedProgressStep.java:78)
at com.android.tools.idea.welcome.wizard.deprecated.ConsolidatedProgressStep.access$000(ConsolidatedProgressStep.java:32)
at com.android.tools.idea.welcome.wizard.deprecated.ConsolidatedProgressStep$1.run(ConsolidatedProgressStep.java:58)
at com.android.tools.idea.welcome.wizard.deprecated.FirstRunWizardHost$LongRunningOperationWrapper.run(FirstRunWizardHost.java:440)
at com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:713)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$1(CoreProgressManager.java:157)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:543)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:488)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:94)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:144)
at com.intellij.openapi.progress.impl.ProgressManagerImpl$2.run(ProgressManagerImpl.java:165)
at com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:315)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.Error: Incomplete or corrupted installation - "/prebuilts/studio/jdk/linux" directory does not exist
at com.android.tools.idea.gradle.util.EmbeddedDistributionPaths.getSystemSpecificJdkPath(EmbeddedDistributionPaths.java:166)
at com.android.tools.idea.gradle.util.EmbeddedDistributionPaths.getEmbeddedJdkPath(EmbeddedDistributionPaths.java:157)
at com.android.tools.idea.sdk.Jdks.createEmbeddedJdk(Jdks.java:246)
at com.android.tools.idea.sdk.IdeSdks.getJdk(IdeSdks.java:523)
at com.android.tools.idea.sdk.IdeSdks.getJdk(IdeSdks.java:495)
at com.android.tools.idea.sdk.IdeSdks.createAndroidSdkPerAndroidTarget(IdeSdks.java:423)
at com.android.tools.idea.sdk.IdeSdks.setAndroidSdkPath(IdeSdks.java:314)
at com.android.tools.idea.sdk.IdeSdks.setAndroidSdkPath(IdeSdks.java:261)
at com.android.tools.idea.welcome.wizard.deprecated.InstallComponentsPath$SetPreference.lambda$apply$0(InstallComponentsPath.java:378)
at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:1003)
at com.android.tools.idea.ui.ApplicationUtils$1.run(ApplicationUtils.java:35)
at com.intellij.openapi.application.TransactionGuardImpl$2.run(TransactionGuardImpl.java:315)
at com.intellij.openapi.application.impl.LaterInvocator$1.run(LaterInvocator.java:158)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.runNextEvent(LaterInvocator.java:424)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.run(LaterInvocator.java:407)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:822)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:650)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:366)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - Android Studio 3.1.3 Build #AI-173.4819257
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - JDK: 1.8.0_172
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - VM: Java HotSpot(TM) 64-Bit Server VM
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - Vendor: Oracle Corporation
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - OS: Linux
2018-07-19 13:00:26,005 [.0_172-b11] ERROR - intellij.openapi.progress.Task - Last Action: |
|
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Thu Jul 19, 2018 3:54 pm Post subject: |
|
|
Ew that's horrible; it requires a "/prebuilts/studio/jdk/linux" path to exist on the machine, presumably with their jdk installation in binary format..
Well since it's gentoo, you are root, so I guess you could provide the path.
A nicer option might be to edit the string in the file, and make it point to a path under /usr, if you can do that. man strings comes to mind. |
|
Back to top |
|
|
depontius Advocate
Joined: 05 May 2004 Posts: 3509
|
Posted: Thu Jul 19, 2018 4:32 pm Post subject: |
|
|
I set up Android Studio years ago, before the wiki.
On the one hand, I'm not using KVM. On the other hand, I haven't used Android Studio since Cyanogenmod folded, and at that time I was building KitKat ROM images. So if requirements have changed, I may have a non-functional setup. There were instructions at the time, but I got them from Cyangenmod and translated them to Gentoo.
When I find time, maybe I can fire off another KitKat build, to see if it still works. It won't find the Cyanogenmod repositories, but my last build was after they'd already shut down, and the build still ran to completion. _________________ .sigs waste space and bandwidth |
|
Back to top |
|
|
penguin_herder n00b
Joined: 19 Jul 2018 Posts: 4
|
Posted: Fri Jul 20, 2018 2:34 am Post subject: |
|
|
is this what you reckon? literally "/prebuilts/studio/jdk/linux" must be present? I thought there was something missing in front of it, some env variable as it would be too stupid for an application to require "/prebuilts" branch straight of the root.
Anyway... it turned out that the company responsible for the IDE (not google, the one that actually made it) allows to download it's application for free if for android development. It provides essentially the same functionality as android studio, which makes sense since it's the same application. However, unlike google's android-studio, it seems to just work, so I'm gonna stick with this one.
Thanks |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Fri Jul 20, 2018 3:40 pm Post subject: |
|
|
penguin_herder wrote: | is this what you reckon? literally "/prebuilts/studio/jdk/linux" must be present? I thought there was something missing in front of it, some env variable as it would be too stupid for an application to require "/prebuilts" branch straight of the root. | Well, you could be right; it just looks like the kind of thing they'd expect on a phone(!) penguin_herder wrote: | Anyway... it turned out that the company responsible for the IDE (not google, the one that actually made it) allows to download it's application for free if for android development. It provides essentially the same functionality as android studio, which makes sense since it's the same application. However, unlike google's android-studio, it seems to just work, so I'm gonna stick with this one. | Excellent :)
At this point, it's convention to provide a url or two, for the solution you selected, so others can try it out too, and possibly discuss more. |
|
Back to top |
|
|
johngalt Apprentice
Joined: 09 Sep 2004 Posts: 258 Location: 3rd Rock
|
|
Back to top |
|
|
penguin_herder n00b
Joined: 19 Jul 2018 Posts: 4
|
Posted: Sat Jul 21, 2018 1:19 am Post subject: |
|
|
Quote: | At this point, it's convention to provide a url or two, for the solution you selected, |
my apologies, next time I'll remember to post some links as well. This time johngalt has done my work for me. |
|
Back to top |
|
|
johngalt Apprentice
Joined: 09 Sep 2004 Posts: 258 Location: 3rd Rock
|
Posted: Sat Jul 21, 2018 5:03 am Post subject: |
|
|
If you're anything like me, the minute you got it working you left the forums and started setting it up and getting your projects back in shape
So, I figured I'd lend a hand _________________
desultory wrote: | If you want to retain credibility as a functional adult; when you are told that you are acting boorishly, the correct response is to consider that possibility and act accordingly to correct that behavior. |
Amen. |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Fri Jul 27, 2018 10:47 pm Post subject: |
|
|
Nice one, cheers :-) |
|
Back to top |
|
|
Adasss n00b
Joined: 19 Mar 2005 Posts: 16
|
Posted: Thu Jan 03, 2019 6:33 pm Post subject: |
|
|
I wonder if anyone is still experiencing this problem.
I'm using Android Studio for a few months on a daily basis and I haven't seen it.
Also I've tried (for curiosity) Intellij IDEA as a replacement for Android Studio and I wouldn't advise it to anyone as such. It seems to miss too many features from Android Studio and shows too many problems (like some false warnings). |
|
Back to top |
|
|
GenieSpark n00b
Joined: 05 Jan 2019 Posts: 3
|
Posted: Sat Jan 05, 2019 7:15 pm Post subject: |
|
|
Android Studio is android targeted unlike Intellij IDEA |
|
Back to top |
|
|
willeponken n00b
Joined: 04 Apr 2019 Posts: 1
|
Posted: Thu Apr 04, 2019 4:39 pm Post subject: |
|
|
Sorry for the bump, but I got this problem after I ran:
Where icedtea-bin got removed because I had installed oracle-jdk-bin and used as user VM (where icedtea-bin was used as system VM).
So the simple fix for me was to either set oracle-jdk-bin as the system VM, too, or as I ended up with, re-emerging the icedtea-bin package. |
|
Back to top |
|
|
|