2

On Windows 7 64-bit, running Eclipse 3.6 64-bit, JDK (jdk1.6.0_23) 64-bit and Android 2.3 (bitness?), running a program via Eclipse's Run|Run (Ctrl+F11) invokes the android emulator, but won't install .apk on the emulator (and certainly won't run it).

(update, answering @Computerish's question) All I am getting at Eclipse's Console is:

[2010-12-16 10:23:33 - HelloAndroid] ------------------------------
[2010-12-16 10:23:33 - HelloAndroid] Android Launch!
[2010-12-16 10:23:33 - HelloAndroid] adb is running normally.
[2010-12-16 10:23:33 - HelloAndroid] Performing com.example.helloandroid.HelloAndroid activity launch
[2010-12-16 10:23:33 - HelloAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'AVD23'
[2010-12-16 10:23:33 - HelloAndroid] Launching a new emulator with Virtual Device 'AVD23'

This problem doesn't happen on Windows XP, running Eclipse 3.5.2 and Android 2.2 (all 32-bit).

I tried the solution suggested by the accepted answer in this thread but it didn't help. Task manager shows adb's Image Name as 'adb.exe *32'. Perhaps there is a mismatch between the bitness of Eclipse+JDK (64-bit) and the Android emulator/SDK?

Is Android development using 64-bit JDK not possible (yet)?

Community
  • 1
  • 1
Android Eve
  • 14,864
  • 26
  • 71
  • 96
  • 1
    What folder did you install Eclipse in? I use 64 bit eclipse with Android + JDK – Galip Dec 16 '10 at 14:23
  • Eclipse is in C:\eclipse, JDK is in C:\Program Files\Java\jdk1.6.0_23, Android is in C:\android-sdk-windows. @Galip, is your JDK 64-bit? Do you have happen to have the 32-bit JDK installed, too? – Android Eve Dec 16 '10 at 14:39
  • Android 2.3 is very new. Have you tried using a 2.2 emulator? Are you getting any LogCat or console output? – Computerish Dec 16 '10 at 14:39
  • @Computerish, right now I am only interested in Android 2.3. I wonder if there anyone who managed to have the above configuration work. – Android Eve Dec 16 '10 at 14:43
  • @Android Eve I have the 32-bit JDK. Do you get something when you type "adb" in command prompt? – Galip Dec 16 '10 at 14:52
  • @Galip, if I type 'adb' from anywhere, it's not found. If I type 'adb' from C:\android-sdk-windows\platform-tools, I receive default help output, preceded by the version info: 'Android Debug Bridge version 1.0.26'. – Android Eve Dec 16 '10 at 15:01
  • @Computerish, answering your your 2nd question: Yes, I am getting the console output (see update above, in the original post). – Android Eve Dec 16 '10 at 15:25
  • Have you tried to push the APK to the device manually? Not saying this is an acceptable answer, but it could help you determine the cause. – Dan Dec 16 '10 at 16:31

4 Answers4

5

OK, here is the final answer (as of today): Android development, using 64-bit JDK only, is not possible (yet).

If you install the 64-bit Eclipse and install only the 32-bit JDK, Eclipse will refuse to start.

So, if you decided to install the 64-bit Eclipse, you need to install both the 64-bit JDK and the 32-bit JDK.

Thereafter, even the infamous installer_r08-windows.exe will run (and even invoke "SDK Manager.exe" automatically for you).

But 64-bit Eclipse still won't install .apk on Android emulator.

Conclusion: Google is absolutely correct in stating that Android is not supported (yet) under 64-bit Windows. The fact that some geniuses manages to do some magic to make their environment work is beyond me.

Android Eve
  • 14,864
  • 26
  • 71
  • 96
1

I know this might be late, but I found a fix for it.

I'm running:

-64-bit Windows 7

-64-bit Java 1.7 SDK

-64-bit Eclipse for Java Developers + ADT Plugin

-64-bit Android SDK

So what I do is save my java source files, and run the application through Eclipse. I close the emulator after it fully loads to the home screen. Next, I go to my command prompt in Win7 and type emulator -verbose -avd youravdname. After you press enter, Eclipse will decide to upload and install the .apk file onto the emulator. Now you can see your new activities!

It's very cumbersome, and I wonder why this even works. I seriously spent hours wondering if I even installed everything correctly.

StealthE
  • 11
  • 1
1

I suppose that 32-bit ADB waits for 32-bit JDK. Just install 32-bit JDK - and everything should work after that. i'm running Android SDK on 64 bit machine with both installed JDK's 32 and 64 bits - and everything is OK

Barmaley
  • 16,638
  • 18
  • 73
  • 146
  • thanks and +1 for your suggestion. Installing 32-bit JDK is an easy solution... I am looking for the difficult solution. ;-) – Android Eve Dec 16 '10 at 14:44
  • I gave up on the difficult solution as it seems non-existent. So I tried, installing the 32-bit JDK and this thing still doesn't work. So I uninstalled the 64-bit JDK and now Eclipse fails to run, complaining that "Failed to load the JNI shared library "C:\Program Files (x86)\Java\jdk1.6.0_23.bin\..\jre\bin\client\jvm.dll". Strange, since that file is there, in that exact path. What's going on? – Android Eve Dec 17 '10 at 21:48
  • You must be running the 32-bit Eclipse and/or an older version of the Android SDK, if "everything works after that" as you described. – Android Eve Dec 21 '10 at 12:45
0

I had the same problem as the original poster and I'm also using Android SDK 2.3, Eclipse Helios, JDK 1.6.0_23 64-bit on Windows 7 Professional 64-bit.

However, once I've killed the adb.exe *32 process and then restarted eclipse and then tried running HelloAndroid app again, the emulator started successfully, the app *.apk was loaded and ran perfectly.

I didn't do anything else and I haven't installed JDK 32-bit on my machine.

tsaixingwei
  • 636
  • 9
  • 13