Game Development Reference
In-Depth Information
Next you will need to download the Android SDK and NDK. The Android SDK is
the Java library normally used to develop Android applications, while the NDK is an
additional set of libraries that allows Java Android code to interface with compiled
C++ code.
The Android SDK is available at the following URL:
http://developer.android.com/sdk/index.html
It comes as a Windows installer file; so just execute it, accept all the default install
options, and wait for it to install.
Once the Android SDK has been installed, it is useful to set the
environment variable ANDROID_ROOT to the installation directory.
This lets the Marmalade deployment tool know where the Android
platform tools can be found so that it can automatically install and
run generated package files on an Android device connected to
your PC using a USB cable.
Next you can visit the following URL to download the Android NDK:
http://developer.android.com/tools/sdk/ndk/index.html
You will need different versions of the NDK depending on which
version of Marmalade you are using. If you are using Marmalade
6.1 or higher, as expected in this topic, you will need NDK version
8. For earlier versions of Marmalade, you will need NDK version 7.
The NDK is supplied as a ZIP archive, so you will need to decompress it using a
suitable archiving program (for example, WinZip). The NDK should be contained in
a directory named something like android-ndk-xxx , where xxx refers to the version
number of the NDK. You can either copy this directory into the root of your C: or
you can set the environment variable NDK_ROOT to point to the installation path.
Creating an Android extension
Now that we have the necessary development tools in place, we can create
the Android extension files by again using the Windows Explorer to locate
the Gyroscope.s4e file. Right-click on the file and select the Build Android
Extension menu option.
The files Gyroscope_android.mkb and Gyroscope_android_java.mkb will be
created in the main Gyroscope directory. These files will be used later to build
the extension code.
 
Search WWH ::




Custom Search