IL2CPP Android Build Failing Unity 2021.3.9f1

I’ve been trying to build my android game with IL2CPP as required to upload on the Google Play Store. It always comes back with these errors

The longest one being the first Error with full text:

Internal build system error. BuildProgram exited with code -2147024809.
Old commandline for Library/Bee/artifacts/Android/iz17e/xl60_le_CodeGen.o:
-march=armv7-a -mfloat-abi=softfp -mfpu=neon-fp16 -marm -D__ARM_ARCH_7__ -D__ARM_ARCH_7A__ -D__ANDROID_API__=22 -DANDROID -DHAVE_INTTYPES_H
-no-canonical-prefixes -funwind-tables -fstack-protector -fdiagnostics-format=msvc -fomit-frame-pointer -Wswitch -Wno-trigraphs -Wno-tautological-compare
-Wno-invalid-offsetof -Wno-implicitly-unsigned-literal -Wno-integer-overflow -Wno-shift-negative-value -Wno-unknown-attributes -Wno-implicit-function-declaratio
n -Wno-null-conversion -Wno-missing-declarations -Wno-unused-value -Wno-pragma-once-outside-header -fvisibility=hidden -fexceptions -g -O2 -fPIC
-fno-strict-overflow -ffunction-sections -fdata-sections -fmessage-length=0 -pipe -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DIL2CPP_MONO_DEBUGGER_DISABLED
-DRUNTIME_IL2CPP -DIL2CPP_ENABLE_WRITE_BARRIERS=1 -DIL2CPP_INCREMENTAL_TIME_SLICE=3 -DHAVE_BDWGC_GC -DNDEBUG -I"."
-I"D:/Programming Projects/Unity Projects/Dutch Shuffleboard/Library/Bee/artifacts/Android/il2cppOutput/cpp"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/libil2cpp/pch" -I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/libil2cpp"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/external/baselib/Include"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/external/baselib/Platforms/Android/Include" -o
“Library/Bee/artifacts/Android/iz17e/xl60_le_CodeGen.o” -fcolor-diagnostics -fdiagnostics-absolute-paths -target armv7a-linux-androideabi22 -fstrict-aliasing
-fdiagnostics-format=msvc -c -x c
“D:/Programming Projects/Unity Projects/Dutch Shuffleboard/Library/Bee/artifacts/Android/il2cppOutput/cpp/UnityEngine.UnityConnectModule_CodeGen.c”

New commandline for Library/Bee/artifacts/Android/iz17e/xl60_le_CodeGen.o:
-march=armv7-a -mfloat-abi=softfp -mfpu=neon-fp16 -marm -D__ARM_ARCH_7__ -D__ARM_ARCH_7A__ -D__ANDROID_API__=22 -DANDROID -DHAVE_INTTYPES_H
-no-canonical-prefixes -funwind-tables -fstack-protector -fdiagnostics-format=msvc -fomit-frame-pointer -Wswitch -Wno-trigraphs -Wno-tautological-compare
-Wno-invalid-offsetof -Wno-implicitly-unsigned-literal -Wno-integer-overflow -Wno-shift-negative-value -Wno-unknown-attributes -Wno-implicit-function-declaratio
n -Wno-null-conversion -Wno-missing-declarations -Wno-unused-value -Wno-pragma-once-outside-header -fvisibility=hidden -fexceptions -g -O2 -fPIC
-fno-strict-overflow -ffunction-sections -fdata-sections -fmessage-length=0 -pipe -DBASELIB_INLINE_NAMESPACE=il2cpp_baselib -DIL2CPP_MONO_DEBUGGER_DISABLED
-DRUNTIME_IL2CPP -DIL2CPP_ENABLE_WRITE_BARRIERS=1 -DIL2CPP_INCREMENTAL_TIME_SLICE=3 -DHAVE_BDWGC_GC -DNDEBUG -I"."
-I"D:/Programming Projects/Unity Projects/Dutch Shuffleboard/Library/Bee/artifacts/Android/il2cppOutput/cpp"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/libil2cpp/pch" -I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/libil2cpp"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/external/baselib/Include"
-I"C:/Program Files/Unity/Hub/Editor/2021.3.9f1/Editor/Data/il2cpp/external/baselib/Platforms/Android/Include" -o
“Library/Bee/artifacts/Android/iz17e/xl60_le_CodeGen.o” -fcolor-diagnostics -fdiagnostics-absolute-paths -target armv7a-linux-androideabi22 -fstrict-aliasing
-fdiagnostics-format=msvc -c -x c
“D:/Programming Projects/Unity Projects/Dutch Shuffleboard/Library/Bee/artifacts/Android/il2cppOutput/cpp/UnityEngine.PhysicsModule_CodeGen.c”
System.ArgumentException: AddAction invocation conflicts with earlier invocation for “Library\Bee\artifacts\Android\iz17e\xl60_le_CodeGen.o”: commandLineArguments differ
Previous AddAction was here:

