1
votes

I'm trying to use a cocoapod with my Xcode project (Swift).

When I try to Build the project it fails with:

Apple Mach-O Linker Error Group - "_OBJC_CLASS_$_FSCalendar", referenced from: - clang: error: linker command failed with exit code 1 (use -v to see invocation)

Errors

Any ideas what could be causing this?

(The cocoapod I am using is: https://github.com/WenchaoD/FSCalendar

UPDATE

I have added the frameworks and now I am just getting "clang: error: linker command failed with exit code 1 (use -v to see invocation)"

UPDATE

Full error:

ld: warning: directory not found for option '-F/Users/me/Documents/APP/build/Debug-iphoneos/FSCalendar' ld: warning: directory not found for option '-F/Users/me/Documents/APP/build/Debug-iphoneos' ld: framework not found FSCalendar clang: error: linker command failed with exit code 1 (use -v to see invocation)

3
Copy the full error from the issue navigator - Alexander
Those are the full errors - user3227546
No they're not. Double click it. - Alexander
ld: warning: directory not found for option '-F/Users/me/Documents/APP/build/Debug-iphoneos/FSCalendar' ld: warning: directory not found for option '-F/Users/me/Documents/APP/build/Debug-iphoneos' ld: framework not found FSCalendar clang: error: linker command failed with exit code 1 (use -v to see invocation) - user3227546
how did you add the framework? - Hosny

3 Answers

1
votes

I tried everything suggested on the internet for the same issue and nothing resolved this. I fully re-installed Xcode and Cocoapods, set up the project exactly the same as before and it is now working.

0
votes

After I ran pod install on the new name I changed my project to, I had this error cause the pod framework was not linking to NEW project name and was still looking for OLD name.

I resolved by going into my projects 'Linked Frameworks and Libraries' in the Targets section and removing the OLD framework that has the OLD project name.

Targets > General > Linked Frameworks and Libraries > -(Pods_OLD_PROJECT_NAME.framework)

0
votes

I got this error after setting up a new function. Just restart your computer and clean the project (cmd+shift+k) and run.