X-Code 8 beta 2 Apple Mach-O Linker (id) Error

Hi,

I had a project that worked and built perfectly under iOS with many native plugins, but having troubles with the push native plugin I started playing with cocoa pods to remove an error in XCode about Google Cloud Messaging.

Now whatever I try to do or Roolback, I get this error which I can’t Handle…

I’ve seen this older post about a question that looked very similar but it didn’t help.

Ionic Info :
Cordova CLI: 6.4.0
Ionic Framework Version: 2.0.0-rc.3
Ionic CLI Version: 2.1.13
Ionic App Lib Version: 2.1.7
Ionic App Scripts Version: 0.0.45
ios-deploy version: 1.9.0
ios-sim version: Not installed
OS: macOS Sierra
Node Version: v6.6.0
Xcode version: Xcode 8.0 Build version 8A218a

XCode Error screen capture (the app won’t run on device till i don’t fix it)

i have same issue, PLS HELP

I had the same problem, so here’s how I solved it.

First, here’s a TL;DR: version:

  • $ brew install ruby (restart the terminal after this, so the new binary starts getting used)
  • check that $ ruby -v is at least 2.2 (mine was 2.4.0p…)
  • $ sudo gem install activesupport -v 4.2.6
  • $ sudo gem install cocoapods
  • $ ionic build ios
  • go to path/to/your/project/platforms/ios/ and open yourproject.xcworkspace

Long version with explanations:

I’m going to write up the whole process, as it was quite convoluted, but you may just need the last few or something.

Firstly, for me, this began with the update of phonegap-plugin-push past 1.8.4. In 1.9.0 they started using CocoaPods, which you need to have installed.

To install CocoaPods you need ruby and its gem installer. For some reason just running sudo gem install cocoapods didn’t work for me. I found this github issue and a few commends down, this is comment solved it. But before all that works, you need to have a newer version of ruby. The issue says 2.2, but I just ran brew install ruby and it upgraded to 2.4.0, which works for me and my colleague. So here are the steps for this part:

$ brew install ruby (restart the terminal after this, so the new binary starts getting used
$ sudo gem install activesupport -v 4.2.6
$ sudo gem install cocoapods

Once this is done, I suggest rerunning ionic build ios. If that doesn’t work, maybe you need to clean your platforms and plugins folders and restore them. For that to work best, check that all your plugins are listed in config.xml and package.json.

MOST IMPORTANT: Once ionic builds ios project, you have to run the xcworkspace file! xcproj won’t work, as the solution contains 2 projects (at least) and your app’s projects is linked to a Pods project. The workspace file has that link stored, while the project file doesn’t.

3 Likes