What's the difference between deploytool and mbuild, mcc?
显示 更早的评论
Hi, I'm not sure if this is the correct forum, but could anyone tell me the difference between Matlab's deploytool and the command line options mbuild, mcc? I'm trying to package a code using each of them, but the two options seem to act differently.
If I use deploytool, the exe only seems to run the first program, graph.m. That is, it plots the first function in a new window (but does not display the subtraction). Running mbuild and then mcc creates an executable that also opens a command line window, where the display('') and input commands take place. It also plots the second file. Any ideas why this happens?
I'm using Windows 7, Matlab R2013b, and my compiler is Microsoft Visual C++ 2010 in C:\Program Files (x86)\Microsoft Visual Studio 10.0.
----------
function graph
set(0,'DefaultFigureVisible','on'); %Ensure figures visible
a=[12,54,33,80,26];
b=[44,25,72,98,66];
display(a-b)
plot(a,b);
plot([1,2,3,4,5],[1,2,3,4,5]);
pause(2);
graph1;
end
----------
function graph1
name=input('name the graph:','s');
plot([1,2,3,4,5,6,7],[1,2,3,4,5,6,7]);
title(name);
end
回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 C Shared Library Integration 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!