Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

linker command failed with: ld: file not found

Tags:

xcode

ios

swift

ld: file not found .../Library/Developer/Xcode/DerivedData/.../Universal.app/Universal

clang: error: linker command failed with exit code 1 (use -v to see invocation)

enter image description here

Can you help with this error?

like image 853
user2989513 Avatar asked Dec 06 '25 06:12

user2989513


2 Answers

Try to hit CMD-Alt-K or select Product -> Clean.

like image 155
Roi Mulia Avatar answered Dec 08 '25 20:12

Roi Mulia


I localize this error with simple mistake:

in my project i have 3 files: main.m, SimpleClass.h, SimpleClass.m; some project

in file main, I have written:

#import <Foundation/Foundation.h>
#import "SimpleClass.h"
#import "SimpleClass.m" //Mistake

When I erased the third line, all had built success.

like image 26
Andrew Kachalin Avatar answered Dec 08 '25 18:12

Andrew Kachalin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!