# Unity 2021.1.0f1 + FMOD 2.01.07 il2cpp build failed

**URL:** <https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933>\
**Category:** Unity\
**Tags:** unity, cpp\
**Created:** [March 24, 2021, 9:57am UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933 "2021-03-24T09:57:16Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Racot\_A](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/racot_a/32/362_2.png) [@Racot\_A](https://qa.fmod.com/u/Racot_A)\
**Post date:** [March 24, 2021, 9:57am UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/1 "2021-03-24T09:57:16Z")

</div>

UPD: Updating to v2.01.08 not fixed the problem ☹  
I founded this post [Unity2020 android export project error when il2cpp copy fmod\_register\_static\_plugins.cpp](https://qa.fmod.com/t/unity2020-android-export-project-error-when-il2cpp-copy-fmod-register-static-plugins-cpp/16660)

Any news about v2.01.09 of fixes variants for my problem?

Console logs

```
Exception: Unity.IL2CPP.Building.BuilderFailedException: fmod_register_static_plugins.cpp
D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\Il2cppBuildCache\Windows\x64\il2cppOutput\fmod_static_plugin_support.h(48): error C2660: 'il2cpp::os::LibraryLoader::LoadDynamicLibrary': function does not take 1 arguments
D:\Programs\2021.1.0f1\Editor\Data\il2cpp\libil2cpp\os/LibraryLoader.h(41): note: see declaration of 'il2cpp::os::LibraryLoader::LoadDynamicLibrary'
D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\Il2cppBuildCache\Windows\x64\il2cppOutput\fmod_static_plugin_support.h(57): error C2661: 'il2cpp::os::LibraryLoader::GetFunctionPointer': no overloaded function takes 2 arguments

Invocation was: Executable: "D:\Programs\Microsoft\VisualStudio\Community\VC\Tools\MSVC\14.28.29333\bin\HostX64\x64\cl.exe"
Arguments: "D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\Il2cppBuildCache\Windows\x64\il2cppOutput\fmod_register_static_plugins.cpp" /nologo /c /bigobj /W3 /Z7 /EHs /GR- /Gy /utf-8 /wd4102 /wd4800 /wd4056 /wd4190 /wd4723 /wd4467 /wd4503 /wd4996 /wd4200 /wd4834 /Ox /Oi /Oy- /GS- /Gw /GF /Zo /MT /DNET_4_0 /DUNITY_AOT /DIL2CPP_MONO_DEBUGGER_DISABLED /DGC_NOT_DLL /DRUNTIME_IL2CPP /DIL2CPP_ENABLE_WRITE_BARRIERS=1 /DIL2CPP_INCREMENTAL_TIME_SLICE=3 /DBASELIB_INLINE_NAMESPACE=il2cpp_baselib /D_WIN32 /DWIN32 /DWIN32_THREADS /D_WINDOWS /DWINDOWS /D_UNICODE /DUNICODE /D_CRT_SECURE_NO_WARNINGS /D_SCL_SECURE_NO_WARNINGS /D_WINSOCK_DEPRECATED_NO_WARNINGS /DNOMINMAX /D_NDEBUG /DNDEBUG /DWINDOWS_SDK_BUILD_VERSION=18362 /DWINAPI_FAMILY=WINAPI_FAMILY_DESKTOP_APP /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\libil2cpp" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\libil2cpp" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\external\bdwgc\include" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\external\xxHash" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\external\baselib\Include" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\external\baselib\Platforms\Windows\Include" /I"D:\Programs\2021.1.0f1\Editor\Data\il2cpp\libil2cpp\pch" /I"D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\Il2cppBuildCache\Windows\x64\il2cppOutput" /I"D:\Programs\Microsoft\VisualStudio\Community\VC\Tools\MSVC\14.28.29333\include" /I"D:\Windows Kits\10\Include\10.0.18362.0\shared" /I"D:\Windows Kits\10\Include\10.0.18362.0\um" /I"D:\Windows Kits\10\Include\10.0.18362.0\winrt" /I"D:\Windows Kits\10\Include\10.0.18362.0\ucrt" /Fo"D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\il2cpp_cache\29FEA426BE6B3DA5CA15ABC906394005.obj" /Fd"D:\Projects\BAG\COLD_DEPTH\ColdDepthSource\Library\il2cpp_cache\29FEA426BE6B3DA5CA15ABC906394005.pdb"
EnvArg key: PATH value: D:\Windows Kits\10\bin\10.0.18362.0\x64;D:\Windows Kits\10\bin\x64;D:\Windows Kits\10\bin\10.0.18362.0\x86;D:\Windows Kits\10\bin\x86;D:\Programs\Microsoft\VisualStudio\Community\VC\Tools\MSVC\14.28.29333\bin\HostX64\x64

   at Unity.IL2CPP.Building.CppProgramBuilder.BuildAllCppFiles(IEnumerable`1 sourceFilesToCompile, IBuildStatisticsCollector statisticsCollector)
   at Unity.IL2CPP.Building.CppProgramBuilder.Build(IBuildStatistics& statistics)
   at il2cpp.Compilation.CompilationDriver.Run(RuntimePlatform platform, BuildingOptions buildingOptions, ReadOnlyCollection`1 matchedAssemblyMethodSourceFiles)
   at il2cpp.Program.DoRun(String[] args, RuntimePlatform platform, BuildingOptions buildingOptions, Boolean throwExceptions)
```

---

<div class="post-metadata">

**Author:** ![KandyMan1990](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/kandyman1990/32/1835_2.png) [@KandyMan1990](https://qa.fmod.com/u/KandyMan1990)\
**Post date:** [March 24, 2021, 8:17pm UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/2 "2021-03-24T20:17:34Z")

</div>

I’m also seeing this issue. No problems on Unity 2020.3.0 LTS, as soon as I updated to 2021.1 I can no longer build. A fix would be much appreciated

---

<div class="post-metadata">

**Author:** ![mathew](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/mathew/32/431_2.png) [@mathew](https://qa.fmod.com/u/mathew)\
**Post date:** [March 29, 2021, 10:29pm UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/3 "2021-03-29T22:29:44Z")

</div>

This issue has been fixed in v2.01.09 which we are getting close to releasing.

A potential work around is described here:

> [@Fmod\_register\_static\_plugins.cpp not found](https://qa.fmod.com/t/fmod-register-static-plugins-cpp-not-found/16728/5):
>
> This issue is also fixed pending our next release. To work around it first remove the additional CPP settings from the file ProjectSettings/ProjectSettings.asset, search for additionalIl2CppArgs: and remove the FMOD files. To disable the cause of this edit Assets\Plugins\FMOD\src\Runtime\Settings.cs modify the function PreprocessBuild to remove the call to PreprocessStaticPlugins. This will disable any static plugins, but is necessary to work around the issue. Everything will work correctly in…

---

<div class="post-metadata">

**Author:** ![Racot\_A](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/racot_a/32/362_2.png) [@Racot\_A](https://qa.fmod.com/u/Racot_A)\
**Post date:** [April 2, 2021, 11:43am UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/4 "2021-04-02T11:43:28Z")

</div>

> [@mathew](#):
>
> A potential work around is described here

Thanks for trying to help me. It’s a pity that this option doesn’t work for me.  
Maybe I’m doing something wrong.

I hope v2.01.09 is released soon.

 ![Args](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/4/48b2e6cbf44ad09fd6f39504a87edf873782b992.png) ![Settings](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/7/7e50d84241b891e5be29349cb43d3924d95941e7.png)

---

<div class="post-metadata">

**Author:** ![mathew](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/mathew/32/431_2.png) [@mathew](https://qa.fmod.com/u/mathew)\
**Post date:** [April 6, 2021, 4:09am UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/5 "2021-04-06T04:09:54Z")

</div>

Can you check your Unity project for the file fmod\_register\_static\_plugins.cpp, if you find it, delete it.

We are aiming to do a release this week provided QA gives the all clear.

---

<div class="post-metadata">

**Author:** ![Racot\_A](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/racot_a/32/362_2.png) [@Racot\_A](https://qa.fmod.com/u/Racot_A)\
**Post date:** [April 6, 2021, 7:22am UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/6 "2021-04-06T07:22:01Z")

</div>

I find the only fmod\_static\_plugin\_support.h file and try to remove it. It doesn’t help too.  
Be waiting for a v2.01.09

---

<div class="post-metadata">

**Author:** ![Racot\_A](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/racot_a/32/362_2.png) [@Racot\_A](https://qa.fmod.com/u/Racot_A)\
**Post date:** [April 16, 2021, 2:27pm UTC](https://qa.fmod.com/t/unity-2021-1-0f1-fmod-2-01-07-il2cpp-build-failed/16933/7 "2021-04-16T14:27:55Z")

</div>

> [@Racot\_A](#):
>
> Be waiting for a v2.01.09

This issue is fixed after the update to v2.01.09.  
Thanks
