Unable to run '<Microsoft VC++ Dir>\Bin'

Unable to run '\Bin'

Hello all,

I'm new to this forum and have just installed the trial-version of Intel's Visual Fortran Compiler for Windows. (I'm running Win-XP Prof.)

However, after my first compilation, from DOS mode (command: ifort test.f90), I got the strange message

ifort: Unable to run '\Bin'

So, the compilation itself seems to be ok, and a file test.obj is created, but no sign of a file test.exe (as I was hoping...)

Since the error message itself doen't tell me much, I am asking here what I am doing wrong.
I anyone can tell me what to do, I would be much obliged!

Regards, Lucas

33 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

You need to have first installed the prerequisite Microsoft development product - one of:

  • Visual Studio 2005 Standard Edition or higher
  • Visual Studio.NET 2002 or 2003
  • Visual C++.NET 2002 or 2003, Standard Edition

If you are going to be using command line only, then you can also use the free Microsoft Visual C++ 2005 Express Edition.

Whichever you choose must be installed before installing Intel Fortran. Please read the Installation Guide (INSTALL.htm) for further details.

So after installing the MS product, uninstall and reinstall Intel Visual Fortran.

Steve

Indeed Steve, I plan (at least for now) to only use the command line, so I downloaded the free Microsoft C++ 2005 Express Eition (vsetup.exe).

But now I ran into a different problem when trying to install this thing.
The installation only gets as far as "Setup is loading installation components. This may take a minute or two". It displays about 80% of the blue bars, then stops and hangs!
I cannot even cancel the process in TaskManager, so I had to reboot.

I hope this new problem also sounds familiar!
Many thanks.

I'm not clear on whether you heeded Steve's advice (uninstall, e.g. using the Add/Remove menu, or the uninstall option in the unpacked ifort installer files) before first installing VS express, then Intel Fortran. If you did do that, and you still don't get correct installed ifortvars.bat and ifort.cfg files, you can edit them manually, after telling the ifort installation to continue even when it doesn't ask you to show it the VS installation. Those files must be consistent with vcvarsxx.bat, for example. (32-bit ifortvars.bat and ifort.cfg consistent with vcvars32.bat, and 64-bit consistent with the Microsoft 64-bit release compile environment window). Automatic installation, at best, will work only when following the 'yellow brick road."

Well guys, I still have problems, but I think I am 2 steps further.

First, the problem of installing "Visual C++ 2005 Express Edition" has been solved by using the so-called "manual procedure".
More info about this : http://msdn.microsoft.com/vstudio/express/support/install/

Then I un-installed and re-installed Fortran again, and recompiled test.f90.
This time I got the error message (during execution of link.exe):

"This application has failed to start because mspdb80.dll was not found. Re-installing the application may fix this problem".

Since the mspdb80 file WAS indeed present on my system in the folder C:Program FilesMicrosoft Visual Studio 8Common7IDE, I copied this file to the directory of link.exe, namely C:Program FilesMicrosoft Visual Studio 8VCin.
Not the most elegant solution, I admit, but it apparently worked.

Anyway the following compilation try resulted in yet another error message:

"LINK : fatal error LNK1104: cannot open file LIBCMT.lib".

Yet, also this file is present on my system, in folder C:Program FilesMicrosoft Visual Studio 8VClib.
This time the trick of copying this file to the bin-folder doesn't work however...

Any more suggestions?
What am I doing wrong?
Do I have to modify some configuration settings or files?

Regards, Lucas.

Lucas, is the problem you're having with the VC installer or the Intel Fortran installer? It isn't an issue I am familiar with.

I suggest that you check for adequate disk space and clean out your Temp folder (whatever the environment variable TEMP points to) and try again.

Steve

Hello Steve,

The problems have finally been solved!
The last error message I got (
"LINK : fatal error LNK1104: cannot open file LIBCMT.lib".) could be resolved by modifying the LIB environment parameter in Windows.
Why this wasn't done automatically at Fortran and VC++ installation time still puzzles me but hey, who is complaining here? The thing works!

The only frustrating issue at this time is that my execution times in Intel's Fortran are about the same as those when running Salford's FTN-95.
To be honest I had expected a gain of about 25 to 50%, as was mentioned by some benchmarking websites.
Is this "normal"? By the way I used the /O3 compiler option to speed up things as much as possible, but without success so far.

Meanwhile, thanks for the support!
Lucas.

The most likely ways for ifort to improve performance over Salford
would be with vectorization (-QxW et al.) or parallelization
(-Qparallel or OpenMP), if those are applicable to your example.
-O3 is most likely to show speedup when used together with
vectorization for nested loops. Are we to assume your example is
or is not of that character?

You had said earlier that you used a "manual install" method. If Visual C++ was properly installed, then the Fortran install should have found it. But please also note that if you are using Visual C++ Express Edition, you do not have access to Fortran debugging in the MS debugger - you should use the Intel Debugger instead.

Look at C:Program FilesIntelCompilerFortran9.1IA32Binifortvars.bat and look to see if there is a line that looks like this:

@call "C:Program FilesMicrosoft Visual Studio 8VCBinVcvars32.bat"

This is what sets up the environment variables. Be sure that you are using the "Build Environment for IA-32 Applications" shortcut to start your build session.

What kind of processor does your system have? What is your ifort command line? I would normally expect a lot better code than Salford, but if your application is not CPU-bound (if it is dominated by I/O or memory access, for example), the results might be closer. Try one of the /Qx switches such as /QxP if you have a current Pentium 4/Pentium D.

Steve

Until fairly recently I was using the Visual C++ Express Edition, so I'm very familiar with this problem. :-) The Intel Fortran installer does not recognize the Express Editions, so it does not insert the correct paths in ifortvars.bat or ifort.cfg, so you have to edit them to replace with the correct path in both files.

To add to the fun, both these files are overwritten by every update, so it is probably a good idea to save copies in another directory.

The Intel Fortran installer does recognize the VC++ 2005 Express Edition in versions as of 9.0.028 and later.

Steve

That's nice to know. I assume VC++ 2003 Express Edition was not supported by earlier versions, or did I sleep through that as well? :-)

There was no "Express Edition" prior to VC2005. There was a Standard Edition of VC++ 2002 and 2003, and that was supported to provide full functionality. There was also a "Visual C++.NET 2003 Toolkit" which had command-line tools only. It was not supported, but could be made to work from the command line.

If you use VC 2005 Express Edition, you also need the free Microsoft Platform SDK installed as detailed in the Installation Guide.

Steve

Hi Steve,

After the installation problems, it took a while to build a kind of reliable benchmarking program to compare Salford's and Intel's execution times.

My processor is a 3-year old Pentium-4 2.8 Ghz (mounted on an Asus P4C800 motherboard).
And yes, the testprogram is VERY cpu-bounded.

In the test cases Salford's times are on average 82 seconds, while Intel's times are just above 90 seconds (compiled without options, so he command line looked like "ifort TEST.f90").

When adding the option /QxN (and later also /O3) the execution times are about 10% better (a drop to 82 seconds), but even then Intel cannot beat Salford.
I am very puzzeled why (not)...

And another thing: Salford compiles my source code to an 94 KB executable, Intel on the other hand builds a 502 KB executable. I had hoped that the extra 400% (!) of code would contain some optimizations, but so far I haven't seem them.

What command line are you using?

The 502KB includes code from the static run-time library. Your actual object code is much smaller.

I'd appreciate it if you would send the test program and the compile line used, along with your notes on performance, to Intel Premier Support so that we can investigate.

Steve

Hi, I have the same exact problem as described in this thread. Moreover, IVF doesn't recognize C++ 2005 Express Edition. Then when you try to run it can't find the linker. If you point it to the linker, it then can't find the libraries, etc. I have one other problem though, I'm running Windows x64. Some of the things it can't find, don't seem to be there. Only in the Platform SDK folder. What I need to know is when you are running Windows x64 can you target 32-bit processors without purchasing the full blown C++. It seems like the answer is no, but I want to make sure. I have been trying for months to get answers through Intel Premier Support, but they have been of no use whatsoever.

Anthony,

What version of IVF are you using? Recognition of VC2005 Express started with 9.0.028. Please tell me the Premier Support issue numbers and I'll investigate - the problem described in this thread is one we have lots of experience helping users with so I'd like to understand what went wrong.

The Platform SDK does not provide what is needed to build IA-32 applications. You need one of the Visual C++/Visual Studio products for that. I have not tried installing VC2005 Express on x64 so I don't know if it fails to install or not. But if it does install, then IVF should work with it for building IA-32 applications. You can, of course, build x64 applications using the PSDK.

Steve

Hi,

Thank you very much. I am so fusturated. I needed to swith to Windows x64 due to the memory needs of my FEA work. Unfortunately, I can't compile 32-bit executables anymore. Only 64-bit, which no one else in my company can use.

I support issue number is 386398. I think the problem is with the linker that comes with C++ Express edition. But I don't know for sure. Some of the files the linker looks for are not there. However, they are there for the 64-bit version.

I get the feeling that when you are using x64 IVF can not compile 32-bit executables unless you buy C++. The free version may not have all the right stuff. But I don't know Microsoft's products enough to know that. In fact I don't know them at all.

My biggest frustration at this point is that IVF says it can compile Itanium, EMT64, and x86 code, but because it relies on Microsoft's linker, it really can't do any of that on its own. My hope is that you guys can figure out something so that we can just install IVF and that's it. I only want to compile using the command prompt. I don't know C++ and don't want to know it. I know a lot of users probably like and need the integration. But maybe you guys can sell a seperate version that only runs from the command prompt and doesn't require anyone to install anything else.

Anyways, I have tried everything that I possibly can. I have tried all the install options and change pointers and what not, but I can't get it to work.

Anthony

Sorry, I forgot to say that I have tried version 025, 028, and 029. Version 028 would not allow me to license it for some reasaon. But I can install and run 025 and 029. However, I can only compile EMT64 executables, whereas, I need to compile x86 executables, so others in my company can use them.

Does Visual C++ 2005 Express Edition install for you? Once installed, reinstall the Intel Fortran compiler (the IA-32 version). Do a Start>Programs>Intel Software Development Tools>Intel Fortran Compiler 9.1>Build Environment for IA-32 Applications. Post the output.

Steve

Hi Steve,

I can install everything. I have uninstalled and reinstalled everything several times. This time I registered C++ Express Edition, whereas before I did not. I think this had a lot to do with IVF not being able to properly detect the installation. If you chose only to install the command line of C++ Express Edition, you don't have to register it. That was my preferred method, but like I said, it seemed to cause IVF problems if you do it that way.

Anyways, I just finished reinstalling everything again and have attached the image you asked for. The error is different now that I have registered C++. Previously, I got all the same errors that were posted in this thread.

Attachments: 

AttachmentSize
Download New_Picture__1_.png27.95 KB

Interesting. Please post the contents of C:Program FilesIntelCompilerFortran9.1ia32inifortvars.bat

Steve

This thread has become so long I'm not sure I know the differences between the problems referred to by various posters. When I started with VS Express, I had to find the separate Microsoft instruction page which tells you where to download 32-bit and amd64 SDKs separately, to enable both 32- and 64-bit operation with CL. Of course, you first select C++ support when installing VS. All these are needed before the corresponding Intel compilers could install correctly. I still had to finish up the paths in ifort.cfg myself.

Hi,

Thanks for the tip. I'm not sure what to say about the installation of C++ 2005 Express Edition and the Windows Server 2003 Platform SDK SP1 though. As far as I know those install and work fine. Their command prompts for 32-bit and 64-bit both are present and open without any errors showing up. The C++ Command Prompt window also opens without any errors showing up. Only the IVF Command Prompt window for 32-bit operation has the issue. Again, I'm using Windows x64. I didn't have this problem on standard windows. I'll try to read up more on how to intall C++ and the SDK just to make sure I'm doing it right. I have installed them both so many times I've lost count. I've been trying to get IVF running on this machine, since I got it, to no avail. Only the EMT64 works. Never the 32-bit. I've tried three different version of IVF. The 025, 028, and 029 release.

Hi,

Sure, here is the bat file:

@echo off
Rem Intel Visual Fortran Compiler Build Environment for 32-bit applications

echo.
echo Intel Visual Fortran Compiler 9.1.029 Build Environment for 32-bit applications
echo Copyright (C) 1985-2006 Intel Corporation. All rights reserved.
echo.

@call "C:Program Files (x86)Microsoft Visual Studio 8VCBinVcvars32.bat"
@call "C:Program FilesMicrosoft Platform SDKSetEnv"
title Intel Visual Fortran Compiler 9.1.029 Build Environment for 32-bit applications

echo.

SET IFORT_COMPILER91=C:Program Files (x86)IntelCompilerFortran9.1

SET INTEL_SHARED=C:Program Files (x86)Common FilesIntelShared Files

SET INTEL_LICENSE_FILE=C:Program Files (x86)Common FilesIntelLicenses

SET PATH=%IFORT_COMPILER91%Ia32Bin;%INTEL_SHARED%Ia32Bin;%PATH%

SET LIB=%IFORT_COMPILER91%Ia32Lib;%LIB%

SET INCLUDE=%IFORT_COMPILER91%Ia32Include;%INCLUDE%

if exist "C:Program Files (x86)IntelCompilerFortran9.1ia32Binimsl.bat" call "C:Program Files (x86)IntelCompilerFortran9.1ia32Binimsl.bat"

Here is the cfg file:

# This Configuration file may be used for additional switches

# Enable Microsoft Visual C++* .NET 8.0 compatibility
-Qvc8

# Path to Microsoft Visual C++* .NET 8.0 linker
-Qlocation,link,"C:Program Files (x86)Microsoft Visual Studio 8VCBin"

# *Other names and brands may be claimed as the property of others

During previous installation attempts I had to manually change a lot of the items in both files, to get it to find everything. But that is were I got all the same error messages that were stated in this thread. However, that was when I chose only to install the C++ Express Edition Command Prompt only. If you also install and register the GUI, IVF can then find everything ok. But then you get the error show in the image you had me post in a previous e-mail.

Edit the ifortvars.bat file and change the first line to read:

@echo on

Save it. Now try opening a build window again and post the output.

Verify that the files named in the following two lines exist:

@call "C:Program Files (x86)Microsoft Visual Studio 8VCBinVcvars32.bat"
@call "C:Program FilesMicrosoft Platform SDKSetEnv"

Steve

Hi,

I turned echo on and attached the results as you asked. Also, I verified that the files are their. Vcvars32.bat was there but not capatilized. I changed that after I took the screenshot, but it made no difference. Same error as before.

Attachments: 

AttachmentSize
Download New_Picture.png36.11 KB

Ok, the problem is inside the MS file. Open a command prompt window and type:

@echo on
"C:Program Files (x86)Microsoft Visual Studio 8VCBinVcvars32.bat"

post the output.

Steve

Hi Steve,

I turned echo on in the file, but it didn't add any information to the screen. I attached the picture anyway. I manually added a line so that I knew when the file was being called. The thing is, when you open the C++ command prompt window it opens without any errors. Only the IVF window has the problem. So it doesn't make sense that it is any of the C++ or SDK batch files. In any event I copied the bat file for C++ below:

@echo on
@echo start of vsvars32.bat

@SET VSINSTALLDIR=C:Program Files (x86)Microsoft Visual Studio 8
@SET VCINSTALLDIR=C:Program Files (x86)Microsoft Visual Studio 8VC
@SET FrameworkDir=C:WINDOWSMicrosoft.NETFramework
@SET FrameworkVersion=v2.0.50727
@SET FrameworkSDKDir=C:Program Files (x86)Microsoft Visual Studio 8SDKv2.0
@if "%VSINSTALLDIR%"=="" goto error_no_VSINSTALLDIR
@if "%VCINSTALLDIR%"=="" goto error_no_VCINSTALLDIR

@echo Setting environment for using Microsoft Visual Studio 2005 x86 tools.

@rem
@rem Root of Visual Studio IDE installed files.
@rem
@set DevEnvDir=C:Program Files (x86)Microsoft Visual Studio 8Common7IDE

@set PATH=C:Program Files (x86)Microsoft Visual Studio 8Common7IDE;C:Program Files (x86)Microsoft Visual Studio 8VCBIN;C:Program Files (x86)Microsoft Visual Studio 8Common7Tools;C:Program Files (x86)Microsoft Visual Studio 8SDKv2.0in;C:WINDOWSMicrosoft.NETFrameworkv2.0.50727;C:Program Files (x86)Microsoft Visual Studio 8VCVCPackages;%PATH%
@set INCLUDE=C:Program Files (x86)Microsoft Visual Studio 8VCINCLUDE;%INCLUDE%
@set LIB=C:Program Files (x86)Microsoft Visual Studio 8VCLIB;C:Program Files (x86)Microsoft Visual Studio 8SDKv2.0lib;%LIB%
@set LIBPATH=C:WINDOWSMicrosoft.NETFrameworkv2.0.50727

@goto end

:error_no_VSINSTALLDIR
@echo ERROR: VSINSTALLDIR variable is not set.
@goto end

:error_no_VCINSTALLDIR
@echo ERROR: VCINSTALLDIR variable is not set.
@goto end

:end

Attachments: 

AttachmentSize
Download New_Picture.png36.11 KB

Hi Again,

Here is more information that I discovered. I was checking all the paths and they seemed ok. So then I turned echo on in the next file that IVF was calling. That was the bat file for the Platform SDK. Then what you were probably looking for showed up. I attached a picture. I don't know what it means though. Also, the thing I don't understand is all of the command prompt windows for the SDK and the one for C++ all open without a problem. So I don't know why the Platform SDK batch file is having an issue when called from the IVF command prompt window.

Attachments: 

AttachmentSize
Download New_Picture.png36.11 KB

Hi Steve,

I think I fixed it. I changed the vsvars32.bat file as follows:

@SET VSINSTALLDIR=C:Program Files (x86)Microsoft Visual Studio 8
@SET VCINSTALLDIR=C:Program Files (x86)Microsoft Visual Studio 8VC
@SET FrameworkDir=C:WINDOWSMicrosoft.NETFramework
@SET FrameworkVersion=v2.0.50727
@SET FrameworkSDKDir=C:Program Files (x86)Microsoft Visual Studio 8SDKv2.0
@if "%VSINSTALLDIR%"=="" goto error_no_VSINSTALLDIR
@if "%VCINSTALLDIR%"=="" goto error_no_VCINSTALLDIR

@echo Setting environment for using Microsoft Visual Studio 2005 x86 tools.

@rem
@rem Root of Visual Studio IDE installed files.
@rem
@set DevEnvDir=C:Program Files (x86)Microsoft Visual Studio 8Common7IDE

@set PATH=C:Program Files (x86)Microsoft Visual Studio 8Common7IDE;C:Program Files (x86)Microsoft

Visual Studio 8VCin;C:Program Files (x86)Microsoft Visual Studio 8Common7Tools;C:Program Files

(x86)Microsoft Visual Studio 8SDKv2.0Bin;C:WINDOWSMicrosoft.NETFrameworkv2.0.50727;C:Program Files

(x86)Microsoft Visual Studio 8VCvcpackages;%PATH%
@set INCLUDE=C:Program Files (x86)Microsoft Visual Studio 8VCinclude;%INCLUDE%
@set LIB=C:Program Files (x86)Microsoft Visual Studio 8VClib;C:Program Files (x86)Microsoft Visual

Studio 8SDKv2.0Lib;%LIB%
@set LIBPATH=C:WINDOWSMicrosoft.NETFrameworkv2.0.50727

@set MsVcDir=DevEnvDir

@goto end

:error_no_VSINSTALLDIR
@echo ERROR: VSINSTALLDIR variable is not set.
@goto end

:error_no_VCINSTALLDIR
@echo ERROR: VCINSTALLDIR variable is not set.
@goto end

:end

Moreover, I added the following line to the existing file:

@set MsVcDir=DevEnvDir

It seems to work now. I'm going to see if someone using a 32bit can run the executable, if so, its finally fixed.

Thanks for your help,

Anthony

Ok, but I am going to look at this in more detail - it should have worked.

Steve

Hi,

I did fix the problem. A few co-workers checked to make sure the executable ran on their 32-bit computers. So you can download the free Microsoft C++ Express Edition andthe Windows Platform SDK and use IVF to target 32-bit computers, when running from Windows x64 edition. You just have to modify one of the batch files.

Anthony

Login to leave a comment.