Artifact [a89026a213]
Not logged in

Artifact a89026a2134e58aed64e3665df3b0224d32e8c63:

Wiki page [Building AndroWish] by chw 2019-04-27 16:43:53.
D 2019-04-27T16:43:53.053
L Building\sAndroWish
P 7f2aecd37330d3ec9496f235ea7c5d94fa4dbf8d
U chw
W 2269
<h2>Building AndroWish</h2>

<h3>Requirements</h3>

  *  <a href="http://developer.android.com/sdk/index.html">Android SDK</a> (version 12 or later)
  *  <a href="http://developer.android.com/tools/sdk/ndk/index.html">Android NDK</a> (r7 or later)
  *  Minimum API level support by SDL is 10 (Android 2.3.3), requested API level from <tt>project.properties</tt> is 16 (Android 4.1)
  *  CPUs supported for native shared libraries are currently <tt>armeabi</tt> and <tt>x86</tt>. This can be changed in <tt>jni/Application.mk</tt>.

<h3>Building and Running AndroWish</h3>

Old school using Apache <tt>ant</tt>:

  #  Refresh the project settings using the android command from Android SDK: <tt>android update project</tt>
  #  Review <tt>local.properties</tt> to point to the directory where the Android SDK resides.
  #  Use <tt>ant</tt> to build AndroWish from scratch: <tt>ant debug</tt>. This includes building the C libraries using Android NDK. That step can be performed separately by running <tt>ndk-build</tt> in the <tt>jni</tt> directory or by invoking <tt>ant ndk-build</tt>
  #  The resulting Android APK is built to <tt>bin/AndroWish-debug.apk</tt> which can be installed onto a device or emulator using <tt>adb install -r bin/AndroWish-debug.apk</tt>.
  #  Start AndroWish on device or emulator using <tt>adb</tt> from the development system: <tt>adb shell am start tk.tcl.wish/.AndroWishLauncher</tt>.
  #  Clean the build tree with <tt>ant clean</tt>.

New style using <tt>gradlew</tt>:

  #  Setup your environment regarding the <tt>ndk-build</tt> command e.g. by setting both a proper <tt>PATH</tt> and <tt>ANDROID_NDK_HOME</tt>.
  #  Use <tt>gradlew</tt> to build AndroWish from scratch: <tt>./gradlew assembleDebug</tt>. As above this performs both the NDK build and the final compile and packaging steps.
  #  The resulting Android APK is built to <tt>build/outputs/apk/AndroWish-debug.apk</tt> which can be installed onto a device or emulator using <tt>adb install -r build/outputs/apk/AndroWish-debug.apk</tt>.
  #  Start AndroWish on device or emulator using <tt>adb</tt> from the development system: <tt>adb shell am start tk.tcl.wish/.AndroWishLauncher</tt>.
  #  Clean the build tree with <tt>./gradlew clean</tt>.

Z 59e985a28474b8a2bfa368d0da071a52