flat assembler
Message board for the users of flat assembler.

Index > Windows > Libraries in FASM

Author
Thread Post new topic Reply to topic
Manos



Joined: 24 Aug 2003
Posts: 35
Location: Greece
Manos 24 Nov 2016, 11:52
Hi.

You can inlude libraries in FASM using: section '.drectve' data readable linkinfo
This directive informs the linker that the current module should be linked with a library.

Example:
section '.drectve' data readable linkinfo
db "/defaultlib:msvcrt.lib"
.

My C compiler produce MS object files directly,
that is, without any assembler as a backend,
but also can emit assembly language in MASM and FASM syntax.

Below I attached a file that my C compiler produced in FASM code.
At the and of file you can see the above directive.
You can assmble this file using the command line FASM.exe and then you can use some linker to link the produced object file with the .res file that accompanies the assembly file to produce the executable.

Manos.


Description:
Download
Filename: Demo.zip
Filesize: 16.15 KB
Downloaded: 531 Time(s)

Post 24 Nov 2016, 11:52
View user's profile Send private message Visit poster's website Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 42
uor99 24 Dec 2016, 12:48
I need the c source of an x86 c compiler.
Post 24 Dec 2016, 12:48
View user's profile Send private message ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20333
Location: In your JS exploiting you and your system
revolution 24 Dec 2016, 14:27
uor99 wrote:
I need the c source of an x86 c compiler.
GCC should fit the requirement.
Post 24 Dec 2016, 14:27
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1791
Roman 24 Dec 2016, 17:17
section '.drectve' is present in fasm 1.69.03 ?
How i understood in c++ we compile lib and then might using in fasm.
Did i think right ?
Post 24 Dec 2016, 17:17
View user's profile Send private message Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 42
uor99 25 Dec 2016, 18:16
Yes, GCC is a good choice. However, it is INTEL's style assembly. Is there any other opensource tiny c compiler for 8086/8088 ?
Post 25 Dec 2016, 18:16
View user's profile Send private message ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20333
Location: In your JS exploiting you and your system
revolution 25 Dec 2016, 18:18
uor99 wrote:
Is there any other opensource tiny c compiler for 8086/8088 ?
Yep, lots. You can visit my website to find more.
Post 25 Dec 2016, 18:18
View user's profile Send private message Visit poster's website Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 42
uor99 10 Jan 2017, 09:35
revolution,please put down your url here. Thanks.
Post 10 Jan 2017, 09:35
View user's profile Send private message ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20333
Location: In your JS exploiting you and your system
revolution 11 Jan 2017, 07:55
All my post have a "WWW" button. That will take you to the website.
Post 11 Jan 2017, 07:55
View user's profile Send private message Visit poster's website Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 42
uor99 13 Jan 2017, 09:02
The browser always say:Connection reset.
Post 13 Jan 2017, 09:02
View user's profile Send private message ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20333
Location: In your JS exploiting you and your system
revolution 13 Jan 2017, 13:56
Works fine for me.

BTW: The full URL is http://tinyurl.com/justfgi
Post 13 Jan 2017, 13:56
View user's profile Send private message Visit poster's website Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo 13 Jan 2017, 20:38
revolution is also a very good singer.
Post 13 Jan 2017, 20:38
View user's profile Send private message Visit poster's website 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-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.