Search Unity

  1. We are looking for your feedback about Templates! Tell us about your experiences by taking our survey.
    Dismiss Notice
  2. Curious about what's going to be in 2021.1? Have a look at the 2021.1 beta blog post.
    Dismiss Notice
  3. Want to see 2021.1b in action? Sign up for our 2021.1 Beta Webinar on February 25 for a live presentation and a Q&A session with guests from R&D.
    Dismiss Notice

Help Wanted android build error on 2020.2.0a10

Discussion in '2020.2 Beta' started by trumanita, May 8, 2020.

  1. trumanita

    trumanita

    Joined:
    Feb 2, 2012
    Posts:
    20
    Hi,
    when I build on Android target I have this error:

    Win32Exception: ApplicationName='C:\Program Files\Unity\Hub\Editor\2020.2.0a10\Editor\Data\il2cpp/build/deploy/netcoreapp3.0/il2cpp.exe', CommandLine='--convert-to-cpp --emit-null-checks --enable-array-bounds-check --dotnetprofile="unityaot" --compile-cpp --libil2cpp-static --platform="Android" --architecture="ARMv7" --configuration="Release" --outputpath="C:\Users\giuseppei\OneDrive - Agic Technology srl\Documenti\Unity\MyGPViewer4.0\Temp\StagingArea\assets\bin\Data\Native\armeabi-v7a\libil2cpp.so" --cachedirectory="C:\Users\giuseppei\OneDrive - Agic Technology srl\Documenti\Unity\MyGPViewer4.0\Assets\..\Library\il2cpp_android_armeabi-v7a/il2cpp_cache" --additional-include-directories="C:/Program Files/Unity/Hub/Editor/2020.2.0a10/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\bdwgc/include" --additional-include-directories="C:/Program Files/Unity/Hub/Editor/2020.2.0a10/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\libil2cpp/include" --baselib-directory="C:/Program Files/Unity/Hub/Editor/2020.2.0a10/Editor/Data/PlaybackEngines/AndroidPlayer\Variations\il2cpp\Release\StaticLibs\armeabi-v7a" --avoid-dynamic-library-copy --tool-chain-path="C:/Program Files/Unity/Hub/Editor/2020.2.0a10/Editor/Data/PlaybackEngines/AndroidPlayer/NDK" --profiler-report --map-file-parser="C:/Program Files/Unity/Hub/Editor/2020.2.0a10/Editor/Data/Tools/MapFileParser/MapFileParser.exe" --directory="C:/Users/giuseppei/OneDrive - Agic Technology srl/Documenti/Unity/MyGPViewer4.0/Temp/StagingArea/assets/bin/Data/Managed" --generatedcppdir="C:/Users/giuseppei/OneDrive - Agic Technology srl/Documenti/Unity/MyGPViewer4.0/Temp/StagingArea/Il2Cpp/il2cppOutput" ', CurrentDirectory='C:\Users\giuseppei\OneDrive - Agic Technology srl\Documenti\Unity\MyGPViewer4.0\Temp\StagingArea\assets\bin\Data\Managed', Native error= Per eseguire l'operazione richiesta è necessaria l'esecuzione con privilegi elevati.

    System.Diagnostics.Process.StartWithCreateProcess (System.Diagnostics.ProcessStartInfo startInfo) (at <525dc68fbe6640f483d9939a51075a29>:0)
    System.Diagnostics.Process.Start () (at <525dc68fbe6640f483d9939a51075a29>:0)
    (wrapper remoting-invoke-with-check) System.Diagnostics.Process.Start()
    UnityEditor.Utils.Program.Start (System.EventHandler exitCallback) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditor.Utils.Program.Start () (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.Runner.RunProgram (UnityEditor.Utils.Program p, System.String exe, System.String args, System.String workingDirectory, UnityEditor.Scripting.Compilers.CompilerOutputParserBase parser) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.Runner.RunNetCoreProgram (System.String exe, System.String args, System.String workingDirectory, UnityEditor.Scripting.Compilers.CompilerOutputParserBase parser, System.Action`1[T] setupStartInfo) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.IL2CPPBuilder.RunIl2CppWithArguments (System.Collections.Generic.List`1[T] arguments, System.Action`1[T] setupStartInfo, System.String workingDirectory) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.IL2CPPBuilder.ConvertPlayerDlltoCpp (UnityEditor.Il2Cpp.Il2CppBuildPipelineData data, System.String outputDirectory, System.String workingDirectory, System.Boolean platformSupportsManagedDebugging) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.IL2CPPBuilder.Run () (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditorInternal.IL2CPPUtils.RunIl2Cpp (System.String tempFolder, System.String stagingAreaData, UnityEditorInternal.IIl2CppPlatformProvider platformProvider, System.Action`1[T] modifyOutputBeforeCompile, UnityEditor.RuntimeClassRegistry runtimeClassRegistry) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEditor.Android.PostProcessor.Tasks.RunIl2Cpp.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <a0981cc1e303442ba956b32a5bc87fa9>:0)
    UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at <a0981cc1e303442ba956b32a5bc87fa9>:0)
    UnityEditor.Android.PostProcessAndroidPlayer.PostProcess (UnityEditor.BuildTarget target, System.String stagingAreaData, System.String stagingArea, System.String playerPackage, System.String installPath, System.String companyName, System.String productName, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <a0981cc1e303442ba956b32a5bc87fa9>:0)
    UnityEditor.Android.AndroidBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <a0981cc1e303442ba956b32a5bc87fa9>:0)
    UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <599a88f0dc984e9a84071cb802b80734>:0)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)


    I tried to run command with elevated privileges by cmd and I have 20 errors:

    C:\Users\giuseppei\OneDrive - Agic Technology srl\Documenti\Unity\MyGPViewer4.0\Temp\StagingArea\Il2Cpp\il2cppOutput\Assembly-CSharp4.cpp:20736:71: error: token is not a valid binary operator in a preprocessor subexpression
    #if FORCE_PINVOKE_INTERNAL || FORCE_PINVOKE_LogitechLedEnginesWrapper _INTERNAL


    Can you help me?

    Thanks in advance
     
  2. Schodemeiss

    Schodemeiss

    Joined:
    Jan 4, 2018
    Posts:
    25
    I had a similar problem on an older version of Unity, it has to do with spaces " " in the path names. I see yours contains "OneDrive - Agic Technology srl". Perhaps try moving the project to a folder that doesn't contain spaces?
     
  3. trumanita

    trumanita

    Joined:
    Feb 2, 2012
    Posts:
    20
    I've solved: I had a problem on a DllImport on a class (whitespace to be removed")
    Also I have to launch UnityHub with elevated privileges
    Thanks
     
    Schodemeiss likes this.
unityunity