I've an application which aims to run only as a service (no interface, just run in background). I have no activity mentioned in my AndroidManifest.xml but put a receiver to start the application at phone start.
<application
android:icon="@drawable/ic_launcher"
android:label="@string/app_name" >
<service
android:enabled="true"
android:name=".MyAppService">
<intent-filter>
<action
android:name = "me.myapp.MyAppService">
</action>
</intent-filter>
</service>
<receiver
android:enabled="true"
android:name=".BootReceiver">
<intent-filter>
<action android:name = "android.intent.action.BOOT_COMPLETED"/>
</intent-filter>
</receiver>
</application>
The problem is that as I'm developing (using Eclipse) the application, I need to test my changes often. When I run the application (with my phone connected in debug mode), I've got a message like
[2011-12-14 00:18:40 - MyApp] Android Launch!
[2011-12-14 00:18:40 - MyApp] adb is running normally.
[2011-12-14 00:18:40 - MyApp] No Launcher activity found!
[2011-12-14 00:18:40 - MyApp] The launch will only sync the application package on the device!
[2011-12-14 00:18:40 - MyApp] Performing sync
How can I start the application at run, without having to restart it every time ?
Edit this is not possible anymore for Android 3.1 or above. Source