User`s guide
A Producing a COM Object from MATLAB
A-4
Figure A-2: M-Build Steps and Intermediate Files Created
mcc -B cexel:mycomponent,myclass,1.0 foo.m bar.m
foo.h, foo.c
bar.h, bar.c
mycomponent_com.hpp,
mycomponent_com.cpp
mycomponent_idl.idl
foo.m, bar.m
mycomponent_dll.cpp
mycomponent.def
Step 1. Code
Generation
IDL Compiler
mycomponent_idl.h,
mycomponent_idl_i.c
Step 2. Create
Interface
Definitions
mycomponent_idl.tlb
mycomponent.rc
Step 3. C++
Compilation
C++ Compiler
Object Files
Step 3. C++
Compilation
Step 4. Linking
and Resource
Binding
Linker
MATLAB Libraries
mycomponent_1_0.dll
(no type info)
Resource Compiler
Step 5. Component
Registration
mycomponent_1_0.dll
(includes type info)
MATLAB M-files
MATLAB Compiler
mycomponent.bas
mclcomclass.h