flat assembler
Message board for the users of flat assembler.

Index > Windows > FA - command line extension for fasm

Author
Thread Post new topic Reply to topic
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8356
Location: Kraków, Poland
Tomasz Grysztar 19 Mar 2009, 20:57
Here's a small tool, which I made mainly for the people like vid, who'd like to have -D option in command line. It's a non-SSSO command line overlay for fasm, which provides few "unorthodox" options that fasm itself does not.

First of all, it allows to specify multiple source files in the command line, which will get assembled as one - this way you can, for instance, include some macro package before the main program you are assembling, like:
Code:
fa optimization_macros.inc my_program.asm -o my_program.exe    

Note the -O switch used to specify output file. If it is not specified, the default will be used, which is "a" with a extension appropriate for the output format (like a.exe or a.obj). Such neutral name is used because of the fact, that there may not be single source file (it's similar to how ld linker generates the default output as a.out).

Other additional options are: -D for defining symbolic variables from command line, -I for defining include paths (same as defining them with INCLUDE variable), -L to make listing (FA has listing generator built-in).

And it's currently only for Windows, sorry.


Description: FA - command line extension for fasm
Download
Filename: fa.zip
Filesize: 8.36 KB
Downloaded: 1317 Time(s)



Last edited by Tomasz Grysztar on 26 Sep 2019, 10:50; edited 2 times in total
Post 19 Mar 2009, 20:57
View user's profile Send private message Visit poster's website Reply with quote
habran



Joined: 31 Aug 2008
Posts: 82
Location: South Australia
habran 19 Mar 2009, 21:32
Hi Tomasz,
Thank you very much, nice tool!
So, if I understood it correctly, we don't need to call fasm.exe from the command line to compile files but fa.exe , which calls fasm.exe?

best regards
Post 19 Mar 2009, 21:32
View user's profile Send private message Reply with quote
madmatt



Joined: 07 Oct 2003
Posts: 1045
Location: Michigan, USA
madmatt 21 Mar 2009, 00:59
Thanks Tomasz, I can hardly keep up with all the updates! One question, does the command line version for Windows use the fasmw.ini file? Would it be hard to add this to the command line version also?
Post 21 Mar 2009, 00:59
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1903
DOS386 22 Mar 2009, 02:21
Tomasz Grysztar wrote:
Here's a small tool, which I made mainly for the people like vid, who'd like to have -D option in command line. It's a non-SSSO command line overlay for fasm, which provides few "unorthodox" options that fasm itself does not.

First of all, it allows to specify multiple source files in the command line

-O switch used to specify output file.

-D for defining symbolic variables from command line

-I for defining include paths (same as defining them with INCLUDE variable),

-L to make listing (FA has listing generator built-in).


COOL. Smile

Quote:
And it's currently only for Windows, sorry.


Would be nice to have this for DOS also. I personally don't need "-D" and "-O" (since format binary as "DLL" rocks Laughing), but "-L" is interesting Smile

madmatt wrote:

> One question, does the command line version for Windows use the fasmw.ini file?

NO. RTFS Idea
Post 22 Mar 2009, 02:21
View user's profile Send private message Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo 27 Mar 2009, 14:32
Tomasz Grysztar wrote:

And it's currently only for Windows, sorry.


Will it be included in future official FASM Win32 packages?

EDIT: In particular, this subforum doesn't allow non-registered viewers to download attachments, so that's part of my concern.

EDIT #2: Laughing I would honestly prefer it named to "fas" or "fasmw32" or similar.
Post 27 Mar 2009, 14:32
View user's profile Send private message Visit poster's website Reply with quote
madmatt



Joined: 07 Oct 2003
Posts: 1045
Location: Michigan, USA
madmatt 27 Mar 2009, 14:37
Quote:
madmatt wrote:

Quote:
> One question, does the command line version for Windows use the fasmw.ini file?


NO. RTFS Idea


RTFS?

_________________
Gimme a sledge hammer! I'LL FIX IT!
Post 27 Mar 2009, 14:37
View user's profile Send private message Reply with quote
rugxulo



Joined: 09 Aug 2005
Posts: 2341
Location: Usono (aka, USA)
rugxulo 27 Mar 2009, 14:45
"Read The Freakin' Source", I assume. Rolling Eyes
Post 27 Mar 2009, 14:45
View user's profile Send private message Visit poster's website Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1903
DOS386 27 Mar 2009, 14:47
rugxulo wrote:
prefer it named to "fas" or "fasmw32" or similar.


Why ? Confused NO Confused

Maybe FASMEVIL would be a good name for a hack not tolerable in the "official" version Shocked
Post 27 Mar 2009, 14:47
View user's profile Send private message Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid 27 Mar 2009, 14:55
Please recount all the problems it caused while it was active, aside from couple of design freaks (including Tomasz Very Happy) hating it.
Post 27 Mar 2009, 14:55
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
madmatt



Joined: 07 Oct 2003
Posts: 1045
Location: Michigan, USA
madmatt 27 Mar 2009, 22:28
rugxulo wrote:
"Read The Freakin' Source", I assume. Rolling Eyes

Smile I think he means read the first post, you can define an INCLUDE variable. I'll do this and see if it does the same as the fasm.ini file.

_________________
Gimme a sledge hammer! I'LL FIX IT!
Post 27 Mar 2009, 22:28
View user's profile Send private message Reply with quote
alorent



Joined: 05 Dec 2005
Posts: 221
alorent 14 Feb 2011, 12:06
Hello,

Notice that launching "FA" concurrently (like with GNU make) makes corruption as it uses always an intermediate file named "A.$$$". It might be better if the "A.$$$" file takes a random name each time.

Regards
Post 14 Feb 2011, 12:06
View user's profile Send private message Reply with quote
AsmGuru62



Joined: 28 Jan 2004
Posts: 1657
Location: Toronto, Canada
AsmGuru62 05 Jul 2011, 10:19
Nice tool!
Is it possible to add an option to generate the MAP file?
Like the file with addresses for all non-local labels.
Post 05 Jul 2011, 10:19
View user's profile Send private message Send e-mail Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8356
Location: Kraków, Poland
Tomasz Grysztar 05 Jul 2011, 12:58
AsmGuru62 wrote:
Nice tool!
Is it possible to add an option to generate the MAP file?
Like the file with addresses for all non-local labels.
Do you mean something like what TOOLS/WIN32/SYMBOLS generates?
Post 05 Jul 2011, 12:58
View user's profile Send private message Visit poster's website Reply with quote
AsmGuru62



Joined: 28 Jan 2004
Posts: 1657
Location: Toronto, Canada
AsmGuru62 05 Jul 2011, 13:47
It is perfect!

I must filter it out a little, I need to exclude stuff from FASM INC files, but that is what I was looking for.
Post 05 Jul 2011, 13:47
View user's profile Send private message Send e-mail Reply with quote
catafest



Joined: 05 Aug 2010
Posts: 129
catafest 26 Aug 2015, 08:31
Why use this style of coding ? I think you can stores a byte, word, or doubleword from the AL, AX, or EAX register, respectively, into the destination operand. So what it's your idea ?

convert_definition:
mov esi,[ebx+4]
mov eax,'defi'
stosd
mov eax,'ne '
stosd
dec edi
Post 26 Aug 2015, 08:31
View user's profile Send private message Visit poster's website Yahoo Messenger 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.