David Garsha
2013-Oct-22 22:24 UTC
[LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
Hi, I'm encountering the following assertion when linking an Xcode project with Xcode 4.6.3 (4H1503). The project has dependencies on, and links against, an Objective-C static library Xcode project, and a C++ static library Xcode project. All are using using LLVM 4.2. ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. 0 0x10fa41098 __assert_rtn + 144 1 0x10fa678af archive::File<x86_64>::makeObjectFileForMember(archive::File<x86_64>::Entry const*) const + 1149 2 0x10fa670fd archive::File<x86_64>::forEachAtom(ld::File::AtomHandler&) const + 645 3 0x10fa7776c ld::tool::InputFiles::forEachInitialAtom(ld::File::AtomHandler&) + 420 4 0x10fa80884 ld::tool::Resolver::resolve() + 44 5 0x10fa41380 main + 370 6 0x10fa32cd4 start + 52 A linker snapshot was created at: /tmp/<Name Removed>-2013-09-22-135411.ld-snapshot ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. clang: error: linker command failed with exit code 1 (use -v to see invocation) The problem does not occur in Xcode 5.0 (5A1413) with LLVM 5, but unfortunately I must continue to use Xcode 4 for a while. Any suggestions for how to work around this assertion, or hints as to what is going wrong would be greatly appreciated. Thanks for reading. Regards, David -- David Garsha Engineering Program Manager Macintosh Desktop Products Telestream, Inc. www.flip4mac.com www.telestream.net davidg at telestream.net
Tim Northover
2013-Oct-23 08:02 UTC
[LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
Hi David,> ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354.This looks like a bug in the Apple linker, which isn't part of LLVM. The best on-topic place to ask would probably be Apple's developer forum (https://devforums.apple.com), but linkers are rather specialised beasts. The fact that it's been fixed in XCode 5 probably means filing a bug won't be that useful for you. Having said that, the ld64 sources are available online, so if you really need an XCode 4 solution you could try to track it down yourself. Sorry we couldn't be more help. Tim.
Quentin Colombet
2013-Oct-23 17:07 UTC
[LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
Hi David, I already saw this problem and it was due to a bad interaction (incompatible versions) between cctools and ld, IIRC. CC’ed Nick, he may have more information about that. -Quentin On Oct 23, 2013, at 1:02 AM, Tim Northover <t.p.northover at gmail.com> wrote:> Hi David, > >> ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. > > This looks like a bug in the Apple linker, which isn't part of LLVM. > The best on-topic place to ask would probably be Apple's developer > forum (https://devforums.apple.com), but linkers are rather > specialised beasts. > > The fact that it's been fixed in XCode 5 probably means filing a bug > won't be that useful for you. Having said that, the ld64 sources are > available online, so if you really need an XCode 4 solution you could > try to track it down yourself. > > Sorry we couldn't be more help. > > Tim. > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20131023/705f1d6b/attachment.html>
Nick Kledzik
2013-Oct-23 21:24 UTC
[LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
David, This usually means a static library is corrupt. The table of contents said a symbol was in an object file at some offset in the archive, but the linker later found there was no member at that offset. -Nick On Oct 22, 2013, at 3:24 PM, David Garsha <davidg at telestream.net> wrote:> I'm encountering the following assertion when linking an Xcode project with Xcode 4.6.3 (4H1503). The project has dependencies on, and links against, an Objective-C static library Xcode project, and a C++ static library Xcode project. All are using using LLVM 4.2. > > ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. > > 0 0x10fa41098 __assert_rtn + 144 > 1 0x10fa678af archive::File<x86_64>::makeObjectFileForMember(archive::File<x86_64>::Entry const*) const + 1149 > 2 0x10fa670fd archive::File<x86_64>::forEachAtom(ld::File::AtomHandler&) const + 645 > 3 0x10fa7776c ld::tool::InputFiles::forEachInitialAtom(ld::File::AtomHandler&) + 420 > 4 0x10fa80884 ld::tool::Resolver::resolve() + 44 > 5 0x10fa41380 main + 370 > 6 0x10fa32cd4 start + 52 > A linker snapshot was created at: > /tmp/<Name Removed>-2013-09-22-135411.ld-snapshot > ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. > clang: error: linker command failed with exit code 1 (use -v to see invocation) > > The problem does not occur in Xcode 5.0 (5A1413) with LLVM 5, but unfortunately I must continue to use Xcode 4 for a while. > > Any suggestions for how to work around this assertion, or hints as to what is going wrong would be greatly appreciated. > > Thanks for reading. > > Regards, > David > > -- > David Garsha > Engineering Program Manager > Macintosh Desktop Products > Telestream, Inc. > www.flip4mac.com > www.telestream.net > davidg at telestream.net > > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
David Garsha
2013-Oct-28 18:38 UTC
[LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
Thanks to all of you for your help, and thanks for the explanation, Nick. This will save me a lot of time, as now I know where to focus my efforts. Regards, David -- David Garsha Engineering Program Manager Macintosh Desktop Products Telestream, Inc. www.flip4mac.com<http://www.flip4mac.com/> www.telestream.net<http://www.telestream.net/> davidg at telestream.net<mailto:davidg at telestream.net> On Oct 23, 2013, at 2:24 PM, Nick Kledzik <kledzik at apple.com<mailto:kledzik at apple.com>> wrote: David, This usually means a static library is corrupt. The table of contents said a symbol was in an object file at some offset in the archive, but the linker later found there was no member at that offset. -Nick On Oct 22, 2013, at 3:24 PM, David Garsha <davidg at telestream.net<mailto:davidg at telestream.net>> wrote: I'm encountering the following assertion when linking an Xcode project with Xcode 4.6.3 (4H1503). The project has dependencies on, and links against, an Objective-C static library Xcode project, and a C++ static library Xcode project. All are using using LLVM 4.2. ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. 0 0x10fa41098 __assert_rtn + 144 1 0x10fa678af archive::File<x86_64>::makeObjectFileForMember(archive::File<x86_64>::Entry const*) const + 1149 2 0x10fa670fd archive::File<x86_64>::forEachAtom(ld::File::AtomHandler&) const + 645 3 0x10fa7776c ld::tool::InputFiles::forEachInitialAtom(ld::File::AtomHandler&) + 420 4 0x10fa80884 ld::tool::Resolver::resolve() + 44 5 0x10fa41380 main + 370 6 0x10fa32cd4 start + 52 A linker snapshot was created at: /tmp/<Name Removed>-2013-09-22-135411.ld-snapshot ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember, file /SourceCache/ld64/ld64-136/src/ld/parsers/archive_file.cpp, line 354. clang: error: linker command failed with exit code 1 (use -v to see invocation) The problem does not occur in Xcode 5.0 (5A1413) with LLVM 5, but unfortunately I must continue to use Xcode 4 for a while. Any suggestions for how to work around this assertion, or hints as to what is going wrong would be greatly appreciated. Thanks for reading. Regards, David -- David Garsha Engineering Program Manager Macintosh Desktop Products Telestream, Inc. www.flip4mac.com<http://www.flip4mac.com> www.telestream.net davidg at telestream.net _______________________________________________ LLVM Developers mailing list LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
Apparently Analagous Threads
- [LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
- [LLVMdev] ld: Assertion failed: (memberIndex != 0), function makeObjectFileForMember
- how to backup samba ad domain
- Installation of XiphQT component in Snow Leopard
- CentOS 7.4 fails to boot as Xen PV guest: resurfaces (now also) with centosplus kernel 693.11.6.el7