ここからはJavaでコーディングが必要になります。IS01はAndroid1.6であるため、NDKを利用する場合でも、SDKで作ったJavaアプリから、JNIで呼び出す必要があります。とは言ってもサンプルをコピーするだけでOKでした。
<?xml version="1.0" encoding="UTF-8"?> <project name="SDLApp" default="help"> <property file="local.properties" /> <property file="build.properties" /> <property file="default.properties" /> <import file="${sdk.dir}/tools/ant/pre_setup.xml" /> <setup /> </project>
local.properties
# This file is automatically generated by Android Tools. # Do not modify this file -- YOUR CHANGES WILL BE ERASED! # # This file must *NOT* be checked in Version Control Systems, # as it contains information specific to your local configuration. # location of the SDK. This is only used by Ant # For customization when using a Version Control System, please read the # header note. sdk.dir=C:\\android-sdk-windows
SDLActivity.java
全てビルドしてみます。
> cd c:\home\android-project
いよいよ、IS01にインストールしてみます。
> ant install