Problem while creating an exe file in matlab using mcc/deploytool???

1 view (last 30 days)
Hi, I want to create an executable file from an m file which can be run in a machine where there is no matlab. My m file contains commands related to graphics & user interfacing. I got the following error while using the mcc command.
'cmd' is not recognized as an internal or external command,
operable program or batch file.
Error: An error occurred while shelling out to mbuild (error code = 1).
Unable to build executable (specify the -v option for more information).
??? Error using ==> mcc
Error executing mcc, return status = 1 (0x1).
And the following errors were shown while using the deploytool command.
Build output( 2013-10-03 19:30:40).
mcc -F 'D:\Work\Del212.prj'
mcc -o 'Del212' -W 'main' -d 'D:\Work\Del212\src' -T 'link:exe' -v 'C:\Documents and Settings\Md. Delar\My Documents\MATLAB\CandImage.m'
Compiler version: 4.10 (R2009a)
Processing C:\Program Files\MATLAB\R2009a\toolbox\images\mcc.enc
Processing C:\Program Files\MATLAB\R2009a\toolbox\shared\imageslib\mcc.enc
Processing include files...
2 item(s) added.
Processing directories installed with MCR...
The file D:\Work\Del212\src\mccExcludedFiles.log contains a list of functions excluded from the CTF archive.
2 item(s) added.
Generating MATLAB path for the compiled application...
Created 47 path items.
Begin validation of MEX files: Thu Oct 03 19:31:39 2013
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\bin\win32\libippmw.dll'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\images\private\imlincombc.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\images\private\immultmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\images\private\intlutc.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptformats\private\bitparse.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptformats\private\dicom_decode_rle_segment.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptformats\private\dicomlookup_helper.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptformats\private\dicomparse.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptformats\private\tobits.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptutils\iptcheckinput.mexw32'.
Found M-file 'C:\Program Files\MATLAB\R2009a\toolbox\images\iptutils\iptcheckinput.m'.
MEX file
'C:\Program Files\MATLAB\R2009a\toolbox\images\iptutils\iptcheckinput.mexw32'
is valid. It contains 'mexFunction.'
End validation of MEX files: Thu Oct 03 19:31:39 2013
Parsing file "C:\Documents and Settings\Md. Delar\My Documents\MATLAB\CandImage.m"
(Referenced from: "Compiler Command Line").
Parsing file "C:\Program Files\MATLAB\R2009a\toolbox\compiler\deploy\deployprint.m"
(Referenced from: "Compiler Command Line").
Parsing file "C:\Program Files\MATLAB\R2009a\toolbox\compiler\deploy\printdlg.m"
(Referenced from: "Compiler Command Line").
Deleting 10 temporary MEX authorization files.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_31525_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_12427_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_11909_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_26632_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_14175_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_21286_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_10776_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_3937_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_9815_3036.auth'.
Removing: 'C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\Temp\mathworks_tmp_3036_15731_3036.auth'.
Generating file "D:\Work\Del212\src\Del212_main.c".
Generating file "D:\Work\Del212\src\Del212_delay_load.c".
Generating file "D:\Work\Del212\src\readme.txt".
Generating file "D:\Work\Del212\src\Del212_mcc_component_data.c".
Executing command: mbuild -O -v -output "Del212" -I"D:\Work\Del212\src" "D:\Work\Del212\src\Del212_main.c" "D:\Work\Del212\src\Del212_delay_load.c" "D:\Work\Del212\src\Del212_mcc_component_data.c" -link exe -env MCR_DELAYLOAD=/delayload:mclmcrrt710.dll -env MCR_DELAYLIB=delayimp.lib -outdir "D:\Work\Del212\src"
This is mbuild Copyright 1984-2006 The MathWorks, Inc.
-> Default options filename found in C:\Documents and Settings\Md. Delar\Application Data\MathWorks\MATLAB\R2009a
----------------------------------------------------------------
-> Options file = C:\Documents and Settings\Md. Delar\Application Data\MathWorks\MATLAB\R2009a\compopts.bat
-> COMPILER = lcc
-> Compiler flags:
COMPFLAGS = -c -Zp8 -I"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\include" -noregistrylookup
OPTIMFLAGS = -DNDEBUG
DEBUGFLAGS = -g4
arguments = -ID:\WORK\DEL212\SRC
Name switch = -Fo
-> Pre-linking commands =
-> LINKER = lcclnk
-> Link directives:
LINKFLAGS = -tmpdir "D:\WORK\DEL212\SRC\." -L"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\lib" -libpath "C:\PROGRA~1\MATLAB\R2009a\extern\lib\win32\lcc"
LINKFLAGSPOST = mclmcrrt.lib
Name directive = -o "D:\WORK\DEL212\SRC\Del212.exe"
File link directive =
Lib. link directive =
Rsp file indicator = @
-> Resource Compiler =
-> Resource Linker =
----------------------------------------------------------------
--> lcc -ID:\WORK\DEL212\SRC -c -Zp8 -I"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\include" -noregistrylookup -FoC:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_main.obj -IC:\PROGRA~1\MATLAB\R2009a\extern\include -IC:\PROGRA~1\MATLAB\R2009a\simulink\include -DNDEBUG D:\Work\Del212\src\Del212_main.c
--> lcc -ID:\WORK\DEL212\SRC -c -Zp8 -I"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\include" -noregistrylookup -FoC:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_delay_load.obj -IC:\PROGRA~1\MATLAB\R2009a\extern\include -IC:\PROGRA~1\MATLAB\R2009a\simulink\include -DNDEBUG D:\Work\Del212\src\Del212_delay_load.c
Warning D:\Work\Del212\src\Del212_delay_load.c: 21 static `void function(void) FailedToLoadMCR' is not referenced
0 errors, 1 warnings
--> lcc -ID:\WORK\DEL212\SRC -c -Zp8 -I"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\include" -noregistrylookup -FoC:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_mcc_component_data.obj -IC:\PROGRA~1\MATLAB\R2009a\extern\include -IC:\PROGRA~1\MATLAB\R2009a\simulink\include -DNDEBUG D:\Work\Del212\src\Del212_mcc_component_data.c
Contents of C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\mbuild_tmp.rsp:
C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_main.obj C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_delay_load.obj C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\Del212_mcc_component_data.obj
--> lcclnk -o "D:\WORK\DEL212\SRC\Del212.exe" -tmpdir "D:\WORK\DEL212\SRC\." -L"C:\PROGRA~1\MATLAB\R2009a\sys\lcc\lib" -libpath "C:\PROGRA~1\MATLAB\R2009a\extern\lib\win32\lcc" @C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\MBUILD~1.RSP mclmcrrt.lib
--> "if exist C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\templib.def del C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\templib.def"
--> "if exist C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\templib_stub.obj del C:\DOCUME~1\MD4E3C~1.DEL\LOCALS~1\TEMP\MBUILD~1\templib_stub.obj"
'cmd' is not recognized as an internal or external command,
operable program or batch file.
Error: An error occurred while shelling out to mbuild (error code = 1).
Unable to build executable.
??? Error using ==> mcc
Error executing mcc, return status = 1 (0x1).
There were errors during compilation process.
I am currently using R2009a & installed the MCRInstaller. Please help me!!! Thanks in advance.

Answers (0)

Categories

Find more on C Shared Library Integration in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!