Generation of dll file from a MATLAB function

4 visualizzazioni (ultimi 30 giorni)
Tarun Santosh
Tarun Santosh il 13 Gen 2021
Risposto: Pratyush il 16 Feb 2024
I have created a MATLAB function file which minimizes an objective function using "fminbnd". The objective function also has "interp2" function to look up values from a 2d lookup table. I used "Library compiler" to generate dll for the function file. It generated only one dll file. Now when i am trying to use this dll file in a different modeling environment, i am getting an error that another dll file is missing. Is this error because i used inbuilt MATLAB functions and havent generated their dlls? If so, how should i proceed further?

Risposte (1)

Pratyush
Pratyush il 16 Feb 2024
Hi Tarun,
To resolve the missing DLL error when using a MATLAB compiled function in a different environment, make sure to:
  • Install the MATLAB Runtime on the target machine.
  • Distribute all generated files from the compilation process to the target machine.
  • Set the necessary environment variables, such as the `PATH`, to include the MATLAB Runtime.
  • Review the `MWDeployXML` file for any additional dependencies.
  • Ensure proper licensing for MATLAB Compiler and MATLAB Runtime.
  • Use the `-a` option during compilation to include any additional required files.

Categorie

Scopri di più su MATLAB Compiler in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by