No changes to testflight and Xcode 5 libraries now say "ld: library not found for -lTestFlight"

I have been creating some kind of application for several months and Suddently Xcode 5 does not want to create it. He simply complains about the following error.

Ld build/Debug-iphonesimulator/appname.app/appname normal i386 cd /Users/myname/proyectos/appname/dev/iOS/appname setenv IPHONEOS_DEPLOYMENT_TARGET 5.1 setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk -L/Users/myname/proyectos/appname/dev/iOS/appname/build/Debug-iphonesimulator -L\"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/FlurryAnalytics\" -L\"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/SmartADServer\" -L\"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/TestFlight\" -F/Users/myname/proyectos/appname/dev/iOS/appname/build/Debug-iphonesimulator -F/Users/myname/proyectos/appname/dev/iOS/appname/appname/External -filelist /Users/myname/proyectos/appname/dev/iOS/appname/build/appname.build/Debug-iphonesimulator/Appname.build/Objects-normal/i386/appname.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=5.1 -weak_framework AdSupport -framework Security -framework MessageUI -framework Twitter -framework CoreLocation -weak_framework CoreMotion -framework AudioToolbox -framework AVFoundation -framework MediaPlayer -framework SystemConfiguration -framework MobileCoreServices -lz -framework CFNetwork -framework QuartzCore -framework UIKit -framework Foundation -framework CoreGraphics -lTestFlight -framework comScore -lFlurry -Xlinker -dependency_info -Xlinker /Users/myname/proyectos/appname/dev/iOS/appname/build/appname.build/Debug-iphonesimulator/Appname.build/Objects-normal/i386/appname_dependency_info.dat -o /Users/myname/proyectos/appname/dev/iOS/appname/build/Debug-iphonesimulator/appname.app/appname ld: warning: directory not found for option '-L"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/FlurryAnalytics"' ld: warning: directory not found for option '-L"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/SmartADServer"' ld: warning: directory not found for option '-L"/Users/myname/proyectos/appname/dev/iOS/appname/appname/External/TestFlight"' ld: library not found for -lTestFlight clang: error: linker command failed with exit code 1 (use -v to see invocation) 

If I understand this, he complains about testflight, but I haven't changed anything about this in a few weeks. He compiled it perfectly.

I have to say that I tried to add the Adobe ADMS tracking library to the project (but then canceled its addition). And then after that linker errors appear.

Any hint? I TOTALLY lost and disappointed. Perhaps my project files are corrupted? (Let him hope not!) Any hope of their recovery in this case?

Hello

+6
source share
5 answers

"Problem resolved."

Apparently, it seemed (as ahwulf said, and I suspected) that my project paths / libraries / headers were somehow corrupted inside Xcode 5.

What was my decision? After additional tests, I just physically removed some of my apparently conflicting libraries (testflight, flurry, etc.) from the project (and ALSO from disk) and started compiling, waiting for obvious compilation errors to appear.

When they appeared, I just added the files. Xcode asked me to add (one file / library at a time), and then one by one, all these errors started to disappear slowly. My original binding error ALSO disappeared, so my project is under construction again.

I have a feeling that I really don’t know what I did, but "it worked."

+9
source

Something that worked for me in this situation was to remove “libTestFlight.a” from the “Linking Binary Files to Libraries” section in the “Assembling Phases” section and clear my project and then redoing it into this section from my file tree. (Of course, if you want to use Testflight in your application, make sure that you also have libz.dylib as the framework, and the related TestFlight files are also included in your project, for example TestFlight.h, TeshFlight + AsyncLogging.h and TestFlight + ManualSession.h - if libz.dylib is deleted and then read, this may cause this error). Warriors of a lucky code!

+1
source

Xcode 5 has an error in which it automatically adds an additional absolute path in the build settings. He bit me a couple of times.

0
source

I had an identical error for a completely different reason.

After upgrading from TestFlight 1.2.4 to TestFlight 2.0.2, the assembly worked on my own machine, but the nightly assembly on another machine failed.

The simple reason the library was not found was because it was not executed. Our .gitignore is set to ignore .a files, so libTestFlight.a was not included. Opening a project in Xcode made this more obvious than the command line build log.

git add -f this is sorted.

0
source

I ran into the same issue by adding TestFlight 2.0.2 . And it also ran counter to Flurry (and some others). Removing (link!) And re-adding all conflicting libraries with the latter helped me. But first, do not forget to remove the Library Search Paths .

0
source

Source: https://habr.com/ru/post/955608/


All Articles