New GameAnalytics plugin not building on Android

WARNING: [XmlResourcesTransformer] No mapping for: android/support/FILE_PROVIDER_PATHS
/private/var/folders/1w/wfn_f8wd7pq1fv0xc193wjbc0000gn/T/CLtmpecUEyp/template/app/src/main/AndroidManifest.xml Error:
	uses-sdk:minSdkVersion 15 cannot be smaller than version 16 declared in library [com.gameanalytics.sdk:gameanalytics-android:6.2.9] /Users/m/.gradle/caches/transforms-3/5937492daab5f465998d63cba887dd76/transformed/jetified-gameanalytics-android-6.2.9/AndroidManifest.xml as the library might be using APIs not available in 15
	Suggestion: use a compatible library with a minSdk of at most 15,
		or increase this project's minSdk version to at least 16,
		or use tools:overrideLibrary="com.gameanalytics.sdk.android" to force usage (may lead to runtime failures)

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':App:processReleaseMainManifest'.
> Manifest merger failed : uses-sdk:minSdkVersion 15 cannot be smaller than version 16 declared in library [com.gameanalytics.sdk:gameanalytics-android:6.2.9] /Users/m/.gradle/caches/transforms-3/5937492daab5f465998d63cba887dd76/transformed/jetified-gameanalytics-android-6.2.9/AndroidManifest.xml as the library might be using APIs not available in 15
  	Suggestion: use a compatible library with a minSdk of at most 15,
  		or increase this project's minSdk version to at least 16,
  		or use tools:overrideLibrary="com.gameanalytics.sdk.android" to force usage (may lead to runtime failures)

Worked last week, got a message from GameAnalytics saying they updated it, now broken.
Using Solar2D builds 3662, and new 3665 both same result.

GameAnalytics is not broken. They just do not support anything under Android 16 anymore. As the error states:

Suggestion: use a compatible library with a minSdk of at most 15,
		or increase this project's minSdk version to at least 16,
		or use tools:overrideLibrary="com.gameanalytics.sdk.android" to force usage (may lead to runtime failures)

So either:

  1. Add this to your build setting (this is what I would recommend):
android =
	{
       ...
        minSdkVersion = "16",
      }
  1. Or override the library (might cause issues, especially with devices under 16):
android =
	{
       ...
manifestChildElements = 
        {
            
            [[
            <uses-sdk tools:overrideLibrary="com.gameanalytics.sdk.android"/>
            ]]

        },
}

1 Like

Thanks very much, that did it. I can build with 3662.

I couldn’t build with 3665, it just hung forever.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.