Il2cpp.exe crashing

Windows 7 reports the crash of il2cpp.exe, when checking in the console there is an error. The error references something in a .c file that should only be used for iOS. This might be the cause of the crash, but I will only know if I can somehow exclude these files. This is generally something I am curious about, how do you exclude anything from a build. I did find some info that files/folders starting with ./~ are excluded so I renamed the IOS folder to ~IOS. This did not help. Either il2cpp ignores that change or there is more I do not understand.

Failed running I:\Unity\Editors\2019.3.13f1\Editor\Data\il2cpp/build/deploy/net471/il2cpp.exe --convert-to-cpp --emit-null-checks --enable-array-bounds-check --dotnetprofile=“unityaot” --compile-cpp --libil2cpp-static --platform=“Android” --architecture=“ARMv7” --configuration=“Release” --outputpath=“I:\Unity\BulletWalker\Temp\StagingArea\assets\bin\Data\Native\armeabi-v7a\libil2cpp.so” --cachedirectory=“I:\Unity\BulletWalker\Assets..\Library\il2cpp_android_armeabi-v7a/il2cpp_cache” --additional-include-directories=“I:/Unity/Editors/2019.3.13f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\bdwgc/include” --additional-include-directories=“I:/Unity/Editors/2019.3.13f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools\libil2cpp/include” --tool-chain-path=“I:/Unity/Editors/2019.3.13f1/Editor/Data/PlaybackEngines/AndroidPlayer/NDK” --profiler-report --map-file-parser=I:/Unity/Editors/2019.3.13f1/Editor/Data/Tools/MapFileParser/MapFileParser.exe --directory=I:/Unity/BulletWalker/Temp/StagingArea/assets/bin/Data/Managed --generatedcppdir=I:/Unity/BulletWalker/Temp/StagingArea/Il2Cpp/il2cppOutput

stdout:
Building libil2cpp.so with AndroidToolChain
Output directory: I:\Unity\BulletWalker\Temp\StagingArea\assets\bin\Data\Native\armeabi-v7a
Cache directory: I:\Unity\BulletWalker\Library\il2cpp_android_armeabi-v7a\il2cpp_cache
il2cpp.exe didn’t catch exception: Unity.IL2CPP.Building.BuilderFailedException: I:\Unity\BulletWalker\Temp\StagingArea\Il2Cpp\il2cppOutput\intercept.c:12:10: fatal error: ‘ffmpeg_wrapper.h’ file not found
#include “ffmpeg_wrapper.h”
^~~~~~~~~~~~~~~~~~
1 error generated.

I just deleted the IOS folder and this fixes the crash, so ~IOS does not do the trick with il2cpp. How do I exclude a folder without deleting it? Is there a good method for handling different build and excluding/including specific files. Would also be interesting for including the SteamSDK or similar stuff that is dependent on the release platform.

when you click on that c file in Editor, you should see a plugin inspector, select iOS as only compatible platform

Very nice! Thank you so much Tomas. Looks like I need to import the unity-IOS-module to be able to select it, but that should be fine.
edit: would be even more awesome if this setting could be applied to a folder :smile: