In the Library Search Paths section of our Xcode project, we list:
"$(SRCROOT)/../native_rust_library/target/aarch64-apple-ios/release", "$(SRCROOT)/../native_rust_library/target/x86_64-apple-ios/release",
When we build for Any iOS Device (arm64), Xcode locates the arm64 static library in the first search path. Then, when we build for Simulator (x86_64), Xcode again locates the arm64 static library in the first search path, and we get an error.
If we haven't previously built for Any iOS Device (arm64), when we build for Simulator (x86_64), Xcode doesn't find anything in the first search path, locates the x86_64 static library in the second search path, and builds successfully.
The solution is to set the search paths conditionally.