4 Stand-Alone Applications
4-38
The Build Process
The steps needed to build this stand-alone application are:
1 Compile the M-code.
2 Generate the library wrapper file.
To perform these steps, use
mcc -t -W lib:Pkg -T link:exe -h mrank mrankp.c libmmfile.mlib
The MATLAB Compiler generates C source code files named mrank.c, Pkg.c,
and
Pkg.h. This command invokes mbuild to compile the resulting
Compiler-generated source files (
mrank.c, Pkg.c, Pkg.h) with the existing C
source file (
mrankp.c) and links against the required libraries. For details, see
“Building Stand-Alone C/C++ Applications” on page 4-5.
The MATLAB Compiler provides two different versions of
mrankp.c in the
<matlab>/extern/examples/compiler directory:
•
mrankp.c contains a POSIX-compliant main function. mrankp.c sends its
output to the standard output stream and gathers its input from the
standard input stream.
•
mrankwin.c contains a Windows version of mrankp.c.
Comments to this Manuals