Search code examples
xcodelinkerclangllvm-clang

LD: (null): Assertion failed: ("dylib not assigned ordinal"), function compressedOrdinalForAtom, file OutputFile.cpp,


After some editing my Xcode 5.1.0 source files I suddenly get this linker error:

0  0x1059b5f93  __assert_rtn + 144
1  0x105a1d7f5  ld::tool::OutputFile::compressedOrdinalForAtom(ld::Atom const*) + 281
2  0x105a1e469  ld::tool::OutputFile::addDyldInfo(ld::Internal&, ld::Internal::FinalSection*, ld::Atom const*, ld::Fixup*, ld::Fixup*, ld::Fixup*, ld::Atom const*, ld::Atom const*, unsigned long long, unsigned long long) + 2261
3  0x105a14496  ld::tool::OutputFile::generateLinkEditInfo(ld::Internal&) + 1322
4  0x105a0f952  ld::tool::OutputFile::write(ld::Internal&) + 116
5  0x1059b6c40  main + 1012
A linker snapshot was created at:
    /tmp/keytech PLM-2014-03-05-101905.ld-snapshot
ld: Assertion failed: (0 && "dylib not assigned ordinal"), function compressedOrdinalForAtom, file /SourceCache/ld64/ld64-236.3/src/ld/OutputFile.cpp, line 3454.
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I have absolute no idea what this means?

I already tried to:

  • Delete the derived data folder
  • Clean Files and build files
  • Cosed and reopen Xcode
  • Made sure no Linker Optimizer are active: No dead Code Stripping, No Link Time Optimization.

I also have excluded some of my latest changed code. With no result. Googleing the error did not find any useful information.

Does anybody have an idea?


Solution

  • In my case the linker error was gone after I switched in the Build Settings "OSX Deployment Target" from "10.7" to "10.8".