flat assembler
Message board for the users of flat assembler.

Index > Unix > BeOS ELF generation problem

Author
Thread Post new topic Reply to topic
Ralph



Joined: 04 Oct 2003
Posts: 86
Ralph
Hello,
I'm trying to cross-compile elf files for BeOS using fasm. I can use nasm to generate beos elfs fine, but I would prefer fasm. When I compared the two I noticed that the absolute addresses were not correct in the fasm elf. To correct this I had to add 80000000h and subtract 4800, ie :
Code:
org 80000000h + ($ and 0FFh)    

This worked, but it's obviously not a very good solution. Does anyone have any suggestions on a real fix?
Post 03 May 2004, 07:34
View user's profile Send private message Reply with quote
Dryobates



Joined: 13 Jul 2003
Posts: 46
Location: Poland
Dryobates
Maybe you should try something like brandelf (I don't know what tools are on BeOS).
Post 04 May 2004, 08:42
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7734
Location: Kraków, Poland
Tomasz Grysztar
Is BeOS not reading base address field from the ELF header? You try this setting:
Code:
format ELF executable at 80000000h    
Post 04 May 2004, 12:15
View user's profile Send private message Visit poster's website Reply with quote
Ralph



Joined: 04 Oct 2003
Posts: 86
Ralph
Thanks. Exactly what I was looking for.
Post 06 May 2004, 01:59
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.