can not run mex function

8 visualizaciones (últimos 30 días)
ammar al jodah
ammar al jodah el 15 de Feb. de 2013
hello i have this error when want to compile c-file on MATLAB 2011b , i use WIN 7 64 bit, any help will be appreciated:
>> mex -setup
Welcome to mex -setup. This utility will help you set up a default compiler. For a list of supported compilers, see http://www.mathworks.com/support/compilers/R2011b/win64.html
Please choose your compiler for building MEX-files:
Would you like mex to locate installed compilers [y]/n? y
Select a compiler: [1] Microsoft Software Development Kit (SDK) 7.1 in C:\Program Files (x86)\Microsoft Visual Studio 10.0
[0] None
Compiler: 1
Please verify your choices:
Compiler: Microsoft Software Development Kit (SDK) 7.1 Location: C:\Program Files (x86)\Microsoft Visual Studio 10.0
Are these correct [y]/n? y
************************************************************************* Warning: MEX-files generated using Microsoft Windows Software Development Kit (SDK) require that Microsoft Visual Studio 2010 run-time libraries be available on the computer they are run on. If you plan to redistribute your MEX-files to other MATLAB users, be sure that they have the run-time libraries. *************************************************************************
Trying to update options file: C:\Users\DELL\AppData\Roaming\MathWorks\MATLAB\R2011b\mexopts.bat From template: C:\PROGRA~1\MATLAB\R2011b\bin\win64\mexopts\mssdk71opts.bat
Done . . .
************************************************************************ Warning: The MATLAB C and Fortran API has changed to support MATLAB variables with more than 2^32-1 elements. In the near future you will be required to update your code to utilize the new API. You can find more information about this at: http://www.mathworks.com/support/solutions/en/data/1-5C27B9/?solution=1-5C27B9 Building with the -largeArrayDims option enables the new API. ************************************************************************
>> mex sfun_time.c -lmwlapack -lmwblas
C:\PROGRA~1\MATLAB\R2011B\BIN\MEX.PL: Error: Compile of 'sfun_time.c' failed.
Error using mex (line 206) Unable to complete successfully.
>>
  3 comentarios
ammar al jodah
ammar al jodah el 15 de Feb. de 2013
Editada: ammar al jodah el 15 de Feb. de 2013
>> mex -v sfun_time.c -lmwlapack -lmwblas
-> Default options filename found in C:\Users\DELL\AppData\Roaming\MathWorks\MATLAB\R2011b
----------------------------------------------------------------
-> Options file = C:\Users\DELL\AppData\Roaming\MathWorks\MATLAB\R2011b\mexopts.bat
MATLAB = C:\Program Files\MATLAB\R2011b
-> COMPILER = cl
-> Compiler flags:
COMPFLAGS = /c /GR /W3 /EHs /D_CRT_SECURE_NO_DEPRECATE /D_SCL_SECURE_NO_DEPRECATE /D_SECURE_SCL=0 /DMATLAB_MEX_FILE /nologo /MD
OPTIMFLAGS = /O2 /Oy- /DNDEBUG
DEBUGFLAGS = /Z7
arguments =
Name switch = /Fo
-> Pre-linking commands =
-> LINKER = link
-> Link directives:
LINKFLAGS = /dll /export:mexFunction /LIBPATH:"C:\Program Files\MATLAB\R2011b\extern\lib\win64\microsoft" libmx.lib libmex.lib libmat.lib /MACHINE:X64 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /manifest /incremental:NO /implib:"C:\Users\DELL\AppData\Local\Temp\mex_vcybrd\templib.x" /MAP:"sfun_time.mexw64.map"
LINKDEBUGFLAGS = /debug /PDB:"sfun_time.mexw64.pdb"
LINKFLAGSPOST =
Name directive = /out:"sfun_time.mexw64"
File link directive =
Lib. link directive =
Rsp file indicator = @
-> Resource Compiler = rc /fo "mexversion.res"
-> Resource Linker =
----------------------------------------------------------------
--> cl /c /GR /W3 /EHs /D_CRT_SECURE_NO_DEPRECATE /D_SCL_SECURE_NO_DEPRECATE /D_SECURE_SCL=0 /DMATLAB_MEX_FILE /nologo /MD /FoC:\Users\DELL\AppData\Local\Temp\mex_vcybrd\sfun_time.obj -I"C:\Program Files\MATLAB\R2011b\extern\include" -I"C:\Program Files\MATLAB\R2011b\simulink\include" /O2 /Oy- /DNDEBUG -DMX_COMPAT_32 sfun_time.c
C:\PROGRA~1\MATLAB\R2011B\BIN\MEX.PL: Error: Compile of 'sfun_time.c' failed.
Error using mex (line 206)
Unable to complete successfully.
>>
ammar al jodah
ammar al jodah el 16 de Feb. de 2013
please help

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre MATLAB Compiler en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by