Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Drive SDK and iOS 5.1

Is the SDK compatible with iOS 5 or only with iOS 6 ?

Everything is fine with the Google exemple and iOS 6 (simulator and devices) but Xcode return a runtime error with iOS 5.1 (simulator and devices).

I'm using Xcode 4.5.2.

I've already checked the iOS Deployment target. It's set on 5.1.

Google exemple : https://developers.google.com/drive/quickstart-ios

Runtime error returned :

dyld: lazy symbol binding failed: Symbol not found: _objc_setProperty_nonatomic_copy
 Referenced from: /Users/Borongaj/Library/Application Support/iPhone Simulator/5.1/Applications/FC5B32F0-C5E6-4054-BE81-4F52054AC911/Tests Google Drive.app/Tests Google Drive
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/Foundation.framework/Foundation


dyld: Symbol not found: _objc_setProperty_nonatomic_copy
Referenced from: /Users/Borongaj/Library/Application Support/iPhone Simulator/5.1/Applications/FC5B32F0-C5E6-4054-BE81-4F52054AC911/Tests Google Drive.app/Tests Google Drive
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/Foundation.framework/Foundation
like image 344
Borongaj Avatar asked Dec 27 '22 11:12

Borongaj


1 Answers

I've found the solution.

The Google documentation omit some important things :

  1. watch the Google video instead of reading the Google tutorial (text), because some drag/drop can corrupt Xcode buildings preferences

  2. Add GTLDrive_Sources.m inside Project > Build Phases > Compile Sources

  3. switch the GTL project iOS Deployment Target option to 5.1 (or anything else).

With these three steps, you avoid some boring error message.

Even the Google engineer get same errors during video ! :-)

like image 144
Borongaj Avatar answered Jan 05 '23 17:01

Borongaj