这是我的清单,请任何人都可以检查,在我没有包括android:manifet
的地方,我几乎到处都添加了这个属性,但仍然没有在Android 12中安装,并且在播放商店上传时,它给出了这个错误错误=“您上传了一个APK或Android应用程序包,其中包含一个活动,活动别名,服务或带有意图过滤器的广播接收器,但没有'android:exported'属性集。此文件无法安装在Android 12或更高版本上。”
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.yash.earnfun">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<application
android:allowBackup="true"
android:icon="@drawable/app_icon"
android:label="@string/app_name"
android:name=".SketchApplication"
android:requestLegacyExternalStorage="true"
android:theme="@style/AppTheme">
<activity
android:name=".MainActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".LoginnedmainActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".ReferActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".BonusActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".ProfileActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".RedeemActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".Redeem1Activity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:screenOrientation="portrait" />
<activity
android:name=".Refer1Activity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".EEarnActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".PhoneActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".SpinActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".NameActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".RedeemHActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:screenOrientation="portrait" />
<activity
android:name=".NotFonActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:screenOrientation="portrait" />
<activity
android:name=".Spin2Activity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:screenOrientation="portrait" />
<activity
android:name=".PaymentActivity"
android:exported="true"
android:configChanges="orientation|screenSize|keyboardHidden|smallestScreenSize|screenLayout"
android:hardwareAccelerated="true"
android:supportsPictureInPicture="true"
android:screenOrientation="portrait" />
<activity
android:name=".DebugActivity"
android:exported="true"
android:screenOrientation="portrait" />
<activity
android:name="com.google.android.gms.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
android:theme="@android:style/Theme.Translucent" />
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<provider
android:name="com.google.firebase.provider.FirebaseInitProvider"
android:authorities="com.yash.earnfun.firebaseinitprovider"
android:exported="false"
android:initOrder="100" />
<service
android:name="com.google.firebase.components.ComponentDiscoveryService"
android:exported="false">
<meta-data
android:name="com.google.firebase.components:com.google.firebase.auth.FirebaseAuthRegistrar"
android:value="com.google.firebase.components.ComponentRegistrar" />
<meta-data android:name="com.google.firebase.components:com.google.firebase.database.DatabaseRegistrar"
android:value="com.google.firebase.components.ComponentRegistrar" />
<meta-data
android:name="com.google.firebase.components:com.google.firebase.iid.Registrar"
android:value="com.google.firebase.components.ComponentRegistrar" />
</service>
<service
android:name="com.google.firebase.messaging.FirebaseMessagingService"
android:exported="false">
<intent-filter android:priority="-500">
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>
</service>
<receiver
android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
android:exported="true"
android:permission="com.google.android.c2dm.permission.SEND">
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
</intent-filter>
</receiver>
<provider
android:name="com.startapp.sdk.adsbase.StartAppInitProvider"
android:authorities="APP_ID.startappinitprovider"
android:exported="false" />
<activity
android:name="com.startapp.sdk.adsbase.consent.ConsentActivity"
android:exported="true"
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden" android:theme="@android:style/Theme.Translucent"/>
<activity
android:name="com.startapp.sdk.ads.list3d.List3DActivity"
android:exported="true"
android:theme="@android:style/Theme"/>
<activity
android:name="com.startapp.sdk.adsbase.activities.OverlayActivity"
android:exported="true"
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden"
android:theme="@android:style/Theme.Translucent"/>
<activity
android:name="com.startapp.sdk.adsbase.activities.FullScreenActivity"
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden"
android:exported="true"
android:theme="@android:style/Theme"/>
<service android:name="com.startapp.sdk.adsbase.InfoEventService"
android:exported="true" />
<service
android:name="com.startapp.sdk.adsbase.PeriodicJobService"
android:exported="true"
android:permission="android.permission.BIND_JOB_SERVICE" />
<receiver android:name="com.startapp.sdk.adsbase.remoteconfig.BootCompleteListener">
android:exported="true"
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
</intent-filter>
</receiver>
</application>
</manifest>
我尝试将android:exported
添加到每个组件,但随后也出现此错误
1条答案
按热度按时间2w2cym1i1#
您的活动在清单中应如下所示:
请注意android:export标签只在主Activity上,而intent-filter也在主Activity块内。