Thread Subject: Fortran MEX - Visul Studio Linker

Subject: Fortran MEX - Visul Studio Linker

From: Charan

Date: 10 Feb, 2008 18:50:32

Message: 1 of 7

Hi

I wanted to MEX function to compile a fortran code. I
bought Intel Fortran 9.1 (since the matlab site say that is
compatible to Matlab2007b).

When I load the compiler, I am getting this error. Please
help. It is very urgent.

Thanks,
Charan

----error-----------
Your machine has a Intel Visual Fortran compiler located at
C:\Program Files\Intel\Compiler\Fortran\9.1. Do you want to
use this compiler [y]/n? y
 
Please verify your choices:
 
Compiler: Intel Visual Fortran 9.1
Location: C:\Program Files\Intel\Compiler\Fortran\9.1
 
Are these correct?([y]/n): y
 
Error: Microsoft Visual Studio 2005 was not found by mex
-setup.
       The Microsoft Visual Studio 2005 linker is required
       to build Intel Fortran MEX-files. Please make sure that
       Microsoft Visual Studio 2005 is installed properly.
 
??? Error using ==> mex at 208
Unable to complete successfully.
-------------------------------------------

Subject: Fortran MEX - Visul Studio Linker

From: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)

Date: 10 Feb, 2008 18:52:29

Message: 2 of 7

In article <fonh1o$lqu$1@fred.mathworks.com>,
Charan <boyacharan@gmail.com> wrote:

>I wanted to MEX function to compile a fortran code. I
>bought Intel Fortran 9.1 (since the matlab site say that is
>compatible to Matlab2007b).

>When I load the compiler, I am getting this error. Please
>help. It is very urgent.

>Error: Microsoft Visual Studio 2005 was not found by mex
>-setup.
> The Microsoft Visual Studio 2005 linker is required
> to build Intel Fortran MEX-files. Please make sure that
> Microsoft Visual Studio 2005 is installed properly.

Are you saying that you *do* have Microsoft Visual Studio 2005
installed, but that Matlab is not able to find it?
--
  "To the modern spirt nothing is, or can be rightly known,
  except relatively and under conditions." -- Walter Pater

Subject: Fortran MEX - Visul Studio Linker

From: Charan

Date: 10 Feb, 2008 19:06:02

Message: 3 of 7


No. So Do I have to buy Visual Studio 2005 for just running
MEX Functions?

I see only "Common" folder under Visual Studio so I guess I
dont have Visual Studio on My comp. Is there any alternative
from not buying this?

THanks,
Charan

roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) wrote in
message <fonh5d$seq$1@canopus.cc.umanitoba.ca>...
> In article <fonh1o$lqu$1@fred.mathworks.com>,
> Charan <boyacharan@gmail.com> wrote:
>
> >I wanted to MEX function to compile a fortran code. I
> >bought Intel Fortran 9.1 (since the matlab site say that is
> >compatible to Matlab2007b).
>
> >When I load the compiler, I am getting this error. Please
> >help. It is very urgent.
>
> >Error: Microsoft Visual Studio 2005 was not found by mex
> >-setup.
> > The Microsoft Visual Studio 2005 linker is required
> > to build Intel Fortran MEX-files. Please make
sure that
> > Microsoft Visual Studio 2005 is installed properly.
>
> Are you saying that you *do* have Microsoft Visual Studio 2005
> installed, but that Matlab is not able to find it?
> --
> "To the modern spirt nothing is, or can be rightly known,
> except relatively and under conditions." -- Walter Pater

Subject: Fortran MEX - Visul Studio Linker

From: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)

Date: 10 Feb, 2008 19:47:28

Message: 4 of 7

In article <fonhuq$1hg$1@fred.mathworks.com>,
Charan <boyacharan@gmail.com> wrote:

>No. So Do I have to buy Visual Studio 2005 for just running
>MEX Functions?

http://www.mathworks.com/support/tech-notes/1600/1601.html?BB=1#n7

  7. Intel compilers depend on tools provided by Microsoft
  development products. The following combinations are supported by
  MATLAB and Simulink related products:

(Table showing Intel Visual Fortran 9.1 requires Microsoft Visual
Studio 2005 SP1 Professional Edition, and VF 9.0 requires that
or MS Visual Studio .NET 2003 Professional Edition or
Microsoft Platform SDK for Windows Server 2003)


I do not know if you need VS 2005 for -running- MEX functions,
but if you want to use the Intel Visual Fortran then according
to the error message you got, you need VS to -link- your MEX
functions. Linking is one of the essential steps of compiling.
Whether you need the VS product installed in order to run
the functions after linking is something I cannot predict;
it could go either way.
--
'Roberson' is my family name; my given name is 'Walter'.

Subject: Fortran MEX - Visul Studio Linker

From: Gadi Reinhorn

Date: 11 Feb, 2008 16:41:41

Message: 5 of 7

Charan,

Intel Visual Fortran Requires that you have some Microsoft development
product.
That is listed in the system requirements Intel Visual Fortran:
ftp://download.intel.com/support/performancetools/fortran/windows/v9/INSTALL.pdf


