iOS Build Environment Help Center

Building from commandline fails - cannot find il2cpp.exe

append delete shess

Windows Version: Windows 10 Enterprise 19045.3324
Builder Version: 3.59
iOS SDK 16.2
Unity 2022.3.6f1

Running the builder is suddenly failing. I don't know what has changed since the last time it was correctly built, the only thing I can really think of is moving from Unity 2022.3.3f1 to 2022.3.6f1 in the last week or so. I was on Builder version 3.57, updated to latest 3.59, still failing with the same error:

E:\out.ipa>"D:\iOSBuilder\iOS Project Builder for Unity\build.cmd" -xcname "Unity-iPhone" -xcpname "iPhone-target" -xcconf "Release" -archs "arm64" -multicore -pngcrush -autoresolve -ipa -strip bitcode -entitlements "" -prepkgscript "" -artwork "" -identity <IDENTITY> -provision "dev.mobileprovision"
Building the dependency project GameAssembly...
+ Preparing output directory...
+ XCFrameworks: 0 supplied
+ Libraries: 18 supplied, 0 built
+ Frameworks: 0 supplied, 0 built
+ Pre-parsing project files...
+ Building libGameAssembly.a for iphoneos (configuration: Release)
+ Located Unity il2cpp compiler: 2022.3.6f1
pbxprojparse: error: unknown option 'Files/Unity/Hub/Editor/2022.3.6f1/Editor/Data/il2cpp/build/deploy/il2cpp.exe'

usage:
pbxprojparse <project.xcodeproj> [-target <name>] [-configuration <name>]
<command flag [optional parameters]> [other global flags]
...
Error: unable to figure out the IL2CPP command line. Please report this problem.

il2cpp.exe is present, but that output shows the directory as "Files/" instead of "Program Files/" - though I don't know if that's just an output issue?

Thanks, I appreciate your time!

Reply RSS

Replies

append delete #1. Pierre-Marie Baty

Hello shess,

I think I guessed what the problem is. Please open build.cmd with your favorite text editor, go to line 1956, and change:

% build.cmd circa line 1956
	rem // in case we haven't found it, look in %ProgramFiles%\Unity (default Unity install path)
	if "_!IL2CPP!_"=="__" if exist "%ProgramFiles%\Unity\Hub\Editor\!UNITY_RUNTIME_VERSION!\Editor\Data\il2cpp\build\deploy\il2cpp.exe" set IL2CPP="%ProgramFiles%\Unity\Hub\Editor\!UNITY_RUNTIME_VERSION!\Editor\Data\il2cpp\build\deploy\il2cpp.exe"
%

to

% build.cmd circa line 1956, changed
	rem // in case we haven't found it, look in %ProgramFiles%\Unity (default Unity install path)
	if "_!IL2CPP!_"=="__" if exist "%ProgramFiles%\Unity\Hub\Editor\!UNITY_RUNTIME_VERSION!\Editor\Data\il2cpp\build\deploy\il2cpp.exe" set IL2CPP=%ProgramFiles%\Unity\Hub\Editor\!UNITY_RUNTIME_VERSION!\Editor\Data\il2cpp\build\deploy\il2cpp.exe
%

Notice the quotes removed around the IL2CPP path.

Rebuild and let me know if it fixes your problem.

append delete #2. shess

Hello,

Yes! That worked just fine.

Thank you for such a quick response!

cheers!

append delete #3. Pierre-Marie Baty

You’re welcome. I’ll push the fix in the next version.

Reply

(Leave this as-is, it’s a trap!)

There is no need to “register”, just enter the same name + password of your choice every time.

Pro tip: Use markup to add links, quotes and more.

Moderators: Pierre-Marie Baty