2012-08-13 7 views
0

J'ai mis à jour mon android sdk, mais quand je crée une nouvelle application, je reçois une nouvelle option sur ce que je n'ai jamais vu auparavant. Ce que cela signifie. enter image description hereMise à jour Android sdk faire erreur

ce que cela signifie. Je donne un nom à cette activité mère, mais quand je lance l'application que je reçois cette erreur

No Launcher activity found! 
The launch will only sync the application package on the device! 

La sortie console complète

[2012-08-13 13:54:35 - GG] ------------------------------ 
[2012-08-13 13:54:35 - GG] Android Launch! 
[2012-08-13 13:54:35 - GG] adb is running normally. 
[2012-08-13 13:54:35 - GG] No Launcher activity found! 
[2012-08-13 13:54:35 - GG] The launch will only sync the application package on the device! 
[2012-08-13 13:54:35 - GG] Performing sync 
[2012-08-13 13:54:35 - GG] Automatic Target Mode: launching new emulator with compatible AVD 'Androidvirtual' 
[2012-08-13 13:54:35 - GG] Launching a new emulator with Virtual Device 'Androidvirtual' 
[2012-08-13 13:54:35 - GG] ------------------------------ 
[2012-08-13 13:54:35 - GG] Android Launch! 
[2012-08-13 13:54:35 - GG] adb is running normally. 
[2012-08-13 13:54:35 - GG] No Launcher activity found! 
[2012-08-13 13:54:35 - GG] The launch will only sync the application package on the device! 
[2012-08-13 13:54:35 - GG] Performing sync 
[2012-08-13 13:54:35 - GG] Automatic Target Mode: launching new emulator with compatible AVD 'Androidvirtual' 
[2012-08-13 13:54:35 - GG] Launching a new emulator with Virtual Device 'Androidvirtual' 
[2012-08-13 13:54:48 - Emulator] WARNING: Data partition already in use. Changes will not persist! 
[2012-08-13 13:54:50 - Emulator] WARNING: SD Card image already in use: /home/belkacem/.android/avd/Androidvirtual.avd/sdcard.img 
[2012-08-13 13:54:50 - GG] New emulator found: emulator-5554 
[2012-08-13 13:54:50 - GG] Waiting for HOME ('android.process.acore') to be launched... 
[2012-08-13 13:54:51 - Emulator] WARNING: Cache partition already in use. Changes will not persist! 
[2012-08-13 13:54:51 - GG] New emulator found: emulator-5556 
[2012-08-13 13:54:51 - GG] Waiting for HOME ('android.process.acore') to be launched... 
[2012-08-13 13:55:18 - Emulator] Failed to create Context 0x3005 
[2012-08-13 13:55:18 - Emulator] emulator: WARNING: Could not initialize OpenglES emulation, using software renderer. 
[2012-08-13 13:55:18 - GG] emulator-5556 disconnected! Cancelling 'sync'! 
[2012-08-13 13:55:20 - Emulator] Failed to create Context 0x3005 
[2012-08-13 13:55:20 - Emulator] emulator: WARNING: Could not initialize OpenglES emulation, using software renderer. 
[2012-08-13 13:55:20 - GG] emulator-5554 disconnected! Cancelling 'sync'! 

manifest.xml

<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
    package="main.java" 
    android:versionCode="1" 
    android:versionName="1.0" > 

    <uses-sdk 
     android:minSdkVersion="16" 
     android:targetSdkVersion="15" /> 

    <application 
     android:icon="@drawable/ic_launcher" 
     android:label="@string/app_name" 
     android:theme="@style/AppTheme" > 
     <activity 
      android:name=".MainActivity" 
      android:label="@string/title_activity_main" > 
      <meta-data 
       android:name="android.support.PARENT_ACTIVITY" 
       android:value="d" /> 
     </activity> 
    </application> 

</manifest> 

Répondre

1
No Launcher activity found! 

Votre fichier manifeste doit avoir une activité en tant que lanceur d'applications ...

<activity 
android:name=".MainActivity" 
android:label="@string/title_activity_main" > 

<intent-filter> 
     <action android:name="android.intent.action.MAIN" /> 
     <category android:name="android.intent.category.LAUNCHER" /> 
    </intent-filter>  

</activity> 
+0

mais avant la mise à jour android sdk, je lance l'application sans ajouter aucune activité en tant que lanceur d'application – user1344201

1

Je pense que vous devez définir une activité de lancement.

<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
    package="main.java" 
    android:versionCode="1" 
    android:versionName="1.0" > 

    <uses-sdk 
     android:minSdkVersion="16" 
     android:targetSdkVersion="15" /> 

    <application 
     android:icon="@drawable/ic_launcher" 
     android:label="@string/app_name" 
     android:theme="@style/AppTheme" > 
     <activity 
      android:name=".MainActivity" 
      android:label="@string/title_activity_main" > 
     <intent-filter> 
      <action android:name="android.intent.action.MAIN" /> 
      <category android:name="android.intent.category.LAUNCHER" /> 
     </intent-filter> 
     </activity> 
    </application> 

</manifest> 
1

Insérer <category android:name="android.intent.category.LAUNCHER" /> dans votre balise d'activité, cela prendra soin de question que je suppose.

+0

mais avant la mise à jour android sdk, je lance l'application sans ajouter aucune activité en tant que lanceur d'applications – user1344201