I can compile and link my mex program. However, when I try to run it through a matlab program, I get
Invalid MEX-file 'D:my_mex.mexw64': The specified module could not be found.
This must be a problem with the calls to the ipp library as when I remove them, it does not crash.
I am using Windows 7 and compiling via the compiler:
Intel C++ 13.0 in %ICPP_COMPILER13%
my compile line is matlab is:
mex -v -g my_mex.cpp -L"C:\Program Files (x86)\Intel\Composer XE 2013\mkl\lib\intel64" -lmkl_intel_lp64 -lmkl_core -lmkl_sequential -lmkl_cdft_core -lmkl_intel_thread -L"C:\Program Files (x86)\Intel\Composer XE 2013\ipp\lib\intel64" -lippm -lippm_l
Does anyone have any suggestions?
It seemed as if we were missing the file: libiomp5md.dll. After attempting a re-install of the Intel Composer 2013 version 7.1, this file now appears to be there. We did check the ipp and mkl paths which are currently set to:
with INTEL_DEV_REDIST set to:
C:\Program Files (x86)\Common Files\Intel\Shared Libraries\
The error I now get is:
Invalid MEX-file 'D:\my_mex.mexw64': A dynamic link library (DLL) initialization routine failed.
OK, I compiled using every static library:
mex -v -g my_mex.cpp -L"C:\Program Files (x86)\Intel\Composer XE 2013\mkl\lib\intel64" -lmkl_intel_lp64 -lmkl_core -lmkl_sequential -lmkl_cdft_core -lmkl_intel_thread -L"C:\Program Files (x86)\Intel\Composer XE 2013\ipp\lib\intel64" -lippm_l -lippac_l -lippcc_l -lippch_l -lippcore_l -lippcv_l -lippdc_l -lippdi_l -lippdj_l -lippr_l -lipps_l -lippsc_l -lippvc_l -lippvm_l
and it seems to get over the dll issues. Not sure if I really need all those libraries, but it seems to work.
IPP hierarchy is the next: all IPP domains (libraries) are based on ippCore library, so when you linked with ippm domain (small matrix) you also should add ippcore. It's nothing wrong when linking statically to define all ipp libraries in the cmd line - linker will link only those obj that are used in your app.