I have downloaded NDK for my eclips juno....now i have to add the NDK to path and have to add lines to .bashrc.
I have to add the following lines to my .bashrc
export ANDROID_NDK=/_path_to/android-ndk-linux/
export ANDROID_SDK=/_path_to/android-sdk-linux/
export PATH=$PATH:$ANDROID_SDK/tools:$ANDROID_SDK/platform-tools:$ANDROID_NDK
In my terminal I wrote....
~/.bashrc
But it says bash:
/home/user/.bashrc: Permission denied
how can I change permission to write to .bashrc?????
When you type on the command line:
~/.bashrc
You are requesting that the shell execute the file. If you want to edit the file, try:
nano ~/.bashrc
Replace nano with the name of your favorite editor.
If you just want to copy and paste those three lines into your file, you don't really need an editor. Just run the following:
cat >>~/.bashrc
Then, copy and paste those three lines. Then press enter and type control-D and you are done.
Related
I am trying to run the emulator -list-avds via terminal, but for some reason keep on getting this error.
Here is my .zshrc profile:
export N_PREFIX="$HOME/n"; [[ :$PATH: == *":$N_PREFIX/bin:"* ]] || PATH+=":$N_PREFIX/bin" # Added by n-install (see http://git.io/n-in$
# Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
export PATH="$PATH:$HOME/.rvm/bin"
export PATH=$PATH:/~nativeGuy/Library/Android/sdk
export PATH=$PATH:/~nativeGuy/Library/Android/sdk/platform-tools
export ANDROID_HOME=$HOME/Library/Android/sdk
You could do a
that_guys_home_dir=~nativeGuy # Do tilde-expansion
PATH=$PATH:$that_guys_home_dir/Library/Android/sdk
This allows you to put other people's home directory into the path. Of course, if you happen to be nativeGuy, you would simpler do a
PATH=$PATH:$HOME/Library/Android/sdk
Since you are using zsh, a more elegant solution, which obviates you from worrying about the correct way of doing tilde expansion, would be to do a
path+=~nativeGuy/Library/Android/sdk
This implicitly sets PATH, because path and PATH are kept in-sync.
I'm facing the problem, that i cannot set the ANDROID_HOME path variable.
I added the following lines to my bashrc file:
# Android Path
export ANDROID_HOME=~/android-sdk/Sdk/tools
But when i try to access android via the terminal i get this error:
android: command not found
How can i solve this problem?
You need to add the variable in your PATH as well. The aim is for your PATH variable to contain the complete folder path, in which the file 'android' is present.
export ANDROID_HOME=~/android-sdk/Sdk/tools
export PATH=$ANDROID_HOME:$PATH
Don't forget to source your bashrc after adding these lines
source ~/.bashrc
Again, the file 'android' should be present in the tools folder.
Follow the following steps:
1)Open the bashrc file from command line
nano ~/.bashrc
2) Add following lines at the top.
export PATH=${PATH}:~/android-sdk-linux/tools
export PATH=${PATH}:~/android-sdk-linux/platform-tools
3)Now, quit terminal and re-launch, and try typing:
adb -h
android -h
If both commands are giving you output, it means everything works fine.
I have obstacle when run sudo ionc build android.
Error log terminal:
Set enviroment varibale in .profile:
Please give me solutions. How to setting PATH that true.
The system is not able to find the environment variable ANDROID_HOME in your .bashrc file. To resolve this error, you need to add the following to line to your ~/.bashrc file:
export ANDROID_HOME="<path/to/your/sdk/without/quotes>"
For me, I added the following
export ANDROID_HOME="/Users/chi6rag/Library/Android/sdk"
And ran source ~/.bashrc so that the configuration is loaded.
i have already refer these links...
http://stackoverflow.com/questions/20241637/where-i-can-get-cordava-3-2-jar-file
http://cordova.apache.org/docs/en/3.2.0/guide_platforms_android_webview.md.html
This is my comand prompt o/p :
What should I do...
E:\Android Installation\cordova-3.2.0-src\cordova-3.2.0\cordova-android\framewor
k>android update project -p . -t android-18
'android' is not recognized as an internal or external command,
operable program or batch file.
It is because windows is unable to find the program android.bat or android.exe or whatever it is what you need to do is edit your PATH environmental variable and set it to the folder containing the file ,The file is probably at android-sdk/tools/ directory goto your android sdk installation directory/tools copy the path and in the command prompt typeset PATH="<the path you've just copied>"
I have gone through this NDK example link.And i did all.But ndk-build not working(command not found).I tried ./ndk-build also but no success.I set the path variable too.I am using Ubuntu OS.Any help.Ndk path in bash.bashrc file is like this:
export NDK_HOME=/home/android/android-ndk-r8e-linux-x86/android-ndk-r8e/
The big problem is i am doing cd to this folder in command prompt and doing ndk-build and it's not working.The file inside this filder is ndk-build.cmd
If you want to run ndk-build this way, you need the path of the executable file to be in the PATH env variable. Otherwise you have to specify the entire path to ndk-build. For instace /home/username/ndkpath/ndk-build
Seems that you have get wrong the path, instead use
export NDK_HOME=/home/android/android-ndk-r8e-linux-x86/