How to 'link' object file to executable/compiled binary?

后端 未结 6 1993
失恋的感觉
失恋的感觉 2020-12-24 08:41

Problem

I wish to inject an object file into an existing binary. As a concrete example, consider a source Hello.c:

#inc         


        
6条回答
  •  有刺的猬
    2020-12-24 09:38

    Have you looked at the DyninstAPI? It appears support was recently added for linking a .o into a static executable.

    From the release site:

    Binary rewriter support for statically linked binaries on x86 and x86_64 platforms

提交回复
热议问题