Create .lib file with matlab compiler
13 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi,
I'm trying to compile a simple function with the matlab compiler (2007b).
the compilation ends with the following lines:
--------------------------------------------------
Copying: D:\...\src\MyLib.lib -> D:\...\distrib
Could not copy file to the output directory.
--------------------------------------------------
The .lib file is only available in the intermediate folder (\src). I'm able to load and call the function from the generated DLL but when I try to link to the .lib I get a runtime error when my application loads.
Any idea how to properly create a .lib?
Thanks,
Yoni
0 comentarios
Respuestas (1)
Kaustubha Govind
el 4 de Ag. de 2011
I don't know that it is possible to create a static library using MATLAB Compiler. The .lib file that you see generated is the import library for the generated DLL - it needs to be used with the DLL. What is the runtime error that you see after linking against the .lib file? Is it about being unable to find the corresponding DLL? In that case, you should simply have to add the DLL to the system path.
(I'm not sure why the error about being unable to copy occurs)
0 comentarios
Ver también
Categorías
Más información sobre C Shared Library Integration en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!