Visual Studio property sheets for rapidly configuring a project to build a MEX file.
The usage of the property sheets (.props files) is described at http://stackoverflow.com/a/27391300/2778484. In short, just set the `MATLAB_ROOT` and/or `MATLAB32_ROOT` environment variables (for 32-bit and 64-bit versions, respectively), and include the property sheet (MATLAB.props) into your DLL project:
![add MEX property sheet to Visual Studio project](http://i.stack.imgur.com/pnmDB.png)
The relevant settings configured automatically by the property sheet include:
1. Adding `$(MATLAB_ROOT)\extern\include` to the `AdditionalIncludeDirectories` paths (with inherited paths from parent configurations) -- the location of mex.h.
2. Adding `$(MATLAB_ROOT)\extern\lib\win64\microsoft` to the `AdditionalLibraryDirectories` paths -- the location of libmex.lib, etc.
3. Listing the libraries: `libut.lib;libmx.lib;libmex.lib;libmat.lib`.
4. Exporting `mexFunction` (it's a shared library): `/EXPORT:mexFunction`.
5. Setting the output file extention (e.g. `.mexw64` for x64).
6. Sets MATLAB_MEX_FILE (helpful to signal to your own headers if they are being used in a MEX file).
7. Turns on generation of data required for profiling.
The files MATLABx64.props and MATLABx86.props are for 64-bit and 32-bit MATLAB, respectively. MATLAB.props is supposed to work for either 32-bit or 64-bit MATLAB using conditional expressions, but I have not tested it extensively.
MATLAB-C++.zip
141 浏览量
2023-08-17
12:10:02
上传
评论
收藏 17KB ZIP 举报
paterWang
- 粉丝: 1102
- 资源: 1279
最新资源
- 基于 python 操作大数据的各种组件
- cifar-10-python和cifar-100-python
- 基于 C#实现神经网络算法和遗传算法作为AI的中国象棋程序
- Windows server 2016.2019 .NET Frameword 3.5安装包
- chilkat 9.5.0.98 系列软件 global unlock code
- 基于 python神经网络实现人类颜值评分
- 使用android实现计算器功能
- 305建筑结构水电欧式6套(14.5x20.2)\施工图1-11卫生间大样031026.dwg
- 305建筑结构水电欧式6套(14.5x20.2)\施工图1-09楼梯大样031026.dwg
- 基于PCL、C++编写的格网边缘点检测程序与代码
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