- Home /
Unable to merge android manifests Google Play Games Services
This is the plugin I'm using and have done all the required setup including setting up and downloading all the required SDKs: https://github.com/playgameservices/play-games-plugin-for-unity
Error come while building the project.
And what is the error? Can we see the manifest? This plugin should add all the manifest stuff for you, given you done everything right.
Hello All
I am also having some issues building my android apk.
ERRORS: Unable to merge android manifest error and also repackage resources error
I am using Unity 5.3.2f1.
I am using the following SD$$anonymous$$'s in my project:
Facebook Unity SD$$anonymous$$ version 7.8.0 (unity package)
Unity Ads (in-built)
Google Ad mobs
GooglePlayGamesPlugin-0.9.34 Unity SD$$anonymous$$ (unity package)
I even tried updating the android-sdk tools etc....
What could be the error?
please help
Thanks
i have this errors..
1.error
Error: [Temp\StagingArea\Android$$anonymous$$anifest-main.xml, D:\unityprojects\appGirosaludfinal\Temp\StagingArea\android-libraries\play-services-ads-8.4.0\Android$$anonymous$$anifest.xml:10] Trying to merge incompatible /manifest/application/activity[@name=com.google.android.gms.ads.AdActivity] element:
UnityEditor.HostView:OnGUI()
2.error
CommandInvokationFailure: Unable to merge android manifests. See the Console for more details. C:\Program Files\Java\jdk1.7.0_79\bin\java.exe -Xmx2048$$anonymous$$ -Dcom.android.sdkmanager.toolsdir="D:/androidsdks\tools" -Dfile.encoding=UTF8 -jar "D:\programs\unity5.4\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -
stderr[ Error: [Temp\StagingArea\Android$$anonymous$$anifest-main.xml, D:\unityprojects\appGirosaludfinal\Temp\StagingArea\android-libraries\play-services-ads-8.4.0\Android$$anonymous$$anifest.xml:10] Trying to merge incompatible /manifest/application/activity[@name=com.google.android.gms.ads.AdActivity] element:
--(end reached)
++ ] stdout[ [Temp\StagingArea\Android$$anonymous$$anifest-main.xml, D:\unityprojects\appGirosaludfinal\Temp\StagingArea\android-libraries\Google$$anonymous$$obileAdsPlugin\Android$$anonymous$$anifest.xml:8] Skipping identical /manifest/application/meta-data[@name=com.google.android.gms.version] element. [Temp\StagingArea\Android$$anonymous$$anifest-main.xml, D:\unityprojects\appGirosaludfinal\Temp\StagingArea\android-libraries\play-services-basement-8.4.0\Android$$anonymous$$anifest.xml:5] Skipping identical /manifest/application/meta-data[@name=com.google.android.gms.version] element. ] UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String error$$anonymous$$sg) UnityEditor.Android.AndroidSD$$anonymous$$Tools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memory$$anonymous$$B, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String error$$anonymous$$sg) UnityEditor.Android.AndroidSD$$anonymous$$Tools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memory$$anonymous$$B, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String error$$anonymous$$sg) UnityEditor.HostView:OnGUI()
any help plis ?
According to the error, you have multiple, conflicting definitions of this activity: com.google.android.gms.ads.AdActivity
It's hard to tell since the message appears to be cut. You should check if you declare this activity definition somewhere more than once (for example - in a file called Android$$anonymous$$anifest.xml in your project). If you do have that declared - you should remove it, as it is already declared inside the play-services-basements-8.4.0.aar library.
This worked. I had multiple manifests with different $$anonymous$$SD$$anonymous$$ version numbers. I made them the same. worked.
Answer by jpsmarinho812 · Feb 20, 2014 at 02:47 PM
Me too. I installed this package and now I have the error Unable to merge android manifests. In the console shows this:
Error: [AndroidManifest-main.xml:8, AndroidManifest.xml:3] Main manifest has but library uses minSdkVersion='9'
I'm not know what to do.
edit:
The issue is solved for me. Search for archives with the name manifest in your Assets folder. Open these files and you need to have the same number in minSdkVersion for all files and the same number for targetSdkVersion for all files.
Thank you, I solved this error but now a new error is co$$anonymous$$g:
Failed to compile resources with the following parameters: -bootclasspath "C:/Users/NI$$anonymous$$HIL/android-sdks/platforms/android-14\android.jar" -d "C:\Users\NI$$anonymous$$HIL\Desktop\GameEon\GameFolder\Temp\StagingArea\bin\classes" -source 1.6 -target 1.6 -encoding ascii "com\gameeon\jelly\R.java" "com\google\android\gms\R.java" "com\google\example\games\basegameutils\R.java" "com\google\example\games\mainlibproj\R.java" Picked up _JAVA_OPTIONS: -Xmx1024$$anonymous$$
UnityEditor.HostView:OnGUI()
@ OP, this resolved the specific issue of being unable to merge manifest files. Be sure $$anonymous$$ sdk version and sdk targets are the same in all Android$$anonymous$$anifest files in your project. Please post up your new error in a new question.
Also make sure you all targeted the right $$anonymous$$SD$$anonymous$$Version or targetSD$$anonymous$$Version, for example "6" failed for me but "9" did the job
This doesn't work for me, when building they just all revert back to what their were before.. Any fix please?
Didn't work for me, when i try building again the values revert back to their original values!
Answer by saurabh.saket · Oct 09, 2015 at 03:45 PM
Hi! @rjr I had the same issue with Facebook sdk version: 7.1.0. Add this line with angle brackets:
uses-sdk android:minSdkVersion="15" android:targetSdkVersion="23" /
between "/application" and "/manifest" lines
in the android manifest file in the project > plugins folder. It fixed the issue for me.
Wow, it worked !!
It even solve the second problem, the one that is related to the java. Didnt even have to change the version numbers. $$anonymous$$ine were 15 and 23 for all the manifest files.
Nice man!!!! ^.^
Thanks a lot! I had the same issue and it worked perfect for me.
This is how i solved the issue.
Go to file > build settings> player settings
on the right click on the ''other settings'' tab
change the $$anonymous$$imum API level to 15.
Hope it works...
15 didn't work for me! 21 worked :D Thanks a ton!
Answer by siddharth3322 · Aug 13, 2014 at 06:58 AM
I got solution from this problem because of generated console file. First my project contains already other plugins so I have already one main manifest file.
After adding GooglePlayGamesPlugin it creates other android manifest file in that they specify necessary detail of using Google Play Services.
So as a result both android manifest file contain same details so I commented out my old manifest file code related to console detail.
Now I have no errors related to Unable to merge android manifests. Here I post my personal experience related to this bug, it might possible other developer solve it differently.
I have 2 manifest file one of game service and one of airpush ads. so should I move some code from one manifest to another. I think it should work. please help me bhai. @siddharth3322
Answer by kanaka.koppalu · Sep 08, 2015 at 05:24 PM
I found out.. the menu is moved to Window -> Google Play Games -> setup..
If you build without setup.. you will keep getting the error..
please setup this 1st.. :) took 2Hr + to debug this..
Answer by pixel_fiend · Jun 22, 2016 at 06:04 PM
The way I solved this was pretty simple.
update Minimum API Level in Player Settings > Android > Other Settings
Delete Temp/ directory
Your answer
Follow this Question
Related Questions
Google Play Games plugin for Unity Not Authenticating 9 Answers
Android Crashes on game load 1 Answer
Google Play Services error 0 Answers
Google Play Game Services Unity Plugin for Android 0 Answers
Convert android URI to usable path 0 Answers