English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 24 September 2018, 00:39   #1
jarre
Registered User
 
jarre's Avatar
 
Join Date: Sep 2016
Location: Deventer - Netherlands
Posts: 599
Static adres

Is it possible to re alocate an executable to lets say $30000 and execute it from there
jarre is offline  
Old 24 September 2018, 00:44   #2
Galahad/FLT
Going nowhere
 
Galahad/FLT's Avatar
 
Join Date: Oct 2001
Location: United Kingdom
Age: 50
Posts: 8,986
Quote:
Originally Posted by jarre View Post
Is it possible to re alocate an executable to lets say $30000 and execute it from there
Yes.

Not really advisable if you are wanting to return back to AmigaDOS afterwards though.
Galahad/FLT is offline  
Old 24 September 2018, 03:37   #3
jarre
Registered User
 
jarre's Avatar
 
Join Date: Sep 2016
Location: Deventer - Netherlands
Posts: 599
Quote:
Originally Posted by Galahad/FLT View Post
Yes.

Not really advisable if you are wanting to return back to AmigaDOS afterwards though.
And how should that be possible, loading the exe to $30000 in c-mon and jump to $30028 (program start) results in guru....
jarre is offline  
Old 24 September 2018, 09:31   #4
StingRay
move.l #$c0ff33,throat
 
StingRay's Avatar
 
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
If the code is 100% pc-relative you can simply copy it to the destination address. If it isn't however that will not work, you have to relocate all RELOC32 entries to the new destination address (parse the RELOC32 hunk and adapt the code in the binary).

A simple and easy way to do all this: just crunch the binary using a cruncher that supports absolute addresses (CrunchMania, StoneCracker etc.) and simply let the cruncher do all the work for you.
StingRay is offline  
Old 24 September 2018, 09:34   #5
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Or, if you want to make some test and mod before the crunch, use this:
http://www.whdload.de/docs/en/reloc.html
ross is offline  
Old 24 September 2018, 11:59   #6
jarre
Registered User
 
jarre's Avatar
 
Join Date: Sep 2016
Location: Deventer - Netherlands
Posts: 599
thanks all for the helpfull hints, i go play with it..
jarre is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
skipping parts of a static copperlist... Tigerskunk Coders. Asm / Hardware 13 27 October 2019 16:11
Mouse and static Solderbro support.Hardware 1 19 June 2018 20:36
Moving a big banner behind a static object Ozzyboshi Coders. Asm / Hardware 14 16 May 2018 20:34
Anti static wristband really necessary? Treguard support.Hardware 4 29 June 2015 18:27
Static RAM in Amiga. bebek Hardware mods 4 04 June 2010 05:06

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 03:39.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.08457 seconds with 13 queries