20
2017
Android Build Error: Error: String types not allowed (at ‘configChanges’..
Tried to build simple Cardboard + GVR scene with Unity 2017.3b4, but kept getting this error:
CommandInvokationFailure: Failed to re-package resources.
***\android-sdk\build-tools\25.0.2\aapt.exe package –auto-add-overlay -v -f -m -J “gen” -M “AndroidManifest.xml” -S “res” -I “***android-sdk\platforms\android-23\android.jar” -F bin/resources.ap_ –extra-packages com.google.vr.cardboard:com.unity3d.unitygvr -S “***Game\Temp\StagingArea\android-libraries\gvr\res” -S “***Game\Temp\StagingArea\android-libraries\unitygvr\res”stderr[
AndroidManifest.xml:5: error: Error: String types not allowed (at ‘configChanges’ with value ‘mcc|mnc|locale|touchscreen|keyboard|keyboardHidden|navigation|orientation|screenLayout|uiMode|screenSize|smallestScreenSize|fontScale|layoutDirection|density’).
]
What I tried
– Modifying the AndroidManifest.xml configChanges line or even deleting the whole xml, but that didn’t help
– Tried deleting some unused stuff from GVR plugin, that apparently use some newer features, permission demo and those(?)
– Updated Java JDK to v9, but later founded out that v9 doesn’t work with Unity (CommandInvokationFailure: Failed to build apk. Caused by: java.lang.ClassNotFoundException: sun.misc.BASE64Encoder), more info: http://answers.unity3d.com/answers/1416130/view.html , so installed v8 instead (x64) http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
– Tried running updates on SDK Manager, tried building different API levels from 19 up to 26
Solution
– run SDK Manager, install SDK Platform (API 26), apparently mine was still API 23, although i was building for API 19..
More Info
– About JDK9 incompatibility https://forum.unity.com/threads/java-9-jdk-9-support-by-unity-android.499354/
Related Posts
5 Comments + Add Comment
Leave a comment
Recent posts
- [GreaseMonkey] Unity Forum Fixer
- UnityHub: Make Hub application background Translucent
- Customize SpriteShapeRenderer quality (but has issues)
- Editor tool: Copy selected gameobject’s names into clipboard as rows (for Excel)
- Editor tool: Replace string in selected gameobject’s names
- UnityHub: Enable built-in Login Dialog (no more browser login/logout issues!)
- Use TikTok-TTS in Unity (with WebRequest)
- Create Scene Thumbnail Image using OnSceneSaved & OnPreviewGUI
- webgl+javascript TTS
- Using Moonsharp (LUA) + Unity Webgl
- Using 3D gameobject prefabs with Unity Tilemap + NavMesh Surface
- Custom Unity Hub Project Template Preview Image/Video (using HTML+CSS in package description)
Recent Comments
- Vector3 maths for dummies! on
- UnityHub: Make Hub application background Translucent on
- UnityHub: Make Hub application background Translucent on
- Install Android SDK+JDK+NDK for Unity (without AndroidStudio or Unity Hub) on
- Install Android SDK+JDK+NDK for Unity (without AndroidStudio or Unity Hub) on
- [Asset Store] Point Cloud Viewer & Tools on
- [Asset Store] Point Cloud Viewer & Tools on
- ffmpeg stream raw video into Unity Texture2D on
Hi,
I have the same issue (I think after updating my unity version to 2017.2.0f3). Please let me know when you find out how to fix this. Thanks
Michael
Ah, just saw that you added a solution, will try this.
ok, that didn’t work…
sorry for spamming. It works now, apparently I had to install API 25 to make it work. I guess this is because I use a different unity version than you and this is the latest that you can select in the player settings. So finally I have set API 17 as minimum and API 25 as target (both installed, 17 is probably not needed though). If I set anything else as target, it doesn’t work, no matter if installed or not. Seems like a bug to me.
thank you .i had the same problem.and it works now