Software Requirements to Develop IA-32 Applications
. One of the following Microsoft development products must be installed:
- Microsoft Visual C++* .NET* 2002 or 2003, Standard edition or above
- Microsoft Visual Studio* .NET* 2002 or 2003, any edition, with Visual C++
component installed
- Microsoft Visual Studio 2005, Standard edition or above, with Visual C++
component installed (Note: Microsoft Visual Studio 2005 Express Edition is
supported for command line development only. Express Edition users are
advised to also install the Microsoft Platform SDK if Win32 APIs will be
used.)

etc.

A free option is to get the Microsoft Visual Studio 2005 Express Edition.

Good luck.

Gadi

"Charan " <boyacharan@gmail.com> wrote in message
news:fonhuq$1hg$1@fred.mathworks.com...
>
> No. So Do I have to buy Visual Studio 2005 for just running
> MEX Functions?
>
> I see only "Common" folder under Visual Studio so I guess I
> dont have Visual Studio on My comp. Is there any alternative
> from not buying this?
>
> THanks,
> Charan


Subject: Fortran MEX - Visul Studio Linker

From: Austin

Date: 13 Feb, 2008 16:31:02

Message: 6 of 7

"Charan " <boyacharan@gmail.com> wrote in message
<fonh1o$lqu$1@fred.mathworks.com>...
> Hi
>
> I wanted to MEX function to compile a fortran code. I
> bought Intel Fortran 9.1 (since the matlab site say that is
> compatible to Matlab2007b).
>
> When I load the compiler, I am getting this error. Please
> help. It is very urgent.
>
> Thanks,
> Charan
>
> ----error-----------
> Your machine has a Intel Visual Fortran compiler located at
> C:\Program Files\Intel\Compiler\Fortran\9.1. Do you want to
> use this compiler [y]/n? y
>
> Please verify your choices:
>
> Compiler: Intel Visual Fortran 9.1
> Location: C:\Program Files\Intel\Compiler\Fortran\9.1
>
> Are these correct?([y]/n): y
>
> Error: Microsoft Visual Studio 2005 was not found by mex
> -setup.
> The Microsoft Visual Studio 2005 linker is required
> to build Intel Fortran MEX-files. Please make sure
that
> Microsoft Visual Studio 2005 is installed properly.
>
> ??? Error using ==> mex at 208
> Unable to complete successfully.
> -------------------------------------------


I would highly recommend taking a look at "howto: mex + MS
Visual C/C++ Express Edition 2005" by William Fox at
 http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=13321

It is extremely detailed on what things you need in order to
build MEX functions using the free Visual Studio C/C++
Express software. More specifically, I suspect that the
information Mr. Fox provides in regards to obtaining
"missing components" from the Windows Platform SDK needed by
Matlab to work with the VS Express compiler(s) is directly
applicable(related) to the problem you are experiencing.

Be sure and leave a final post to let everyone know what/how
you end up fixing your problem.


NOTE: I found the information on which Windows Platform SDK
to use a little confusing because the official Microsoft
name for the "Windows Platform SDK" is "Windows Server 2003
R2 Platform SDK." You do NOT want "Windows Server 2003 SP1
Platform SDK." R2 good; SP1 bad(still works just minus a
few bug fixes).

Subject: Fortran MEX - Visul Studio Linker

From: Austin

Date: 13 Feb, 2008 16:33:07

Message: 7 of 7

"Charan " <boyacharan@gmail.com> wrote in message
<fonh1o$lqu$1@fred.mathworks.com>...
> Hi
>
> I wanted to MEX function to compile a fortran code. I
> bought Intel Fortran 9.1 (since the matlab site say that is
> compatible to Matlab2007b).
>
> When I load the compiler, I am getting this error. Please
> help. It is very urgent.
>
> Thanks,
> Charan
>
> ----error-----------
> Your machine has a Intel Visual Fortran compiler located at
> C:\Program Files\Intel\Compiler\Fortran\9.1. Do you want to
> use this compiler [y]/n? y
>
> Please verify your choices:
>
> Compiler: Intel Visual Fortran 9.1
> Location: C:\Program Files\Intel\Compiler\Fortran\9.1
>
> Are these correct?([y]/n): y
>
> Error: Microsoft Visual Studio 2005 was not found by mex
> -setup.
> The Microsoft Visual Studio 2005 linker is required
> to build Intel Fortran MEX-files. Please make sure
that
> Microsoft Visual Studio 2005 is installed properly.
>
> ??? Error using ==> mex at 208
> Unable to complete successfully.
> -------------------------------------------


I would highly recommend taking a look at "howto: mex + MS
Visual C/C++ Express Edition 2005" by William Fox at
 http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=13321

It is extremely detailed on what things you need in order to
build MEX functions using the free Visual Studio C/C++
Express software. More specifically, I suspect that the
information Mr. Fox provides in regards to obtaining
"missing components" from the Windows Platform SDK needed by
Matlab to work with the VS Express compiler(s) is directly
applicable(related) to the problem you are experiencing.

Be sure and leave a final post to let everyone know what/how
you end up fixing your problem.


NOTE: I found the information on which Windows Platform SDK
to use a little confusing because the official Microsoft
name for the "Windows Platform SDK" is "Windows Server 2003
R2 Platform SDK." You do NOT want "Windows Server 2003 SP1
Platform SDK." R2 good; SP1 bad(still works just minus a
few bug fixes).

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
mex Charan 10 Feb, 2008 13:54:55
visual studio Charan 10 Feb, 2008 13:54:55
fortran Charan 10 Feb, 2008 13:54:55
rssFeed for this Thread
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com