Using Titanium Studio, build: 3.1.0 my app was crashing immediately on launch in the Android emulator when using an Android API greater than 15 (4.0.3).
The message was: Unfortunately, APP_NAME has stopped.
It didn’t matter what system image I tried for the emulator (x86, Arm, MIPS) nor any adjustments made to the emulator configuration (memory, SD card, hardware keys etc).
It turned out to be related to the combination of fastdev running and targetSdkVersion (set in tiapp.xml) and has been discussed and reported already (I found after hours of tinkering, testing and threatening my machine of course).
How To Fix/Avoid
When working with an Android API greater than 15 (4.0.3) you just need to turn off fastdev in the tiapp.xml by adding:
<property name="ti.android.fastdev" type="bool">false</property>
So combining that with some other Android configurations I have ended up with a tiapp.xml that includes:
<property name="ti.android.fastdev" type="bool">false</property> <android xmlns:android="http://schemas.android.com/apk/res/android"> <tool-api-level>14</tool-api-level> <manifest> <supports-screens android:anyDensity="false"/> <application android:theme="@android:style/Theme.Holo.Light"/> <uses-sdk android:minSdkVersion="8" android:targetSdkVersion="14" android:maxSdkVersion="17"/> </manifest> </android>
android:anyDensity=”false” is a fix for TabBar icons rendering too small in Android 2.3. I’m not sure yet what (if any) implications that has on the rest of an app yet. In the emulator they rendered as you would expect, but on my 2.3.6 device they were barely legible. This thread has more info on the matter.