From: kk KKsingh on 21 May 2010 18:39 Hi I am trying to run a nfftmex.c by mex nfftmex.c ..compilation is failing with a meaasge no mexversion.c i am running it in matlab2009..which is on my college linux server .........i check the file nfftmex.c #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 Last three lines ar including mexversion.c Aki "Gadi Reinhorn" <gadi.reinhorn(a)mathworks.com> wrote in message <hb7f2q$8h1$1(a)fred.mathworks.com>... > Emre, > > That sounds really frustrating. I'll address your observations in reverse > order: > > 1) Dependency on mexversion.c. > We removed this dependency in R2009a. So that indicates to me that the mex > script that you are running is a version before R2009a. You should check > your system PATH. Perhaps you have access to something like a "which" > function to help you identify which version of mex is being found. > Make sure you are using the R2009b version. > > 2) I'm surprised the usage message does not mention -setup. Which I believe > is partly the issue with the initial "Sorry!" message. > > 3) I think that message is not ideal. I believe it should direct you to > running mex -setup. In fact, I believed that mex should run -setup > automatically if it does not find an options file in your preference > directory. That explains why it's complaining that it can't find > "MATLAB/bin/mexopts.sh". It's the wrong mex script that is being run. > So we cycle back to issue (1) above. > > In conclusion, I'll look at improving our messaging, but I believe the root > cause of your troubles are that you are running the wrong mex build script. > > Hope that helps, > > Gadi > > > > > > "Emre " <emre.ozdemir(a)epfl.ch> wrote in message > news:hb79g1$qu0$1(a)fred.mathworks.com... > > Hi all, > > > > I recently upgraded to MATLAB 2009b and having problems with mex (on OSX > > 10.6.1). I am not familiar with the use of mex so please let me know if > > you need additional information on the following. > > > > mex is giving me the following output whatever I do: > > > > --- > > user(a)home $ mex > > > > Sorry! No options file was found for mex. > > The mex script must be able to source > > an options file to define compiler flags > > and other settings. This options file > > is normally found in MATLAB/bin/mexopts.sh. > > Please check to make sure that your installation > > is complete and includes this file. > > > > Here > > > > MATLAB = /usr/local > > > > Please contact: > > > > MathWorks Technical Support > > > > for further assistance. > > --- > > > > As far as I understand the options file was not on $PATH, so put it on > > $PATH. Result is the expected output (I guess): > > > > --- > > user(a)home $ mex > > > > mex: no file name given. > > > > Usage: > > MEX [option1 ... optionN] sourcefile1 [... sourcefileN] > > [objectfile1 ... objectfileN] [libraryfile1 ... libraryfileN] > > > > or (to build an Ada S-function): > > MEX [-v] [-g] -ada <sfcn>.ads > > > > Use the -help option for more information, or consult the MATLAB > > External Interfaces Guide. > > > > --- > > > > When I try to use this to build the file, I get this: > > > > --- > > user(a)home $ mex -I../.. -I../../../include -L../.. > > TranslateSBML.c -lsbml > > > > mex: /Applications/MATLAB_R2009b.app/extern/src/mexversion.c not a > > normal file or does not exist. > > --- > > > > The file mex is looking for is not found anywhere. > > > > I don't know if this is due to some installation problem or not. I would > > appreciate any input. > > > > Thank! >
From: kk KKsingh on 21 May 2010 19:00 "kk KKsingh" <akikumar1983(a)gmail.com> wrote in message <ht7228$g3$1(a)fred.mathworks.com>... > > Hi I am trying to run a nfftmex.c by mex nfftmex.c ..compilation is failing with a meaasge no mexversion.c i am running it in matlab2009..which is on my college linux server .........i check the file nfftmex.c > > #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 > > Last three lines ar including mexversion.c > > Aki > > "Gadi Reinhorn" <gadi.reinhorn(a)mathworks.com> wrote in message <hb7f2q$8h1$1(a)fred.mathworks.com>... > > Emre, > > > > That sounds really frustrating. I'll address your observations in reverse > > order: > > > > 1) Dependency on mexversion.c. > > We removed this dependency in R2009a. So that indicates to me that the mex > > script that you are running is a version before R2009a. You should check > > your system PATH. Perhaps you have access to something like a "which" > > function to help you identify which version of mex is being found. > > Make sure you are using the R2009b version. > > > > 2) I'm surprised the usage message does not mention -setup. Which I believe > > is partly the issue with the initial "Sorry!" message. > > > > 3) I think that message is not ideal. I believe it should direct you to > > running mex -setup. In fact, I believed that mex should run -setup > > automatically if it does not find an options file in your preference > > directory. That explains why it's complaining that it can't find > > "MATLAB/bin/mexopts.sh". It's the wrong mex script that is being run. > > So we cycle back to issue (1) above. > > > > In conclusion, I'll look at improving our messaging, but I believe the root > > cause of your troubles are that you are running the wrong mex build script. > > > > Hope that helps, > > > > Gadi > > > > > > > > > > > > "Emre " <emre.ozdemir(a)epfl.ch> wrote in message > > news:hb79g1$qu0$1(a)fred.mathworks.com... > > > Hi all, > > > > > > I recently upgraded to MATLAB 2009b and having problems with mex (on OSX > > > 10.6.1). I am not familiar with the use of mex so please let me know if > > > you need additional information on the following. > > > > > > mex is giving me the following output whatever I do: > > > > > > --- > > > user(a)home $ mex > > > > > > Sorry! No options file was found for mex. > > > The mex script must be able to source > > > an options file to define compiler flags > > > and other settings. This options file > > > is normally found in MATLAB/bin/mexopts.sh. > > > Please check to make sure that your installation > > > is complete and includes this file. > > > > > > Here > > > > > > MATLAB = /usr/local > > > > > > Please contact: > > > > > > MathWorks Technical Support > > > > > > for further assistance. > > > --- > > > > > > As far as I understand the options file was not on $PATH, so put it on > > > $PATH. Result is the expected output (I guess): > > > > > > --- > > > user(a)home $ mex > > > > > > mex: no file name given. > > > > > > Usage: > > > MEX [option1 ... optionN] sourcefile1 [... sourcefileN] > > > [objectfile1 ... objectfileN] [libraryfile1 ... libraryfileN] > > > > > > or (to build an Ada S-function): > > > MEX [-v] [-g] -ada <sfcn>.ads > > > > > > Use the -help option for more information, or consult the MATLAB > > > External Interfaces Guide. > > > > > > --- > > > > > > When I try to use this to build the file, I get this: > > > > > > --- > > > user(a)home $ mex -I../.. -I../../../include -L../.. > > > TranslateSBML.c -lsbml > > > > > > mex: /Applications/MATLAB_R2009b.app/extern/src/mexversion.c not a > > > normal file or does not exist. > > > --- > > > > > > The file mex is looking for is not found anywhere. > > > > > > I don't know if this is due to some installation problem or not. I would > > > appreciate any input. > > > > > > Thank! > > Sorry folks i got the solution ! I just need to comment those lines which include mexversion.c for matlab 2009 Thanks kk
|
Pages: 1 Prev: Question about Symbolic Tool Box Next: How to include a path |