Compiling MATLAB, YALMIP and CPLEX , Syntax error

조회 수: 6 (최근 30일)
Sander van der Stelt
Sander van der Stelt 2017년 6월 5일
답변: Arnav Mendiratta 2017년 6월 13일
I'm trying to compile a matlab script with CPLEX and YALMIP as a standalone executable using the mcc command. I'm using matlab R2016b on a 64 bit linux system with the latest YALMIP version and CPLEX 12.7. I Receive the following error
mcc -mv file.m -I /home/user/yalmipdirectories -I /home/user/cplexdirectory -a /call_cplexibm_qcmiqp.m -a /cplexqcp.m -a /cplexlink1271.mexa64
Compiler version: 6.3 (R2016b) Dependency analysis by REQUIREMENTS. Error using matlab.depfun.internal.cacheMtree (line 29) MATLAB code '/home/user/CPLEX_Studio/cplex/matlab/x86-64_linux/cplexmilp.m' contains the following syntax error(s): L 56 (C 1): SYNER: Parse error at '.': usage might be invalid MATLAB syntax.
Error in isClassdef>hasClassDef (line 37) mt = matlab.depfun.internal.cacheMtree(file);
Error in isClassdef (line 21) tf = hasClassDef(file);
Error in className_impl (line 118) elseif isClassdef(whichResult)
Error in className (line 13) [name, clsFile] = className_impl(whichResult);
Error in matlab.depfun.internal.MatlabSymbol/determineClassType (line 750) [name, clsFile] = className(symObj.WhichResult);
Error in matlab.depfun.internal.MatlabSymbol/getTypeUsingEnvironment (line 714) determineClassType(symObj);
Error in matlab.depfun.internal.MatlabSymbol/determineMatlabType (line 652) getTypeUsingEnvironment(symObj);
Error in matlab.depfun.internal.MatlabSymbol/determineSymbolType (line 841) determineMatlabType(symbol);
Error in matlab.depfun.internal.MwFileInspector/evaluateSymbols (line 293) determineSymbolType(symObj, obj.fsCache, obj.addExclusion);
Error in matlab.depfun.internal.MwFileInspector/analyzeSymbol (line 34) evaluateSymbols(obj, symlist, client);
Error in matlab.depfun.internal.Completion/findDependentFiles (line 1349) analyzeSymbol(inspector, symbol);
Error in matlab.depfun.internal.Completion/computeDependencies (line 263) findDependentFiles(obj);
Error in matlab.depfun.internal.Completion/computePartsList (line 2012) computeDependencies(obj);
Error in matlab.depfun.internal.Completion/requirements (line 2412) parts = computePartsList(obj, false);
Error in matlab.depfun.internal.requirements (line 215) [parts, resources.products, resources.platforms] = c.requirements();
Unexpected error while determining required deployable files. Compilation terminated.
Can anyone help me with this? So far I have been unable to create a working executable with YALMIP only, adding CPLEX seems to cause the problem.

답변 (1개)

Arnav Mendiratta
Arnav Mendiratta 2017년 6월 13일
The error happens is the third party file:
'/home/user/CPLEX_Studio/cplex/matlab/x86-64_linux/cplexmilp.m'
This is not a MahtWorks' shipped file. Make sure you are using supported MATLAB version with CPLEX. Error seems to point out that some functionality changed with the older/newer release of MATLAB.
Reach out to the IBM team for help with this specific file.

카테고리

Help CenterFile Exchange에서 Write C Functions Callable from MATLAB (MEX Files)에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by