How to add a command to .p file

5 views (last 30 days)
Faisalmk
Faisalmk on 9 Nov 2013
Commented: dpb on 9 Nov 2013
Dear all,
I want to convert a MATLAB code with .m extension that calls a function from ILOG CPLEX software to solve Mixed Integer Programs to a MEX file in C language for faster execution. When I tried to build the code, I received the following message: " Warning: The specified compiler (msvcsdk) does not support the OpenMP library; turning off parallelization. ??? P-file 'C:/Program Files/IBM/ILOG/CPLEX_Studio125/cplex/matlab/x64_win64/cplexmilp.p' is not authorized for compilation. To support compilation, please consider using 'coder.allowpcode' in this file. When the file defines a MATLAB class, 'coder.allowpcode' should be added to the class constructor." How can I modify the specified file to include this command in it? Or is there any other way to solve this problem. Thanks in advance and help is highly appreciated.

Accepted Answer

dpb
dpb on 9 Nov 2013
Short answer is "can't" unless you have the source from which the p-file was built.
  3 Comments
Azzi Abdelmalek
Azzi Abdelmalek on 9 Nov 2013
Faisalmk, when you accept an answer, that means the problem is solved
dpb
dpb on 9 Nov 2013
Never used the coder so best I can tell you is contained at

Sign in to comment.

More Answers (0)

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!