随笔 - 36, 评论 - 12, 访问 - 224199

导航


  • 访问:224199次
  • 积分:378分
  • 排名:第38名
  • 随笔:36篇
  • 评论:12条

随笔分类

随笔档案

相册

最新评论

阅读排行榜

评论排行榜

unity3d 阅读(283) 评论(0)

导入某个插件后就发生了无法编译的问题。

错误一:

Error: [Temp\StagingArea\AndroidManifest-main.xml:2, E:\Unity3DProjects\vr360\Temp\StagingArea\android-libraries\vrlib\AndroidManifest.xml:3] Main manifest has <uses-sdk android:minSdkVersion='16'> but library uses minSdkVersion='19'

 

解决:

这是最低sdk版本要求不一致导致的,修改Assets/Plugins/Android/AndroidManifest.xml,将minSdkVersion修改为19即可:

<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="22" />

 

错误二:
CommandInvokationFailure: Unable to merge android manifests. See the Console for more details.
D:\Program Files\Java\jdk1.8.0_121\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="D:/AndroidSDK\tools" -Dfile.encoding=UTF8 -jar "E:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -

stderr[

]
stdout[
Warning: [Temp\StagingArea\AndroidManifest-main.xml:1, E:\Unity3DProjects\vr360\Temp\StagingArea\android-libraries\vrlib\AndroidManifest.xml:8] Main manifest has <uses-feature android:glEsVersion='0x00010000'> but library uses glEsVersion='0x00030000'
Note: main manifest lacks a <uses-feature android:glEsVersion> declaration, and thus defaults to glEsVersion=0x00010000.
]
exit code: 1
UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.HostView:OnGUI()

 

解决:

这是opengl版本不一致导致的,修改Assets/Plugins/Android/AndroidManifest.xml,修改glEsVersion版本即可,

<uses-feature android:glEsVersion="0x00030000" android:required="true" />


发表评论
切换编辑模式