Create a standalone application on linux

Hi everyone,
I'm Mirko from Italy. I need some helps to compiling/create a stand alone application from .m files created from a colleague. To simplify the job and understanding the process I work with a simple function without gui/toolbox calling.
Let's start:
linux/matlab command answer
OS is linux
uname -r 2.6.34.7-0.7-desktop
arch x86_64
matlab version:2009b
My simple example snippet work on matlab env. It get two input parameters and perform a sum.
.m
function [result] = DoSum(x1, x2)
% This function add two numbers
X = str2num(x1)
Y = str2num(x2);
result=X+Y;
end
I try to run
deploytool
but it doesn't work (command not found) maybe this tool is available only on newer version...
I try also with (inside folder that contains my .m file)
mcc DoSum.m -o DoSum
the answer is
*g++: error trying to exec 'cc1obj': execvp: No such file or directory *
Then I try with mbuild, to check compiler setting.
mbuild If 'mbuild' is not a typo you can use command-not-found to lookup the package that contains it, like this: cnf mbuild
I search trough the file system but nothing like "mbuild" was found.
I'm only an external consultant, maybe the MathLab compiler is not well installed or need to be configured, but I don't know how to find this information or fix it. Can you help me?
Thank you in advance, Mirko

댓글 수: 1

Chirag Gupta
Chirag Gupta 2012년 1월 3일
Can you type ver on the MATLAB Command Prompt to check whether the MATLAB Compiler is installed? If installed, it will show up as one of the installed toolboxes!
R2009b did include deploytool

댓글을 달려면 로그인하십시오.

답변 (3개)

Andreas Goser
Andreas Goser 2012년 1월 3일

0 개 추천

Please provide the output of the command
ver
Then we can see if the needed products are installed.

댓글 수: 1

Andreas Goser
Andreas Goser 2012년 1월 4일
Your license 620030 simply does not includes the products you need for this task. I will contact a MathWorks person for you, that can help you.

댓글을 달려면 로그인하십시오.

Walter Roberson
Walter Roberson 2012년 1월 3일

0 개 추천

mbuild and deploytool need to be invoked from inside MATLAB.
Mirko
Mirko 2012년 1월 3일

0 개 추천

Here additional informations from matlab IDE...
>> ver
-------------------------------------------------------------------------------------
MATLAB Version 7.9.0.529 (R2009b)
MATLAB License Number: 620030
Operating System: Linux 2.6.34.7-0.7-desktop #1 SMP PREEMPT 2010-12-13 11:13:53 +0100 x86_64
Java VM Version: Java 1.6.0_12-b04 with Sun Microsystems Inc. Java HotSpot(TM) 64-Bit Server VM mixed mode
-------------------------------------------------------------------------------------
MATLAB Version 7.9 (R2009b)
Fuzzy Logic Toolbox Version 2.2.10 (R2009b)
Mapping Toolbox Version 3.0 (R2009b)
Statistics Toolbox Version 7.2 (R2009b)
>>
>> displaytool
??? Undefined function or variable 'displaytool'.
>> mcc
??? Undefined function or variable 'mcc'.

댓글 수: 2

Walter Roberson
Walter Roberson 2012년 1월 3일
deploytool, not displaytool
Anyhow, you do not have the Compiler toolbox installed. It is an optional (and expensive) product.
Mirko
Mirko 2012년 1월 3일
I don't see MatLab compiler license line... Maybe this is the problem!

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터File Exchange에서 C Shared Library Integration에 대해 자세히 알아보기

질문:

2012년 1월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by