android sdk not found (copy to device and launch)

HI, i 

did the 

launchctl setenv ANDROID_SDK /Users/…/android-sdk-macosx

 

and still when i click to build for Android (copy to device and launch)

i get the info window “Android SDK is not found”

 

what could it be.

 

i guess what corona looks for is the ADB, right?

i also set the path to

launchctl setenv ANDROID_SDK /Users/…/android-sdk-macosx/platform-tools

where my adb is in

 

i changed the env.path , restarted corona simulator… always the same,

what else could i do wrong?

 

thanks

chris

 

Hi, I have the same problem here.

Tested:

launchctl setenv ANDROID_SDK /Applications/android-sdk-macosx

launchctl setenv ANDROID_SDK /Applications/android-sdk-macosx/tools/

launchctl setenv ANDROID_SDK /Applications/android-sdk-macosx/platform-tools/

Best

Andreas

Hi, any news about that?
Cant be believe me and A.lepel are the only guys with that problem.

greets

chris

Hello,

I’m having the same problem. Did you find the solution? Thank you.

Pau.

My command line I run is:

launchctl setenv ANDROID_SDK /Volumes/Macintosh\ HD/Users/rmiracle/Library/Android/sdk

But it should be noted I have my Android SDK installed on a second drive. You should not, under normal circumstances need the /Volumes/Macintosh\ HD. You must run this before you run Corona SDK. If you get the dialog box telling you to do it, exit Corona SDK, run the command in the command line and start Corona SDK back up.

Rob

Hello,

Thank you for your reply but I still have the same problem.

I have Android SDK in /Users/pauors/Library/Android/sdk

I write in the Terminal the folling command line:

launchctl setenv ANDROID_SDK /Users/pauors/Library/Android/sdk

Then I start Corona Simulator and I try to make a build. I get the same dialog box. It seems pretty simple… what am I doing wrong!?

Thank you in advance!

Pau.
 

I personally use .bash_profile (create in your home directory) to handle this stuff. It allows you to never have to type in any commands to set your android sdk path again.

Here is an example: (or extract the contents of the attached zip (contains the bash profile file) into your home directory)

# PATHS export ANDROID\_SDK=~/AndroidSDK export ANDROID\_TOOLS=~/AndroidSDK/tools export ANDROID\_PLATFORM\_TOOLS=~/AndroidSDK/platform-tools PATH=${PATH}:${ANDROID\_TOOLS}:${ANDROID\_PLATFORM\_TOOLS}

I tried all

the: launchctl setenv ANDROID_SDK /Volumes/Macintosh\ HD/Users/rmiracle/Library/Android/sdk

and also danny’s bash profile.

doesnt work.

could i have to do my sdk is on my dropbox folder 

PATHS

export ANDROID_SDK= /Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

export ANDROID_TOOLS= /Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/tools/

export ANDROID_PLATFORM_TOOLS= /Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/platform-tools/

PATH=${PATH}:${ANDROID_TOOLS}:${ANDROID_PLATFORM_TOOLS}

do i need to restart my computer after settings the bash_profile?

greets

chris

@Corona

cant u guys simply do a select option , where we choose where the ADB is located?

You just need to restart the simulator/terminal

You can also use relative paths: (note the lack of spacing after the equals sign is intentional, you had spaces in yours, which you don’t want.)

# PATHS export ANDROID\_SDK=~/Dropbox/orga/SourceCodes/android/newsdk/ export ANDROID\_TOOLS=~/Dropbox/orga/SourceCodes/android/newsdk/tools/ export ANDROID\_PLATFORM\_TOOLS=~/Dropbox/orga/SourceCodes/android/newsdk/platform-tools/ PATH=${PATH}:${ANDROID\_TOOLS}:${ANDROID\_PLATFORM\_TOOLS}

Hi Danny,

I copied ur bash profile as it is into  my root.

/snowwhitesinai

or has it to be in my /macintosh HD??

restarted the Simulator… still the same… not found

also my ADB is in /tools   and also one in /platform-tools/ 

(i guess i copied once to both folders as it didnt worked… is that a prob?)

thanks for ur time

chris

also i was reading to use source ~/.bash_profile to activate it without rebooting

because when i do echo $PATH

it sill does not show the path we entered

so i did this source ~/.bash_profile and get

RbMBA:~ snowwhitesinai$ source ~/.bash_profile

-bash: export: `/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/’: not a valid identifier

-bash: export: `/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/tools/’: not a valid identifier

-bash: export: `/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/platform-tools/’: not a valid identifier

Yep that’s the right place.

It’s named “.bash_profile” right? (note the period). Should be a hidden file that you can only see when you tell finder to show hidden files.

You can do this to reload the bash_profile file in the terminal: 

. .bash\_profile

You can do this to make sure it’s working (from the terminal):

echo $ANDROID\_SDK

It should print the path to your android sdk after you hit enter.

EDIT: You’re getting those errors because you have a space after the equals sign in the paths still

Hi,

ok, i removed the spaces

and now i get

RbMBA:~ snowwhitesinai$ . .bash_profile

RbMBA:~ snowwhitesinai$ echo $ANDROID_SDK

/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

RbMBA:~ snowwhitesinai$ 

 

seems ok… and I closed/newly opened the simulator and get

===  Android SDK Not Found
=== launchctl setenv ANDROID_SDK <path-to-sdk>

 

:frowning:

 

i really dont know

Final step!

Terminal again:

launchctl setenv ANDROID\_SDK $ANDROID\_SDK

I also did now:

RbMBA:~ snowwhitesinai$ launchctl setenv ANDROID_SDK ~/Dropbox/orga/SourceCodes/android/newsdk/

RbMBA:~ snowwhitesinai$ launchctl getenv ANDROID_SDK

/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

RbMBA:~ snowwhitesinai$ 

 

and after restart the simulator… STILL NOTHING :frowning:

i did also what u wrote last

RbMBA:~ snowwhitesinai$ launchctl setenv ANDROID_SDK $ANDROID_SDK

RbMBA:~ snowwhitesinai$ launchctl getenv ANDROID_SDK

/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

 

restarted the simulator… and still the same error message :frowning:
 

 

I can’t remember if a logout is needed after doing it.

By “restart the simulator”, you mean quitting the simulator fully and re-opening it right?

yes…

i close the simulator completly and than restart

just a few more outputs

RbMBA:~ snowwhitesinai$ launchctl getenv ANDROID_SDK

/Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

RbMBA:~ snowwhitesinai$ cd /Users/snowwhitesinai/Dropbox/orga/SourceCodes/android/newsdk/

 

RbMBA:newsdk snowwhitesinai$ ls

SDK Readme.txt build-tools extras platforms sources temp

add-ons docs platform-tools samples system-images tools

 

RbMBA:newsdk snowwhitesinai$ ls tools

NOTICE.txt draw9patch jobb monkeyrunner traceview

adb emulator lib proguard uiautomatorviewer

android emulator64-arm lib64 screenshot2

ant emulator64-mips lint source.properties

apps emulator64-x86 mksdcard support

ddms hierarchyviewer monitor templates