XCode LD Linker debug error 1 File not found: /usr/lib/libFosl_dynamic.dylib for armv7 architecture

I am getting this error when linking a very complex project and I need to know how best to debug it.

I have included the following environment variables for ld:

export RC_TRACE_ARCHIVES=1
export RC_TRACE_DYLIBS=1
export RC_TRACE_PREBINDING_DISABLED=1

      

And added -t -whyload -whatsloaded options to ld.

Recent posts from ld:

[Logging for XBS] Used indirect dynamic library: /Applications/Xcode6-
    Beta4.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/
    SDKs/iPhoneOS8.0.sdk/
    System/Library/PrivateFrameworks/FaceCore.framework/FaceCore
ld: file not found: /usr/lib/libFosl_dynamic.dylib for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

      

This is a general question on how to debug this error, but in particular I am using XCode 6 beta 4. This may be the cause of the error. I need to use XCode 6 for its dynamic framework capabilities.

Does anyone know what libFosl_dynamic.dylib is? Can anyone provide information on how to determine which object module, static library, or other dylib caused the requirement for this libFosl_dynamic.dylib module to be loaded?

I grep'ed on a derived data directory:

/Users/"user"/Library/Developer/Xcode/
    DerivedData/EngineSdkDemo-gbkxniqxsljcxybhbszrwqyrzdwq

      

and found the file "app" _dependency_info.dat. This file appears to contain a list of libraries that will be loaded, which will result in the library not being found. Recent entries in this file:

...
/Applications/Xcode6-Beta4.app/Contents/Developer/Platforms/
    iPhoneOS.platform/Developer/SDKs/iPhoneOS8.0.sdk/System/
    Library/PrivateFrameworks/FaceCore.framework/FaceCore
/Users/<user>/Library/Developer/Xcode/DerivedData/
    EngineSdkDemo-gbkxniqxsljcxybhbszrwqyrzdwq/Build/Products/
    Debug-iphoneos/libFosl_dynamic.dylib
<Library search path 1>/libFosl_dynamic.dylib
<Library search path 2>/libFosl_dynamic.dylib
<Library search path 3>/libFosl_dynamic.dylib
<Library search path 4>/libFosl_dynamic.dylib
<Library search path 5>/libFosl_dynamic.dylib
...

      

Apparently ld is going through all my library search paths trying to find this file, but it doesn't exist anywhere on my Mac.

(8/3/14) More details: I found in XCode 6 beta 4 of the iOS 8 framework:

/Applications/Xcode6-Beta4.app/Contents/Developer
    /Platforms/iPhoneOS.platform/Developer
    /SDKs/iPhoneOS8.0.sdk/System/Library/Frameworks

      

I found a bump in coreimage.framework. The excellent MacDepencencies tool (here) has specified a dependency on / usr / lib / libFosl _dynamic.dylib. Apparently this is a bug in XCode 6 beta 4. This dylib is not included in the distribution.

(8/3/14) More details: I finally found one of the libFosl_dynamic.dylib files. It was buried in the XCode iOS 8 SDK SDK folders:

/Applications/Xcode6-Beta4.app/Contents/Developer
    /Platforms/iPhoneSimulator.platform/Developer/SDKs
    /iPhoneSimulator8.0.sdk/usr/lib

      

I copied the file to / usr / lib.

Now that the file itself is missing, I get the following following error from the linker:

ld: in '/usr/lib/libFosl_dynamic.dylib', missing required architecture armv7 in file
    /usr/lib/libFosl_dynamic.dylib (2 slices) for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

      

(8/3/14): More: This particular file in the iOS 8 SDK only supports the i386 and X86-64 architectures.

(8/3/14) More details: Of course it only supports i386 and X86-64 architectures! I just noticed that the file is on the iPhoneSimulator.platform. The file is missing from the corresponding iPhoneOS.platform folders.

(8/3/14) Optional: File does not exist in XCode 5.1.1 version of iPhoneOS.platform files (simulator or device). It appears in XCode 6 Beta 2 (Simulator only), which is the first XCode 6 Beta I have. Apparently this question has been introduced since XCode 6.

Thanks Bob

+3


source to share





All Articles