C– – Compiler
5-39
Code Development Tools
The syntax of the call is:
extern int FAR PASCAL LINK_MAIN (LPSTR source_file,LPSTR
exe_file);
.....
ierr=LINK_MAIN (source_file,exe_file);
Where:
source_file is the project file name, which contains the names of the
files to be linked.
exe_file is the name of the linked executable file.
ierr is the total number of errors returned by the linker.
If errors occur during link, the error information is placed in a file with extension
.rer, with the same name as the executable file.
5.9 C–– Compiler
The MSP50P614/MSP50C614 C– – compiler is implemented as a Windows
dynamic linked library (DLL). The current name of the DLL file is cmm6xx.dll.
It can be invoked from any Windows program, provided that the user included
the file called cmm6xx.lib in the Windows project.
The syntax of the call is:
extern int FAR PASCAL CMM_MAIN (LPSTR source_file,short *warn,
struct cmm_input *,struct error_struct *);
/* ..... */
#define MAX_LEN 256
LPSTR source_file;
short w,i;
struct error_struct{
short pass; /* pass where error was detected */
short type; /* type of error (error, warning */
short error_msg; /* error message number */
short file_number; /* file number in object file table */
long line_number; /* line number in file where error occurred */
char info[MAXIDENTIFIER+1]; /* character string containing some */
/*information on the error */
};
struct cmm_input{
short heap_st; /* start of heap */
short stack_st; /* start of stack */