loadlibrary mfilename put in sub folder
Ältere Kommentare anzeigen
I have a rather large Matlab project (over 100 function files etc.) which I have organised into folders to make it easier to keep track of. The project at its heart has a C DLL which it loads to access some physical hardware. When this is loaded it creates an m file (named through the 'mfilename' option when calling 'loadlibrary'). I would like if possible this m file to be placed in one of the subdirectories not the top level (current) directory.
I tried simply changing the mfilename option to include a relative path but this was completely ignored and the mfile placed in the top directory regardless.
Is there anyway of getting this to happen automatically?
Furthermore, is it possible to get the 'thunk' files to also be placed in a subdirectory to keep things clean?
---
Along similar lines but less importantly, when compiling mex functions, is it possible to specify the output directory for them?
Akzeptierte Antwort
Weitere Antworten (1)
Sean de Wolski
am 20 Jul. 2015
To your second question, Yes:
web(fullfile(docroot, 'matlab/ref/mex.html'))
Look at the 'outdir' option.
1 Kommentar
Thomas Carpenter
am 21 Jul. 2015
Kategorien
Mehr zu File Operations finden Sie in Hilfe-Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!