- Home /
unable to merge androidmenifest
Error building Player: CommandInvokationFailure: Unable to merge android manifests. See the Console for more details.
C:\Program Files (x86)\Java\jdk1.6.0_31sad\bin\java.exe -Xmx1024M -Dcom.android.sdkmanager.toolsdir="C:/Users/Bandhan/AppData/Local/Android/android-sdk\tools" -Dfile.encoding=UTF8 -jar "C:/Program Files (x86)/Unity/Editor/Data/BuildTargetTools/AndroidPlayer\sdktools.jar" -
stderr[ Exception in thread "main" java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at SDKMain.main(SDKMain.java:129) Caused by: java.lang.NoSuchMethodError: com.android.utils.XmlUtils.getUtfReader(Ljava/io/File;)Ljava/io/Reader; at com.android.manifmerger.MergerXmlUtils.parseDocument(MergerXmlUtils.java:85) at com.android.manifmerger.ManifestMerger.process(ManifestMerger.java:231) at com.android.manifmerger.Main.run(Main.java:70) at com.android.manifmerger.Main.main(Main.java:48) ... 5 more ] stdout[
]
Getting this error after adding unity ads and there is only one androidmanifest file please help.. Thanking you
Answer by liortal · Feb 12, 2015 at 12:10 AM
Unity uses the Android SDK that is installed on your machine and runs a few tools that are bundled with it.
The manifest merger is one example of such a tool.
This tool is located in \tools\lib\manifest-merger.jar
For some reason, it fails to find a method (seen in the stack trace you attached):
java.lang.NoSuchMethodError: com.android.utils.XmlUtils.getUtfReader(Ljava/io/File;)Ljava/io/Reader;
You didn't specify which Android SDK version and Unity version you're using, but I believe updating to the latest Android SDK should solve this issue.
Updating to the latest Android SD$$anonymous$$ worked for me (while everything else failed). Thank you so much!
Your answer
Follow this Question
Related Questions
How To fix FacebookSDK merge error in androidmanifest.xml ? 0 Answers
Issue Manifest Merge 2 Answers
can't build android app with facebook sdk 5 Answers
Merging 2 AndroidManifest.xml's 1 Answer
how can i save my AndroidManifest correctly? ** (HELP!) 0 Answers