Mail Archives: djgpp/1997/06/14/02:37:20
acebear AT pukopn1 DOT puk DOT ac DOT za wrote:
>
> The docs I got with DJGPP includes very little info on using DJASM.EXE.
> This is the assembler right? Any idea where I can get examples/docs for
> it?
djasm is not the main assembler! It is designed for one purpose only:
to build the 2k real mode stub that is attached to all DJGPP programs
and handles the tasks of detecting and loading DPMI, switching from real
to protected mode, and passing control to the main program. It is
possible to generate 16-bit executable code from djasm, but not
recommended.
The assembler that is used to compile your programs is 'as.exe', also
known as GAS (the GNU ASsembler). It is automatically run by the 'gcc'
frontend program, and you should _never_ need to invoke it manually.
gcc does all kinds of stuff that you must duplicate for manual calls to
as. Also, as does not handle preprocessor directives; to do this you
must tell gcc to pass your source code through the preprocessor by
invoking it with an uppercase 'S' as the file extension. This part is
covered in the GCC docs ("info gcc invoking").
Don't try to second guess the DJGPP developers or the GNU developers;
things are the way they are for a purpose.
--
---------------------------------------------------------------------
| John M. Aldrich | "Waking a person unnecessarily |
| aka Fighteer I | should not be considered a capital |
| mailto:fighteer AT cs DOT com | crime. For a first offense, that |
| http://www.cs.com/fighteer | is." - Lazarus Long |
---------------------------------------------------------------------
- Raw text -