title: Error appeared when apply plugin: 'com.huawei.agconnect' in Flutter
body: <p>I was trying to use Huawei SDK in flutter so I apply the plugin in the
  <em>android/app/build.gradle</em> file as shown in the instruction in <a href="https://developer.huawei.com/consumer/en/doc/development/HMS-Plugin-Guides/integrate-plugin-0000001050418527" rel="noreferrer">https://developer.huawei.com/consumer/en/doc/development/HMS-Plugin-Guides/integrate-plugin-0000001050418527</a></p>
  <pre><code>apply plugin: 'kotlin-android'
  apply from: &quot;$flutterRoot/packages/flutter_tools/gradle/flutter.gradle&quot;
  **apply plugin: 'com.huawei.agconnect'**
  </code></pre>
  <p>However, it return with an error :</p>
  <pre><code>FAILURE: Build failed with an exception.
  
  * What went wrong:
  Could not determine the dependencies of task ':app_settings:compileDebugAidl'.
  &gt; Failed to find Platform SDK with path: platforms;android-R
  </code></pre>
  <p>I've seen some solution which stated need to add the following code in <em>android/build.gradle</em> file</p>
  <pre><code>subprojects {
      project.evaluationDependsOn(':app')
  }
  
  subprojects {
      project.buildDir = &quot;${rootProject.buildDir}/${project.name}&quot;
  
      project.evaluationDependsOn(':app')
  
      afterEvaluate {project -&gt;
          if (project.hasProperty(&quot;android&quot;) &amp;&amp; project.property(&quot;android&quot;).compileSdkVersion.equals(&quot;android-R&quot;)) {
              android {
                  compileSdkVersion 30
              }
          }
      }
  }
  </code></pre>
  <p>I've added it but it still return the same error. When I removed the <strong>apply plugin: 'com.huawei.agconnect'</strong>, the error did not appeared. But in this case I would like to use the plugin because I am planning to use Huawei push kit.</p>
  <p>Kindly tell me if any additional information needed to look through this problem.
  Thank you.</p>