x


Android Build Problems With Platform(s)

The last 2 weeks I've been having problem with my unity3d, I can't build any project when I got it in Android Platform, I just get this annoying error messages:

Android SDK does not include any platforms! Did you run Android SDK setup to install the platform(s)? Minimum platform required for build is Android 2.3 (API level 9)

I got the SDK installed but I still keep getting this messages... When I try to build an apk file they want me to select the android sdk root folder so I do but when I've selected it it just finish loading and opens my home directory ( D:UsersAxel ) and no apk file have been created.

As I said, I got the sdk installed - I've re installed unity 3.4 x2 times - but I keep getting the same problem.

Anyone might have an solution?

more ▼

asked Oct 09 '11 at 11:04 AM

svettgunnar gravatar image

svettgunnar
16 14 18 20

(comments are locked)
10|3000 characters needed characters left

2 answers: sort oldest

First: Don't reply to yourself if it's NO ANSWER! Use COMMENTS

Second: There are only two places which contain a AndroidSdkRoot key. To edit it...

  1. Hit either "Start > run" or "Win key + R" and type "regedit.exe" and execute it
  2. UAC (Vista, Seven) may ask for Admin permissions. Grant it.
  3. Navigate to HKEY_CURRENT_USERSoftwareUnity TechnologiesUnity Editor 3.xAndroidSdkKey
  4. Double-click on it and enter E:/SDKs/android-sdk-windows (don't choose any of it's subfolders!) or whatever your path to the android sdk is
  5. The second place is on HKEY_USERSS-1-5-21-3119377287-2067305244-3537782073-1000SoftwareUnity TechnologiesUnity Editor 3.xAndroidSdkRoot. Repeat step 4.

That's all. But basically, the Unity3d should be doing the same if you set it via Preferences! If it doesn't work, you may want to uninstall your SDK and reinstall it yourself (Try to avoid installing it in C:Program Files or C:Program Files (x86), as this is quite a pain and the SDKManager fucks around if not manually run as Administrator. You can avoid this if you install it on D: or E:).

And only install SDKS 2.1, 2.2, 2.3, 2.3.3! Don't install 1.x or 3.x SDKs, they cause serious problems while building APK file (it hands while looking for the SDK, until you kill java.exe in TaskManager)

more ▼

answered Oct 09 '11 at 12:25 PM

Tseng gravatar image

Tseng
1.5k 6 8 23

Small warning- messing around with the registry is pretty dangerous and can turn your computer into a toaster oven if you don't know what you're doing. Make sure there isn't another way before you go messing with that stuff!

Oct 09 '11 at 12:34 PM syclamoth

I've reinstalled the sdk manager several times before and i've had the same problem but do you believe it might work if I skip installing everything but 2.1 - 2.3.3 and in another partion?

Oct 09 '11 at 12:45 PM svettgunnar

@syclamoth: In general this is true, in this case you're just editing the value which the Unity Editor would/should do itself. So unless he changes other stuff than the one suggested above, there is no way in breaking something

@svettgunnar: You might try it. When I first bought the Android Basic License, I had problems compiling (it always stuck at "Searching for Android SDK..." screen) until I uninstalled all versions prior to 2.1 (1.1, 1.5, 1.6, 2.0, 2.0.1) and 3.x versions

Oct 09 '11 at 03:24 PM Tseng

There's NO SDK key in regedit...

Sep 28 '12 at 06:10 PM Arpian

Not working for me. :-(

Mar 26 at 10:26 AM gdebojyoti
(comments are locked)
10|3000 characters needed characters left

Hmm, I found an answer when I was searching for this but I kinda have no idea what to do...

I finally resolved this issue tonight.

In short, the AndroidSdkRoot value in the registry was not set to the actual path of the SDK - it was empty. I was kinda clued into this because Unity3D would open my home directory in Explorer. Once I set it, things seem to come together.

Not sure why this value got out of whack on one system, but I had updated from several beta into release versions.

I hope this solution is useful to others.

Where can I find the registry he's speaking about?

more ▼

answered Oct 09 '11 at 11:45 AM

svettgunnar gravatar image

svettgunnar
16 14 18 20

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2488
x668
x663
x147
x67

asked: Oct 09 '11 at 11:04 AM

Seen: 5112 times

Last Updated: Mar 26 at 10:26 AM