Raphael Oliveira
Raphael Oliveira

Reputation: 7841

Integration error with Cocoapods and XCode5

When building my project in the new XCode5, I receive the following warning: Pods-App was rejected as an implicit dependency for 'libPods-App.a' because its architectures 'i386' didn't contain all required architectures 'x86_64'.

Upvotes: 27

Views: 14371

Answers (7)

dslowin
dslowin

Reputation: 31

I had this same issue. The warning suggested that the pod library was not included and as a result, the app failed to finish compiling. (It complained about a missing header file that was part of a Pod dependency).

If you are experiencing the same compilation issue, you might be able to resolve it with the following:

  1. Select Pods project in the workspace
  2. Select Pods project to access Pods project-wide settings
  3. Go to Build Settings
  4. Search for 'Build Active Architecture Only'
  5. Set to 'NO'

This seemed to work for me, but YMMV.

Upvotes: 0

Mehul Chuahan
Mehul Chuahan

Reputation: 752

Go to Project "pods", set "build active architecture only" to NO for debug.

Above solution is working for me.

Upvotes: 2

Enrico Susatyo
Enrico Susatyo

Reputation: 19790

I have just upgraded one of my projects to Xcode 6 and experienced this problem. To fix it, I changed the Base SDK of the Pods project to a real one (previously it was like unknown SDK).

enter image description here

Upvotes: 0

Shahid Aslam
Shahid Aslam

Reputation: 2585

Take a look at the blog post here, it will do the work.

To make your Applications compatible for iPhone 5s and older models (till iPhone 3Gs running iOS6), select the following option for your architectures – “Standard Architectures – armv7, armv7s”. Do not select the option that says “Standard Architectures (including 64 bit)…”. Since the Arm instruction sets are backward compatible, any application compiled for armv7s will also run on the iPhone 5s or the iPhone 5c.

ARCHS = armv7 armv7s

For valid architectures in the build settings, you can specify arm64, armv7, armv7s.

VALID_ARCHS = armv6 armv7 armv7s arm64

Upvotes: 10

yonix
yonix

Reputation: 12257

Non of the other answers worked for me.

What eventually solved it for me is to make sure Build Active Architecture Only is set to Yes for Debug and No for Release in my app's xcodeproj file.

Also, because I have custom configurations, I had to add the following to the Podfile:

xcodeproj 'MyApp.xcodeproj', 'MyDebugConfiguration' => :debug, 'MyReleaseConfiguration' => :release

Upvotes: 18

Raphael Oliveira
Raphael Oliveira

Reputation: 7841

To fix that, select the Pods project in the left menu, then under the targets section select the Pods-#YourAppName# target and in the build settings click on the Architectures and press delete so it goes to the default option (Standard architectures (armv7, armv7s). More information can be found in this link.

Upvotes: 28

rjyo
rjyo

Reputation: 226

env:

  • CocoaPods v0.24.0
  • Xcode 5 from App Store

Add the following at the end of your Podfile.

post_install do |installer|
  installer.project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ARCHS'] = "$(ARCHS_STANDARD_INCLUDING_64_BIT)"
    end
  end
end

Upvotes: 7

Related Questions