Hello,
I've just started using MEX to execute C functions in matlab, but I am facing some linking issues.
This is the example I used to see if the linking process is working:
#include <mex.h>
#include <pmdsdk2.h>
char err[128];
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
pmdGetLastError (0, err, 128);
}
The pmdGetLastError belongs to pdmsdk2.h
And this is the mex command I am using:
>> mex -ID:/TransientPMD/CaptureTool/include D:/TransientPMD/CaptureTool/test.cpp D:/TransientPMD/CaptureTool/lib/pmdaccess2.lib
Error: test.obj : error LNK2019: unresolved external symbol __imp_pmdGetLastError referenced in function mexFunction
I've just started using MEX to execute C functions in matlab, but I am facing some linking issues.
This is the example I used to see if the linking process is working:
#include <mex.h>
#include <pmdsdk2.h>
char err[128];
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
pmdGetLastError (0, err, 128);
}
The pmdGetLastError belongs to pdmsdk2.h
And this is the mex command I am using:
>> mex -ID:/TransientPMD/CaptureTool/include D:/TransientPMD/CaptureTool/test.cpp D:/TransientPMD/CaptureTool/lib/pmdaccess2.lib
Error: test.obj : error LNK2019: unresolved external symbol __imp_pmdGetLastError referenced in function mexFunction