at Bee.Core.Backend.<>c__DisplayClass36_0.b__2(String msg)
at Bee.Core.Backend.AddAction(String actionName, NPath targetFiles, NPath inputs, String executableStringFor, String commandLineArguments, Boolean supportResponseFile, Dictionary2 environmentVariables, NPath[] rspAndBatchFiles, Boolean allowUnexpectedOutput, Boolean allowUnwrittenOutputFiles, Boolean banContentDigestForInputs, String[] allowedOutputSubstrings, NPath[] unavoidableOutputs, NPath[] targetDirectories, String[] sharedResources, Nullable1 deleteOutputsBeforeRun, NPath filesThatMightBeIncluded, CachingMode cachingMode, NPath cachingInputIgnoreList, NPath profilerOutput, String responseFileSeparator)
at Bee.NativeProgramSupport.CLikeCompiler.SetupInvocation(NPath objectFile, CLikeCompilationUnitInstruction cLikeCompilationUnitInstruction)
at Bee.NativeProgramSupport.CLikeCompilationUnitInstruction.AddActionFor(NPath objectFile)
at Bee.NativeProgramSupport.NativeProgram.SetupObjectFilesAndSetupBuiltNativeProgram(String outputFilenameWithoutExtension, NativeProgramConfiguration config, NativeProgramFormat format, ArtifactLocationPolicy artifactLocationPolicy, ObjectFileProductionInstructions allUnits, NPath additionalObjectFiles, ILibrary libraries, NPath knownHeaders)
at Bee.NativeProgramSupport.NativeProgram.SetupSpecificConfigurationImpl(NativeProgramConfiguration config, NativeProgramFormat format, ObjectFileProducer objectFileProducers)
at Bee.NativeProgramSupport.NativeProgram.SetupSpecificConfiguration(NativeProgramConfiguration config, NativeProgramFormat format, ObjectFileProducer objectFileProducers)
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.SetupIl2CppBuild()
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.SetupPlayerBuild()
at AndroidPlayerBuildProgram.AndroidPlayerBuildProgram.SetupPlayerBuild()
at PlayerBuildProgramLibrary.PlayerBuildProgramBase.RunBuildProgram()
at PlayerBuildProgramTypeWrapper.Run(String args)
at Program.Main(String args)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

I tried changing building release, internal and external install locations, installing .Net Framework, disabling incremental Garbage Collection, changing IL2CPP Code Generation between Faster Runtime and smaller builds, changing API Compatibility level, changing target architectures, deleting the library folder, deleting the Bee folder in the library, deleting Temp.

I am at a complete loss…

If anyone has a way to help it would be greatly appreciated.
Thank you for reading :slight_smile:

there are many diffrent answears here but this is the last one.

https://forum.unity.com/threads/internal-build-system-error-backend-exited-with-code-after-upgrade-to-2021-1-4f1-stable.1098451/

hope this is what your searching for

So I managed to fix the problem by creating a new project and importing the assets and manually going back to put the project settings back to how they were. It was a project made with an older version of Unity and maybe incompatible when changing to a newer version of Unity

I had a similar problem. In my case, I have moved the Unity project from one folder to another. Normally it should be fine but it throws errors when I was building for Android. It is very strange.
Finally, I fixed the issue by deleting the project and cloning it again.