I upgraded Unity to latest today (2019.2.16f1), deleted the project’s Library folder, opened it for macOS to force it to rebuild the Library folder, and it successfully created a macOS build.
With a new Library folder, I converted it to iOS and built to Xcode. Then opening Xcode, I got the same Build Failure for the same reason, iPhone Library not found.
'ld: library not found for -liPhone-lib
clang: error: linker command failed with exit code 1 (use -v to see invocation)’
Since no Workspace file was created, and having seen opening it from the Workspace can resolve this in other similar but not exact forum thread posts around the Internet and in this thread, I went to File and Save as Workspace. I created a Workspace file in the same directory as the Xcode project. I quit Xcode. I opened the Workspace file, opening Xcode and the project, which appeared identical. I tried to build…
Fail. Same reason.
And yet, here is the iPhone Library just as Unity built it for Xcode. I compared this with a fresh Unity project that successfully created an iOS Xcode project that built to iPhone and it was identical.
Why is the error looking for ‘-liPhone-lib’ when the file itself is ‘libiPhone-lib’? I tried duplicating the .a archive and renaming it either ‘-liPhone-lib’ or ‘liPhone-lib’ and this also failed, no help.
Also here is the libiPhone-lib listed under General: Frameworks, Libraries, and Embedded Content:
Also, while I didn’t install any Xcode plug-ins myself, I checked anyway and forum threads say they are stored here:
~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/
However, the path ends at Developer. There’s no Shared or Xcode folder in there.
Someone please help… How do we resolve this?