MATLAB: Error LNK2019 when trying to use C++ program of CurveLab-2.1.3

curvelabcurvelab link mexcurvelab toolboxmex

Hello everyone,
I am working with CurveLab2.1.3 downloaded from this website and I am trying now to generate 'mexw64' file using mex command in Matlab,
I've got this link error after running this command:
mex -largeArrayDims fdct3d_forward_mex.cpp -llibfftw3-3 -llibfftw3f-3 -llibfftw3l-3 -L"C:\fftw-3.3.4-dll64" libfdct3d.a libfftw.a
Création de la bibliothèque C:\Users\mariam\AppData\Local\Temp\mex_pfrp1Y\templib.x et de l'objet C:\Users\mariam\AppData\Local\Temp\mex_pfrp1Y\templib.exp
fdct3d_forward_mex.obj : error LNK2019: symbole externe non résolu "int __cdecl fdct3d_forward(int,int,int,int,int,int,class NumTns<class std::complex<double> > &,class std::vector<class std::vector<class NumTns<class std::complex<double> >,class std::allocator<class NumTns<class std::complex<double> > > >,class std::allocator<class std::vector<class NumTns<class std::complex<double> >,class std::allocator<class NumTns<class std::complex<double> > > > > > &)" (?fdct3d_forward@@YAHHHHHHHAEAV?$NumTns@V?$complex@N@std@@@@AEAV?$vector@V?$vector@V?$NumTns@V?$complex@N@std@@@@V?$allocator@V?$NumTns@V?$complex@N@std@@@@@std@@@std@@V?$allocator@V?$vector@V?$NumTns@V?$complex@N@std@@@@V?$allocator@V?$NumTns@V?$complex@N@std@@@@@std@@@std@@@2@@std@@@Z) référencé dans la fonction mexFunction
fdct3d_forward_mex.mexw64 : fatal error LNK1120: 1 externes non résolus
C:\PROGRA~1\MATLAB\R2013A\BIN\MEX.PL: Error: Link of 'fdct3d_forward_mex.mexw64' failed.
Error using mex (line 206) Unable to complete successfully.
I would appreciate your help Thank you in advance

Best Answer

I am writing this time to notify that I found a solution to this problem and this is thanks to you Geoff.
I was using Matlab on Windows. I moved on Ubuntu, I compiled my FFTW using
./configure --disable-shared
make
make install
then, I turned to Curvelab project under matlab, and I ran make and make matlab . and my program is successfully running!
Best regards
Related Question