Open wing92518 opened 8 years ago
You need the following code to implement `mex setup -c' 'mex setup -c++'
You need to select the both c and c++ compiler of the same type. I believe it works best with Visual Studio 2013, because I also faced this problem and read/tried so many solutions just to solve this problem.
I am not sure how to resolve the problem.
vl_compilenn: CUDA: MEX config file: 'C:\Program Files\MATLAB\R2016b\toolbox\distcomp\gpu\extern\src\mex\win64\mex_CUDA_win64.xml' vl_compilenn: * Compiler and linker configurations vl_compilenn: intermediate build products directory: C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build vl_compilenn: MEX files: C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex/ vl_compilenn: MEX options [CC CPU]: -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS vl_compilenn: MEX options [LINK]: -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -lmwblas -largeArrayDims LDFLAGS=$LDFLAGS LINKLIBS=$LINKLIBS gdiplus.lib vl_compilenn: * Reading images vl_compilenn: vl_imreadjpeg enabled vl_compilenn: image library: gdiplus vl_compilenn: image library compile flags: vl_compilenn: image library link flags: gdiplus.lib vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\data.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\datamex.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnconv.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnfullyconnected.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnsubsample.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnpooling.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnnormalize.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnbnorm.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnbias.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\nnbilinearsampler.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\im2row_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\subsample_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\copy_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\pooling_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\normalize_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\bnorm_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\tinythread.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\bilinearsampler_cpu.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\imread.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\bits\impl\imread_gdiplus.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnconv.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnconvt.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnpool.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnnormalize.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnbnorm.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_nnbilinearsampler.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX CC: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\src\vl_imreadjpeg.cpp -c -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -largeArrayDims CXXFLAGS=$CXXFLAGS CXXOPTIMFLAGS=$CXXOPTIMFLAGS Building with 'Microsoft Visual C++ 2015 Professional'. MEX completed successfully. vl_compilenn: MEX LINK: -outdir C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex -DNDEBUG -DENABLE_DOUBLE -DSSSE3 -lmwblas -largeArrayDims LDFLAGS=$LDFLAGS LINKLIBS=$LINKLIBS gdiplus.lib C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\vl_nnconv.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\data.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\datamex.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnconv.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnfullyconnected.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnsubsample.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnpooling.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnnormalize.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnbnorm.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnbias.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\nnbilinearsampler.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\im2row_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\subsample_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\copy_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\pooling_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\normalize_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\bnorm_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\tinythread.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\bilinearsampler_cpu.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\imread.obj C:\Users\fujitsu\Documents\matconvnet-1.0-beta20\matlab\mex.build\bits\impl\imread_gdiplus.obj Building with 'MinGW64 Compiler (C)'. Error using mex gcc: error: gdiplus.lib: No such file or directory
Error in vl_compilenn>mex_link (line 528) mex(mopts{:}) ;
Error in vl_compilenn (line 479) mex_link(opts, objs, mex_dir, flags.mexlink) ;