ELF relocation

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
ohboy

ELF relocation

Post by ohboy »

I'm trying to relocate an ELF, and it's working partly.
When I call a function that is below my current one, it works, but I fail to call one on top of it.

Code: Select all

*absolute = ((uint32)newaddress - (uint32)absolute) / 4 + 1;
That's how I set the references, absolute is pointing at an unsigned dword reference to be patched.

I've tried to use signed values instead, but that won't work either.
ohboy

Re:ELF relocation

Post by ohboy »

If someone have some code that relocates ELFs, I would be very glad if you liked to post it, it would help me alot right now.
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:ELF relocation

Post by Pype.Clicker »

i should have that in the "tools" package of clicker ... http://cvs.sourceforge.net/viewcvs.py/c ... /modmakr2/

that should be "elfopen.c"
Post Reply