title: Flutter - sdk set problem after set compile sdk 30 to 31
body: <p>When I am using to set compile SDK 30 in flutter then I got these error</p>
  <pre><code>* What went wrong:
  Execution failed for task ':app:checkDebugAarMetadata'.
  &gt; A failure occurred while executing 
  com.android.build.gradle.internal.tasks.CheckAarMetadataWorkAction
  &gt; One or more issues found when checking AAR metadata values:
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.appcompat:appcompat:1.4.0.
   AAR metadata file: 
   C:\Users\WasiSoft\.gradle\caches\transforms3\6a6bfbcf60d09272b0cdf4bed2dc0443\
    transformed\appcompat-1.4.0\META-INF\com\android\build\gradle\aar-metadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.appcompat:appcompat-resources:1.4.0.
   AAR metadata file: 
   C:\Users\WasiSoft\.gradle\caches\transforms3\8fe9ccdb464c8d3dff16cf232813d78c\
   transformed\jetified-appcompat-resources-1.4.0\META-INF\com\
    android\build\gradle\aar-metadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.emoji2:emoji2-views-helper:1.0.0.
   AAR metadata file: 
   C:\Users\WasiSoft\.gradle\caches\transforms3\aa5ebfefee6d35dee263bd0cd4753256\
   transformed\jetified -emoji2-views-helper-1.0.0\META-INF\com\android\build\gradle\
   aarmetadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.emoji2:emoji2:1.0.0.
   AAR metadata file: C:\Users\WasiSoft\.gradle\caches\transforms- 
   3\b0e38b05362ae33360070f9b30618d9f\transformed\jetified-emoji21.0.0\METAINF\com\android\build 
    \gradle\aar-metadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.core:core:1.7.0.
   AAR metadata file: C:\Users\WasiSoft\.gradle\caches\transforms- 
   3\028820553fa44b6579541915f81b128d\transformed\core1.7.0\METAINF\com\android\build\gradle\aar
    -metadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.lifecycle:lifecycle-process:2.4.0.
   AAR metadata file: C:\Users\WasiSoft\.gradle\caches\transforms- 
  3\623708390cd51304eeeb10f79f7ceb8b\transformed\jetified-lifecycle-process-2.4.0\META- 
  INF\com\android\build\gradle\aar-metadata.properties.
  
   The minCompileSdk (31) specified in a
   dependency's AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)
   is greater than this module's compileSdkVersion (android-30).
   Dependency: androidx.lifecycle:lifecycle-runtime:2.4.0.
   AAR metadata file: C:\Users\WasiSoft\.gradle\caches\transforms- 
   3\77475f45e2af1906c765abcaefbb8c4c\transformed\lifecycle-runtime-2.4.0\META- 
   INF\com\android\build\gradle\aar-metadata.properties.
  </code></pre>
  <p>if I am using SDK 31 then I got this issue</p>
  <pre><code> C:\Users\WasiSoft\AndroidStudioProjects\wsms_employee\android\app\src\
    main\AndroidManifest.xml Error:
    android:exported needs to be explicitly specified for &lt;activity&gt;. Apps targeting Android 12 
    and higher are required to specify an explicit value for `andro
    id:exported` when the corresponding component has an intent filter defined. See 
    https://developer.android.com/guide/topics/manifest/activity-element#exported for details.
  </code></pre>
  <h2>AndroidManifest.xml</h2>
  <pre><code>   &lt;manifest xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
  xmlns:tools=&quot;http://schemas.android.com/tools&quot;
  package=&quot;com.comple.example&quot;&gt;
  
  &lt;uses-permission android:name=&quot;android.permission.ACCESS_NETWORK_STATE&quot; /&gt;
  &lt;uses-permission android:name=&quot;android.permission.INTERNET&quot; /&gt;
  &lt;uses-permission android:name=&quot;android.permission.CAMERA&quot; /&gt;
  &lt;uses-permission android:name=&quot;android.permission.RECEIVE_BOOT_COMPLETED&quot; /&gt;
  &lt;uses-permission android:name=&quot;android.permission.WAKE_LOCK&quot; /&gt;
  
  &lt;application
      tools:replace=&quot;android:label&quot;
      android:name=&quot;io.flutter.app.FlutterApplication&quot;
      android:hardwareAccelerated=&quot;true&quot;
      android:label=&quot;WSMS Employee&quot;
      android:icon=&quot;@mipmap/ic_launcher&quot;
      &gt;
      &lt;activity
          android:name=&quot;.MainActivity&quot;   
      android:configChanges=&quot;orientation|keyboardHidden|keyboard|
     screenSize|smallestScreenSize|locale|
        layoutDirection|fontScale|screenLayout|density|uiMode&quot;
          android:launchMode=&quot;singleTop&quot;
          android:showWhenLocked=&quot;true&quot;
          android:exported=&quot;true&quot;
          android:theme=&quot;@style/LaunchTheme&quot;
          android:turnScreenOn=&quot;true&quot;
          android:windowSoftInputMode=&quot;adjustResize&quot;&gt;
          &lt;!-- Specifies an Android theme to apply to this Activity as soon as
               the Android process has started. This theme is visible to the user
               while the Flutter UI initializes. After that, this theme continues
               to determine the Window background behind the Flutter UI. --&gt;
          &lt;meta-data
              android:name=&quot;io.flutter.embedding.android.NormalTheme&quot;
              android:resource=&quot;@style/NormalTheme&quot; /&gt;
          &lt;!-- Displays an Android View that continues showing the launch screen
               Drawable until Flutter paints its first frame, then this splash
               screen fades out. A splash screen is useful to avoid any visual
               gap between the end of Android's launch screen and the painting of
               Flutter's first frame. --&gt;
          &lt;meta-data
              android:name=&quot;io.flutter.embedding.android.SplashScreenDrawable&quot;
              android:resource=&quot;@drawable/launch_background&quot; /&gt;
          &lt;intent-filter&gt;
              &lt;action android:name=&quot;android.intent.action.MAIN&quot; /&gt;
              &lt;category android:name=&quot;android.intent.category.LAUNCHER&quot; /&gt;
          &lt;/intent-filter&gt;
      &lt;/activity&gt;
      &lt;!-- Don't delete the meta-data below.
           This is used by the Flutter tool to generate GeneratedPluginRegistrant.java --&gt;
      &lt;meta-data
          android:name=&quot;flutterEmbedding&quot;
          android:value=&quot;2&quot; /&gt;
  
  &lt;/application&gt;
     &lt;/manifest&gt;
  </code></pre>
  <p>i tried all possible ways to get rid of this issue i dont know why this happens kindly anuone look into this.also how to set activity when compile sdk 31. which is very difficult in flutter</p>