0

I have just put the first step in android,and just started with hello android example of android http://developer.android.com/guide/tutorials/hello-world.html. Now the problem is that when i navigate to /tools directory and execute the command android create avd --target 2 --name my_avd ,it gives error like :

mac123:android-sdk-mac_86 mac1$ android create avd --target 2 --name my_av -bash: android: command not found

Please mark that i am working with mac OS. Also is it any other way possible for the installation of the android SDK.

Kindly help me out.

Thank you.

Vladimir Ivanov
  • 42,730
  • 18
  • 77
  • 103
Yama
  • 2,649
  • 3
  • 31
  • 63

1 Answers1

1

I'm not sure know about mac os, but usually in unix-like systems the current directory is not in the PATH environment variable (a variable that tells your shell where to find executables). So to execute a command in your current directory you have to prepend ./:

$ cd [android_sdk_dir]/tools
$ ./android create adv [...]

anyway consider beginning with eclipse, it eases a lot of tasks.

bigstones
  • 15,087
  • 7
  • 65
  • 82
  • I tried to follow the path window -> Android SDK and AVD Manager in eclipse, but it is giving me error of no location found.So can't help myself. Any other way around? – Yama Dec 17 '10 at 12:55
  • 1
    @Sarah probably you're missing a step in SDK configuration: http://developer.android.com/sdk/eclipse-adt.html#configuring – bigstones Dec 17 '10 at 16:41
  • ya,I got the problem. I didn't follow the step to add the location through Eclipse->preference->android->sdk location. – Yama Dec 18 '10 at 07:00