ack/lang/cem/cemcom.ansi/cemcom.ansi.1
2006-02-04 00:57:05 +00:00

104 lines
3.6 KiB
Groff

.TH EM_CEMCOM.ANSI 6 "$Revision$"
.ad
.SH NAME
em_cemcom.ansi \- ANSI C to EM compiler
.SH SYNOPSIS
\fB~/em/lib.bin/em_cemcom.ansi\fP [ options ] source destination
.SH DESCRIPTION
\fICemcom\fP is a compiler that translates C programs
into EM compact code.
The input is taken from \fIsource\fP, while the
EM code is written on \fIdestination\fP.
If either of these two names is "\fB-\fP", standard input or output respectively
is taken.
When the preprocessor is invoked to run stand-alone, \fIdestination\fP
needs not be specified.
.br
\fIOptions\fP is a, possibly empty, sequence of the following combinations:
.IP \fB\-D\fIname\fR=\fItext\fR
.br
define \fIname\fR as a macro with \fItext\fR as its replacement text.
.IP \fB\-D\fIname\fR
.br
the same as \fB\-D\fIname\fR=1.
.IP \fB\-I\fIdirname\fR
.br
insert \fIdirname\fR in the list of include directories.
.IP \fB\-M\fP\fIn\fP
set maximum identifier length to \fIn\fP.
.IP \fB\-g\fP
produce a DBX-style symbol table.
.IP \fB\-n\fR
do not generate EM register messages.
The user-declared variables are not stored into registers on the target
machine.
.IP \fB\-L\fR
don't generate the EM \fBfil\fR and \fBlin\fR instructions
that usually are generated to enable
an interpreter to keep track of the current location in the source code.
.IP \fB\-p\fR
generate code at each procedure entry to call the routine
.BR procentry ,
and at each return to call the routine
.BE procexit .
These routines are supplied with one parameter, a pointer to a
string containing the name of the procedure.
.IP \fB\-A\fR[\fIfile\fR]
.br
if \fIfile\fR is not given, generate a list
of makefile dependencies and write them to the standard output.
If \fIfile\fP is given,
generate the list of makefile dependencies on file \fIfile\fP.
.IP \fB-i\fR
when generating makefile dependencies, do not include files from
/usr/include.
.IP \fB-m\fR
when generating makefile dependencies, generate them in the following format:
.RS
.IP "file.o: file1.h"
.RE
.IP ""
where "file.o" is derived from the source file name. Normally, only a list
of files included is generated.
.IP \fB\-R\fR
interpret the input as restricted C (according to the language as
described in \fIThe C programming language\fR by Kernighan and Ritchie.)
.IP \fB\-U\fIname\fR
.br
get rid of the compiler-predefined macro \fIname\fR.
.IP \fB\-V\fIcm\fR.\fIn\fR,\ \fB\-V\fIcm\fR.\fIncm\fR.\fIn\fR\ ...
.br
set the size and alignment requirements.
The letter \fIc\fR indicates the simple type, which is one of
\fBs\fR(short), \fBi\fR(int), \fBl\fR(long), \fBf\fR(float), \fBd\fR(double),
\fBx\fR(long double) or
\fBp\fR(pointer).
The \fIm\fR parameter can be used to specify the length of the type (in bytes)
and the \fIn\fR parameter for the alignment of that type.
Absence of \fIm\fR or \fIn\fR causes the default value to be retained.
To specify that the bitfields should be right adjusted instead of the
default left adjustment, specify \fBr\fR as \fIc\fR parameter.
.IP \fB\-w\fR
suppress warning messages.
.IP \fB\-s\fR
suppress stricts.
.IP \fB\-a\fR
suppress warnings and stricts.
.IP \fB\-o\fR
suppress warnings and stricts about old-style.
.IP \fB\-\-\fItext\fR
.br
where \fItext\fR can be either of the above or
a debug flag of the compiler (which is not useful for the common user.)
This feature can be used in various shell scripts and surrounding programs
to force a certain option to be handed over to \fBcemcom\fR.
.LP
.SH FILES
.IR ~em/lib.bin/em_cemcom.ansi :
the compiler
.SH DIAGNOSTICS
All warning and error messages are written on standard error output.
.SH REFERENCE
Baalbergen, E.H., D. Grune, M. Waage ;"\fIThe CEM compiler\fR",
Informatica Manual IM-4