XCode 12.3 building for iOS Simulator, but linking in dylib built for iOS, couchbaselite framework for architecture arm64 Using M1 Chipset
Asked Answered
C

2

5

Encountered a build issue on IOS too with "building for iOS Simulator, but linking in dylib built for iOS, file '.../platforms/ios/Pods/CouchbaseLite/iOS/CouchbaseLite.framework/CouchbaseLite' for architecture arm64"

I currently using nativescript 6.5.3 and cocoapod 1.10. Using M1 chipset.

Celadon answered 3/1, 2021 at 11:53 Comment(1)
Same boat: I'm on circleci - cocoapods 10.1, builds for simulator (same error) "building for iOS, but linking in dylib file ... built for iOS Simulator"Inefficient
F
3
  1. Go to TARGET (e.g. Runner in my screen, not the PROJECT), then Build Settings
  2. Search for excluded like in screenshot.
  3. Edit the field in Architectures > Excluded Architectures, to add arm64. You can double click the top line to edit all 3 lines below.
  4. Rebuild/ run

Screenshot of IDE showing architectures section which contains exluded architectures subsection, which as Debug, Profile, Release subsections. Edit all of them to contain arm64

My details: Running on M1 mac mini, with a flutter iOS project.

Feline answered 11/1, 2021 at 20:28 Comment(0)
H
3

Since Xcode is a Universal Application, You can make Xcode to use the intel based logic even in the m1 mac mini for a quick fix and then try to find the cause and fix it if you can:

  1. Quit Xcode.
  2. Right-click on Xcode.app (the application itself! NOT the one in the dock and NOT the project file)
  3. Select Get info.
  4. Select "Open using Rosetta" or "Open using Rosetta 2"
  5. Launch Xcode and Run your project.

Xcode get info example

Hashish answered 5/1, 2022 at 8:6 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.