Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

ld: Assertion failed: (atom->fixupCount() == 1), function targetClassName

Hi all,


I get an error when linking my static library (Strip style: Non-Global Symbols) to my application for i386 architechture

Assertion failed: (atom->fixupCount() == 1)

The linking works fine when building for armv7 or armv7s so the problem only occurs for i386 (the emulator).


Does anyone have a clue how to get around this problem?


0 0x10ecde098 __assert_rtn + 144

1 0x10ecf33b2 mach_o::relocatable::ObjC2ClassRefsSection<x86>::targetClassName(mach_o::reloca table::Atom<x86> const*, ld::IndirectBindingTable const&) const + 136

2 0x10ecf3219 mach_o::relocatable::ObjC2ClassRefsSection<x86>::contentHash(mach_o::relocatabl e::Atom<x86> const*, ld::IndirectBindingTable const&) const + 9

3 0x10ecf141e mach_o::relocatable::Atom<x86>::contentHash(ld::IndirectBindingTable const&) const + 42

4 0x10ed17d53 std::__1::__hash_iterator<std::__1::__hash_node<std::__1::pair<ld::Atom const*, unsigned int>, void*>*> std::__1::__hash_table<std::__1::pair<ld::Atom const*, unsigned int>, std::__1::__unordered_map_hasher<ld::Atom const*, unsigned int, ld::tool::SymbolTable::ReferencesHashFuncs, true>, std::__1::__unordered_map_equal<ld::Atom const*, unsigned int, ld::tool::SymbolTable::ReferencesHashFuncs, true>, std::__1::allocator<std::__1::pair<ld::Atom const*, unsigned int> > >::find<ld::Atom const*>(ld::Atom const* const&) + 37

5 0x10ed1713f ld::tool::SymbolTable::findSlotForReferences(ld::Atom const*, ld::Atom const**) + 111

6 0x10ed1b7b6 ld::tool::Resolver::convertReferencesToIndirect(ld::Atom const&) + 124

7 0x10ed1b59e ld::tool::Resolver::doAtom(ld::Atom const&) + 802

8 0x10ecf4e56 mach_o::relocatable::File<x86>::forEachAtom(ld::File::AtomHandler&) const + 54

9 0x10ed1476c ld::tool::InputFiles::forEachInitialAtom(ld::File::AtomHandler&) + 420

10 0x10ed1d884 ld::tool::Resolver::resolve() + 44

11 0x10ecde380 main + 370

12 0x10eccfcd4 start + 52

A linker snapshot was created at:

/tmp/EncapUI-2012-11-12-170500.ld-snapshot

ld: Assertion failed: (atom->fixupCount() == 1), function targetClassName, file /SourceCache/ld64/ld64-136/src/ld/parsers/macho_relocatable_file.cpp, line 4973.

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

Posted on Dec 12, 2012 11:55 PM

Reply
1 reply

ld: Assertion failed: (atom->fixupCount() == 1), function targetClassName

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.