flat assembler
Message board for the users of flat assembler.

Index > Compiler Internals > LINUX Support

Goto page Previous  1, 2
Author
Thread Post new topic Reply to topic
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4623
Location: Argentina
LocoDelAssembly 06 Nov 2007, 14:20
Raedwulf, I don't remember anything of this anymore, perhaps my code was just to verify that get_dword_value doesn't corrupts anything?
Post 06 Nov 2007, 14:20
View user's profile Send private message Reply with quote
Raedwulf



Joined: 13 Jul 2005
Posts: 375
Location: United Kingdom
Raedwulf 06 Nov 2007, 14:36
Umm but you did say
Quote:
Changing the calling code of get_dword_value with this extremist register protection code fixes the segment origin corruption


So it does suggest that that was the fix Razz.

I actually might just use the Elf from scratch method and wait for Tomasz to get round to making a nicer format specification. I finally got round to testing the fasm code and it work with my new patched version but when I tried to convert the libc version of FASM, the program would just not run ^^ Smile.

_________________
Raedwulf
Post 06 Nov 2007, 14:36
View user's profile Send private message MSN Messenger Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4623
Location: Argentina
LocoDelAssembly 06 Nov 2007, 14:52
Quote:
So it does suggest that that was the fix

Disadvantage of people that doesn't speak English natively Razz

I was wondering if this is good idea after all. On Windows it is OK to import DLLs directly without linker, but on Linux, when you link to a shared library using linker, sometimes you also add some extra code to your executable (for example linking against C library).

So, skipping the linker will be reliable or we gonna just abuse of the fact that the current implementation of a certain library can work anyway?
Post 06 Nov 2007, 14:52
View user's profile Send private message Reply with quote
Raedwulf



Joined: 13 Jul 2005
Posts: 375
Location: United Kingdom
Raedwulf 06 Nov 2007, 21:18
You have a point there... I don't know for sure but I think its pretty portable provided that the *.so name is the same and all the supported symbols are present.

So basically if the *.so is not present by that name you will have to reassemble. However if you use C/C++ you will also have to relink/recompile. So I don't think there's too much of a difference.

_________________
Raedwulf
Post 06 Nov 2007, 21:18
View user's profile Send private message MSN Messenger Reply with quote
nocona



Joined: 04 Aug 2007
Posts: 35
nocona 08 Nov 2007, 07:17
Quote:

nocona: where are you from? I know you're from Southeast asia because I can speak Malay as well "mula" was a dead giveaway in the examples lol. I was like... huh!!?? . I used to live in Brunei and did my primary/secondary-schooling up to O-levels there.

saya dari Malaysia Smile. Negeri Sabah. Saya pasti awak pernah dengar mengenainya sebab Sabah sangat dekat dengan Brunei.

In Windows, linker also add codes to our executable.. otherwise we cannot get those arguments to main.. the same thing goes for linux.. the extra codes are there to support all the C stuff.

the problem here is when building a dll (dynamically shared object) in linux, because afaik every linker available use section header to get info from our object, but the dynamic linker don't need it. perhaps somebody can hack gnu linker here?
Post 08 Nov 2007, 07:17
View user's profile Send private message Reply with quote
Raedwulf



Joined: 13 Jul 2005
Posts: 375
Location: United Kingdom
Raedwulf 08 Nov 2007, 08:30
<Ok removed personal stuff into PM>

Maybe add the normal section info -> because I'm guessing we're skipping all the sections using this method?

_________________
Raedwulf
Post 08 Nov 2007, 08:30
View user's profile Send private message MSN Messenger Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page Previous  1, 2

< 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-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.