Advertisement
Guest User

Bad executable from LD.LLD

a guest
Sep 13th, 2018
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.55 KB | None | 0 0
  1. == The error produced by LLD
  2.  
  3. lld-link: error: undefined symbol: _ZTIi
  4. >>> referenced by C:\msys64\tmp\tst-fbde9c.o:(GCC_except_table2)
  5. >>> referenced by C:\msys64\tmp\tst-fbde9c.o:(.refptr._ZTIi)
  6.  
  7. lld-link: error: undefined symbol: _ZSt4cout
  8. >>> referenced by C:\msys64\tmp\tst-fbde9c.o:(.refptr._ZSt4cout)
  9.  
  10. == The output of NM (the same as Dependency Walker) of a.exe linked with bfd
  11.  
  12. NoTengoBattery@DESKTOP-M0E0M8K MINGW64 ~
  13. $ objdump -x a.exe | grep "DLL Name"
  14. DLL Name: libgcc_s_seh-1.dll
  15. DLL Name: libstdc++-6.dll
  16. DLL Name: KERNEL32.dll
  17. DLL Name: msvcrt.dll
  18.  
  19. == Symbols imported from libstdc++-6.dll to a.exe linked using BFD (Dependency Walker)
  20.  
  21. _ZNSolsEi
  22. _ZNSt8ios_base4InitC1Ev
  23. _ZNSt8ios_base4InitD1Ev
  24. _ZSt4cout <-- LLD complains about this!
  25. _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc
  26. _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c
  27. _ZTIi <-- LLD complains about this!
  28. __cxa_allocate_exception
  29. __cxa_begin_catch
  30. __cxa_end_catch
  31. __cxa_throw
  32. __gxx_personality_seh0
  33.  
  34. == The output of NM (the same as Dependency Walker) of a.exe linked with bfd
  35.  
  36. NoTengoBattery@DESKTOP-M0E0M8K MINGW64 ~
  37. $ objdump -x a.exe | grep "DLL Name"
  38. DLL Name: libstdc++-6.dll
  39. DLL Name: libgcc_s_seh-1.dll
  40.  
  41. == Symbols imported from libstdc++-6.dll to a.exe linked using LLD (Dependency Walker)
  42.  
  43.  
  44. == Observation: Dependency Walker does not list any symbol nor any used DLL
  45. https://imgur.com/a/lZ0SYzb
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement