Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is android_sdk_root? and how do I set it.?

Tags:

android

I set the android_sdk_home variable so that my application could find .android when trying to run. Now I get an error stating that "android_sdk_root is undefined". I am running win 7 with a new installation of Android Studio, inside parallels on a macbook pro.

Thank you for your response. I checked the location and it is identified as the same location as the ANDROID_SDK_HOME environment path. It still says root is undefined. I created an ANDROID_SDK_ROOT enviroment path to the same location and it is still undefined.

like image 692
Reed Vergin Avatar asked Apr 01 '15 13:04

Reed Vergin


1 Answers

This is how I did it on macOS:

vim ~/.bash_profile  # macOS 10.14 Mojave and older vim ~/.zshrc         # macOS 10.15 Catalina and newer (using zsh by default) 

And added the following environment variables:

export ANDROID_HOME=/Users/{{your user}}/Library/Android/sdk export ANDROID_SDK_ROOT=/Users/{{your user}}/Library/Android/sdk export ANDROID_AVD_HOME=/Users/{{your user}}/.android/avd 

Android path might be different, if so change it accordingly. At last, to refresh the terminal to apply changes:

source ~/.bash_profile  # macOS 10.14 Mojave and older source ~/.zshrc         # macOS 10.15 Catalina and newer (using zsh by default) 
like image 199
renatodamas Avatar answered Oct 04 '22 14:10

renatodamas