From: kk KKsingh on 21 May 2010 04:34 Walter Roberson <roberson(a)hushmail.com> wrote in message <0SpJn.36306$304.11049(a)newsfe12.iad>... > kk KKsingh wrote: > > > oh yes sorry ! Following is the error > > > > Attempt to execute Script nfftmex as a function > > /path/..../nfftmex.m > > > > Error in nfft_init_1d at 23 > > p = nfftmex('init_1d',N,M); > > That certainly tries to use nfftmex as a function. What are the first > few lines of nfftmex.m ? If it is just the documentation, then the error > you are seeing would be consistent with it not finding the mex object > file in the path. The mex object file should be in the same directory as > the documentation so that the help information is found. > > http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_prog/f10-60956.html#f10-60987 > > See "Precedence Rules" and "File Precedence" there. I got the reason for one error folder was not in path ! can any one tell me how can i set path in unix server without using GUI after putting everything in path following is error i am getting when using mex nfftmex.c mex nfftmex.c nfftmex.c:30:26: error: mexversion.c: No such file or directory nfftmex.c:43: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:55: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:73: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:96: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:116: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:122: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘int’ mex: compile of ' "nfftmex.c"' failed. ??? Error using ==> mex at 221 Unable to complete successfully. I have no idea what mexversion.c is its one of the files used in nfftmex.c following are lines #include <complex.h> #include <string.h> #include <stdio.h> #include "nfft3.h" #include "infft.h" #include "nfft3util.h" #include "imex.h" #ifdef HAVE_MEXVERSION_C #include "mexversion.c" #endif
From: kk KKsingh on 21 May 2010 19:02
"kk KKsingh" <akikumar1983(a)gmail.com> wrote in message <ht5gi5$o78$1(a)fred.mathworks.com>... > Walter Roberson <roberson(a)hushmail.com> wrote in message <0SpJn.36306$304.11049(a)newsfe12.iad>... > > kk KKsingh wrote: > > > > > oh yes sorry ! Following is the error > > > > > > Attempt to execute Script nfftmex as a function > > > /path/..../nfftmex.m > > > > > > Error in nfft_init_1d at 23 > > > p = nfftmex('init_1d',N,M); > > > > That certainly tries to use nfftmex as a function. What are the first > > few lines of nfftmex.m ? If it is just the documentation, then the error > > you are seeing would be consistent with it not finding the mex object > > file in the path. The mex object file should be in the same directory as > > the documentation so that the help information is found. > > > > http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_prog/f10-60956.html#f10-60987 > > > > See "Precedence Rules" and "File Precedence" there. > > > I got the reason for one error folder was not in path ! can any one tell me how can i set path in unix server without using GUI > > after putting everything in path following is error i am getting when using mex nfftmex.c > > mex nfftmex.c > nfftmex.c:30:26: error: mexversion.c: No such file or directory > nfftmex.c:43: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ > nfftmex.c:55: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ > nfftmex.c:73: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ > nfftmex.c:96: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ > nfftmex.c:116: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ > nfftmex.c:122: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘int’ > > mex: compile of ' "nfftmex.c"' failed. > > ??? Error using ==> mex at 221 > Unable to complete successfully. > > I have no idea what mexversion.c is > > its one of the files used in nfftmex.c following are lines > > #include <complex.h> > #include <string.h> > #include <stdio.h> > #include "nfft3.h" > #include "infft.h" > #include "nfft3util.h" > #include "imex.h" > > #ifdef HAVE_MEXVERSION_C > #include "mexversion.c" > #endif I commented out the lines having mexverion.c but i am still getting syntax error >> mex nfftmex.c nfftmex.c:29: error: expected identifier or ‘(’ before ‘%’ token nfftmex.c:29: error: stray ‘#’ in program nfftmex.c:30: error: stray ‘#’ in program nfftmex.c:31: error: stray ‘#’ in program nfftmex.c:43: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:55: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:73: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:96: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:116: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’ nfftmex.c:122: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘int’ nfftmex.c: In function ‘cleanup’: nfftmex.c:137: error: ‘gflags’ undeclared (first use in this function) nfftmex.c:137: error: (Each undeclared identifier is reported only once nfftmex.c:137: error: for each function it appears in.) nfftmex.c: In function ‘mexFunction’: nfftmex.c:151: error: ‘gflags’ undeclared (first use in this function) mex: compile of ' "nfftmex.c"' failed. ??? Error using ==> mex at 221 Unable to complete successfully. This is just a package which i installed and has a matlab interface its not written by me |