ошибка mex во время vl_compilenn

Я пытаюсь установить MatConvNet, как описано здесь. Когда я запускаю vl_compilenn, я получаю следующую ошибку:

>> vl_compilenn
Building with 'Microsoft Windows SDK 7.1 (C++)'.
MEX completed successfully. % ... repeated many times, then suddenly : 
Error using mex
MEX cannot find library 'gdiplus' specified with the -l option.
 MEX looks for a file with one of the names:
 libgdiplus.lib
 gdiplus.lib
 Please specify the path to this library with the -L option.


Error in vl_compilenn>mex_link (line 456)
mex(mopts{:}) ;

Error in vl_compilenn (line 408)
  mex_link(opts, objs, mex_dir, flags.link) ;

Как мне установить эту библиотеку или сделать все необходимое, чтобы избавиться от этой ошибки?

Я использую MATLAB R2015b на 64-битной Windows 7. Я также успешно запустил mex в некоторых других файлах, но я совершенно уверен, что в этой библиотеке (MatConvNet) нет большой ошибки, поэтому, вероятно, я что-то упускаю. тривиальный, но важный файл. Но я не уверен, что.

Спасибо за любую помощь!

Редактировать

Когда я попытался скопировать gdiplus.lib в предложенное место, я получил другую ошибку:

...
Building with 'Microsoft Windows SDK 7.1 (C++)'.
MEX completed successfully.
Building with 'Microsoft Windows SDK 7.1 (C++)'.
MEX completed successfully.
Building with 'MinGW64 Compiler (C)'.
Error using mex
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
Warning: corrupt .drectve at end of def file
C:\MATLAB\matconvnet-1.0-beta16\matlab\mex\.build\vl_nnconv.obj:(.text[?vlmxError@@YAXW4_VlmxErrorId@@PEBDZZ]+0x178):
undefined reference to `__security_check_cookie'
C:\MATLAB\matconvnet-1.0-beta16\matlab\mex\.build\vl_nnconv.obj:(.xdata[$unwind$?vlmxError@@YAXW4_VlmxErrorId@@PEBDZZ]+0xc):
undefined reference to `__GSHandlerCheck'
C:\MATLAB\matconvnet-1.0-beta16\matlab\mex\.build\vl_nnconv.obj:(.text[?vlmxNextOption@@YAHQEAPEBUmxArray_tag@@HPEBU_vlmxOption@@PEAHPEAPEBU1@@Z]+0x239):
undefined reference to `__security_check_cookie'
C:\MATLAB\matconvnet-1.0-beta16\matlab\mex\.build\vl_nnconv.obj:(.xdata[$unwind$?vlmxNextOption@@YAHQEAPEBUmxArray_tag@@HPEBU_vlmxOption@@PEAHPEAPEBU1@@Z]+0x10):
undefined reference to `__GSHandlerCheck'
C:\MATLAB\matconvnet-1.0-beta16\matlab\mex\.build\vl_nnconv.obj:(.xdata[$unwind$mexFunction]+0x1c):
... and thousands of lines like this :)    
collect2.exe: error: ld returned 1 exit status


Error in vl_compilenn>mex_link (line 456)
mex(mopts{:}) ;

Error in vl_compilenn (line 408)
  mex_link(opts, objs, mex_dir, flags.link) ;

Редактировать 2

Это, а также выбор Microsoft Windows SDK 7.1 (C) в качестве компилятора mex решает проблему.


person jeff    schedule 23.11.2015    source источник


Ответы (1)


Сегодня у меня была такая же проблема с MATLAB R2015b. Я исправил эту ошибку, выполнив поиск файла «gdiplus.lib» в моем каталоге установки Matlab («C:\Program Files\MATLAB\R2015b\sys\lcc64\lcc64\lib64»), а затем скопировав его в следующее место внутри Каталог установки MATLAB ("C:\Program Files\MATLAB\R2015b\extern\lib\win64").

person Sohi    schedule 25.11.2015
comment
Большое спасибо. Но это не сработало для меня. Вы уверены, что это lib\win64, а не lib\win64\mingw64? Во всяком случае, ни один из них не работал для меня. Я обновил вопрос с новым сообщением об ошибке. Спасибо еще раз, - person jeff; 26.11.2015
comment
Я также получил обновленную ошибку. Просто попробуйте «mex -setup C» и выберите компилятор Microsoft C из вариантов. Это решило ошибку для меня. - person Sohi; 27.11.2015
comment
Вы имеете в виду Microsoft Windows SDK 7.1 (C), верно? Это решает проблему. Спасибо еще раз ! - person jeff; 27.11.2015