Re: A92: Request of Information about DJGPP...


[Prev][Next][Index][Thread]

Re: A92: Request of Information about DJGPP...




One of the list members wrote his own preprocessor.  However, I suggested that
cpp.exe (the C PreProcessor) that comes with DJGPP can be used for this
purpose.  His preprocessor has a few other functions, such as deleting spaces
after commas, that the normal C Preprocessor doesn't have.  However, if you'd
like to just use the normal C preprocessor, this is the command line:
cpp -nostdinc -I%fargo%\asm\include -P infile.asm outfile.asm
I would suggest making infile.asm "%1.asm" and choosing something for
outfile.asm like "processed.asm" (assuming nobody would ever make a source
file called processed asm) and then changing all other %1.asm occurances in
fargo.bat to processed.asm.  The line invoking cpp.exe would go right before
the call to the assembler, I think.  You may want the program to delete
processed.asm, or you may want to leave it there so you can distribute it for
people who don't have DJGPP.  Hope this helps.
Also, we may be able to fool with the source to cpp to make a fargo version
(with extra fargo specific features, probably implemented with #pragma
directives), which I believe would be legal to distribute, as long as we
provided source.