Hi, Guest! Login / Register




Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

[Tutorial] How to setup Android NDK on Ubuntu 14

#1
(This post was last modified: 01-12-2015, 10:56 PM by hovatek. )

The Android Android Native Development Kit (NDK) is a toolset that allows you to implement parts of your app using native-code languages such as C and C++. Android Development Requires Oracle Java JDK 6+ and the Android SDK.

Procedure

1. Setup Ubuntu (see https://forum.hovatek.com/thread-1004.html )
2. Open a Command Line Shell Session by pressing Ctr+Alt+t
3. Download Android Native Development Kit for
Linux 32/64bit
4. Double-Click on the archive and extract into /tmp
5. Relocate Android NDK Folder

Code:
sudo su -c "chown -R root:root /tmp/
android-ndk* && mv /tmp/android-ndk* /
opt"

6. Setup ANDROID_NDK Environment Variable

Code:
nano ~/.bashrc

Example Append (Following your NDK
Installation Location):

Code:
export ANDROID_NDK=/opt/android-
ndk*
export PATH=$PATH:$ANDROID_NDK

Ctrl+x to Save & Exit from nano Editor.

7. Install Required Android SDK Tools for
Ubuntu

8. Set Up ANDROID_SDK Environment Variable

Code:
nano ~/.bashrc

Example Append (Following your SDK
Installation Location):

Code:
export ANDROID_SDK=/opt/android-sdk-
linux
export PATH=$PATH:$ANDROID_SDK/tools:
$ANDROID_SDK/platform-tools

Ctrl+x to Save & Exit from nano Editor.

9. Install Oracle JDK7 for Ubuntu

10. Set Up JDK_PATH Environment Variable

Code:
nano ~/.bashrc

Example Append (Following your JDK
Installation Location):

Code:
export JDK_PATH=/usr/lib/jvm/jdk1.7*/
bin
export PATH=$PATH:$JDK_PATH

Ctrl+x to Save & Exit from nano Editor.

11. Load New Environment Variables:

Code:
source ~/.bashrc

Credits: http://tutorialforlinux.com/


Need further assistance? Speak with a Hovatek Representative:
Working Hours: Mondays - Saturdays ; 09:00 - 18:00 (GMT +1:00)
Reply










Users browsing this thread:
1 Guest(s)