AndroidManifest.xml error

Hi!. i´m trying to compile for android…

But i am receiving this error: AndroidManifest.xml is invalid System.Xml.XmlException: android:extractNativeLibs is a duplicate attribute name.

UATHelper: Packaging (Android (ETC2)): heapprofd init
UATHelper: Packaging (Android (ETC2)): Unsupported architecture: armeabi-v7a
UATHelper: Packaging (Android (ETC2)): GoogleGameSDK Android init
UATHelper: Packaging (Android (ETC2)): On build machine.
UATHelper: Packaging (Android (ETC2)): Fixing minSdkVersion; requires minSdkVersion of 27 for Clang's Sanitizers
UATHelper: Packaging (Android (ETC2)): ERROR: AndroidManifest.xml is invalid System.Xml.XmlException: 'android:extractNativeLibs' es un nombre de atributo duplicado. línea 13, posición 15.
UATHelper: Packaging (Android (ETC2)):           en System.Xml.XmlTextReaderImpl.Throw(Exception e)
UATHelper: Packaging (Android (ETC2)):           en System.Xml.XmlTextReaderImpl.AttributeDuplCheck()
UATHelper: Packaging (Android (ETC2)):           en System.Xml.XmlTextReaderImpl.ParseAttributes()
UATHelper: Packaging (Android (ETC2)):           en System.Xml.XmlTextReaderImpl.ParseElement()
UATHelper: Packaging (Android (ETC2)):           en System.Xml.XmlTextReaderImpl.ParseElementContent()
UATHelper: Packaging (Android (ETC2)):           en System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r)
UATHelper: Packaging (Android (ETC2)):           en System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r, LoadOptions o)
UATHelper: Packaging (Android (ETC2)):           en System.Xml.Linq.XDocument.Load(XmlReader reader, LoadOptions options)
UATHelper: Packaging (Android (ETC2)):           en System.Xml.Linq.XDocument.Parse(String text, LoadOptions options)
UATHelper: Packaging (Android (ETC2)):           en UnrealBuildTool.UEDeployAndroid.GenerateManifest(AndroidToolChain ToolChain, String ProjectName, TargetType InTargetType, String EngineDirectory, Boolean bIsForDistribution, Boolean bPackageDataInsideApk, String GameBuildFilesPath, Boolean bHasOBBFiles, Boolean bDisableVerifyOBBOnStartUp, String UE4Arch, St
ring GPUArch, String CookFlavor, Boolean bUseExternalFilesDir, String Configuration, Int32 SDKLevelInt, Boolean bIsEmbedded, Boolean bEnableBundle) en C:\Entorno\Frameworks\UE427\Engine\Source\Programs\UnrealBuildTool\Platform\Android\UEDeployAndroid.cs:línea 2884
UATHelper: Packaging (Android (ETC2)):        <?xml version="1.0" encoding="utf-8"?>
UATHelper: Packaging (Android (ETC2)):        <manifest xmlns:android="http://schemas.android.com/apk/res/android"
UATHelper: Packaging (Android (ETC2)):                  package="com.u71x.p7"
UATHelper: Packaging (Android (ETC2)):                  android:installLocation="auto"
UATHelper: Packaging (Android (ETC2)):                  android:versionCode="1"
UATHelper: Packaging (Android (ETC2)):                  android:versionName="1.0">
UATHelper: Packaging (Android (ETC2)):        
UATHelper: Packaging (Android (ETC2)):         <!-- Application Definition -->
UATHelper: Packaging (Android (ETC2)):         <application android:label="@string/app_name"
UATHelper: Packaging (Android (ETC2)):                      android:icon="@drawable/icon"
UATHelper: Packaging (Android (ETC2)):                      android:extractNativeLibs="true"
UATHelper: Packaging (Android (ETC2)):                      android:hardwareAccelerated="true"
UATHelper: Packaging (Android (ETC2)):                      android:extractNativeLibs="true"
UATHelper: Packaging (Android (ETC2)):                         android:name="com.epicgames.ue4.GameApplication"
UATHelper: Packaging (Android (ETC2)):                      android:hasCode="true">
UATHelper: Packaging (Android (ETC2)):             <activity android:name="com.epicgames.ue4.SplashActivity"
UATHelper: Packaging (Android (ETC2)):                       android:label="@string/app_name"
UATHelper: Packaging (Android (ETC2)):                       android:theme="@style/UE4SplashTheme"
UATHelper: Packaging (Android (ETC2)):                       android:launchMode="singleTask"
UATHelper: Packaging (Android (ETC2)):                       android:screenOrientation="landscape"
UATHelper: Packaging (Android (ETC2)):                       android:debuggable="true">
UATHelper: Packaging (Android (ETC2)):                 <intent-filter>
UATHelper: Packaging (Android (ETC2)):                     <action android:name="android.intent.action.MAIN" />
UATHelper: Packaging (Android (ETC2)):                     <category android:name="android.intent.category.LAUNCHER" />
UATHelper: Packaging (Android (ETC2)):                 </intent-filter>
UATHelper: Packaging (Android (ETC2)):             </activity>
UATHelper: Packaging (Android (ETC2)):             <activity android:name="com.epicgames.ue4.GameActivity"
UATHelper: Packaging (Android (ETC2)):                       android:label="@string/app_name"
UATHelper: Packaging (Android (ETC2)):                       android:theme="@style/UE4SplashTheme"
UATHelper: Packaging (Android (ETC2)):                       android:configChanges="mcc|mnc|uiMode|density|screenSize|smallestScreenSize|screenLayout|orientation|keyboardHidden|keyboard"
UATHelper: Packaging (Android (ETC2)):                       android:resizeableActivity="false"
UATHelper: Packaging (Android (ETC2)):                       android:launchMode="singleTask"
UATHelper: Packaging (Android (ETC2)):                       android:screenOrientation="landscape"
UATHelper: Packaging (Android (ETC2)):                       android:debuggable="true">
UATHelper: Packaging (Android (ETC2)):                 <meta-data android:name="android.app.lib_name" android:value="UE4"/>
UATHelper: Packaging (Android (ETC2)):             </activity>
UATHelper: Packaging (Android (ETC2)):             <activity android:name=".DownloaderActivity"
UATHelper: Packaging (Android (ETC2)):                       android:screenOrientation="landscape"
UATHelper: Packaging (Android (ETC2)):                       android:configChanges="mcc|mnc|uiMode|density|screenSize|orientation|keyboardHidden|keyboard"
UATHelper: Packaging (Android (ETC2)):                       android:theme="@style/UE4SplashTheme" />
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.EngineVersion" android:value="4.27.2"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.EngineBranch" android:value="++UE4+Release-4.27"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.ProjectVersion" android:value="1.0.0.0"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.DepthBufferPreference" android:value="0"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bPackageDataInsideApk" android:value="true"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bVerifyOBBOnStartUp" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bShouldHideUI" android:value="true"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.ProjectName" android:value="P7"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.AppType" android:value=""/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bHasOBBFiles" android:value="true"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.BuildConfiguration" android:value="Development"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.CookedFlavors" android:value="ETC2"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bValidateTextureFormats" android:value="true"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bUseExternalFilesDir" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bPublicLogFiles" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bUseDisplayCutout" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bAllowIMU" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.bSupportsVulkan" android:value="false"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.epicgames.ue4.GameActivity.StartupPermissions" android:value="android.permission.WRITE_EXTERNAL_STORAGE"/>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.google.android.gms.games.APP_ID"
UATHelper: Packaging (Android (ETC2)):                        android:value="@string/app_id" />
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="com.google.android.gms.version"
UATHelper: Packaging (Android (ETC2)):                        android:value="@integer/google_play_services_version" />
UATHelper: Packaging (Android (ETC2)):             <activity android:name="com.google.android.gms.ads.AdActivity"
UATHelper: Packaging (Android (ETC2)):                       android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>
UATHelper: Packaging (Android (ETC2)):             <service android:name="OBBDownloaderService" />
UATHelper: Packaging (Android (ETC2)):             <receiver android:name="AlarmReceiver" />
UATHelper: Packaging (Android (ETC2)):             <receiver android:name="com.epicgames.ue4.LocalNotificationReceiver" />
UATHelper: Packaging (Android (ETC2)):             <receiver android:name="com.epicgames.ue4.MulticastBroadcastReceiver" android:exported="true">
UATHelper: Packaging (Android (ETC2)):                 <intent-filter>
UATHelper: Packaging (Android (ETC2)):                     <action android:name="com.android.vending.INSTALL_REFERRER" />
UATHelper: Packaging (Android (ETC2)):                 </intent-filter>
UATHelper: Packaging (Android (ETC2)):             </receiver>
UATHelper: Packaging (Android (ETC2)):             <meta-data android:name="android.max_aspect" android:value="2.10" />
UATHelper: Packaging (Android (ETC2)):         </application>
UATHelper: Packaging (Android (ETC2)):        
UATHelper: Packaging (Android (ETC2)):         <!-- Requirements -->
UATHelper: Packaging (Android (ETC2)):         <uses-feature android:glEsVersion="0x00030001" android:required="true" />
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.INTERNET"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.WAKE_LOCK"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="com.android.vending.CHECK_LICENSE"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="android.permission.VIBRATE"/>
UATHelper: Packaging (Android (ETC2)):         <uses-permission android:name="com.android.vending.BILLING"/>
UATHelper: Packaging (Android (ETC2)):         <!-- Supported texture compression formats (cooked) -->
UATHelper: Packaging (Android (ETC2)):        </manifest>
UATHelper: Packaging (Android (ETC2)):        
UATHelper: Packaging (Android (ETC2)):        (see C:\Entorno\Frameworks\UE427\Engine\Programs\AutomationTool\Saved\Logs\Log.txt for full exception trace)
UATHelper: Packaging (Android (ETC2)): AutomationTool exiting with ExitCode=1 (Error_Unknown)
UATHelper: Packaging (Android (ETC2)): BUILD FAILED
PackagingResults: Error: Unknown Error

Any clues?.. i think i am almost near to successfuly compiling.

I’ve had the same problem for almost a week, did you manage to solve it?

Not the same exact error, but similar issue.

in my case, I migrated from unreal 4.27 to 5.3, and in engine 4.27, I had to manually add this line to project settings under extra tags for game activity due to some new play store policy:

android:exported=“true”

After migrating, seems like UE 5.3 adds this tag itself, so adding it manually made it duplicate. Simply remove it from the Project Settings → Extra Tags for GameActivity.

Otherwise, if you haven’t defined any extra tags in your project settings, it would be best to check plugins and their UPL/APL XML files to make sure they aren’t adding this tag manually either.

1 Like