Sei sulla pagina 1di 4

Configuring the environment on a Windows machine to use the correct compiler when running both... http://abaqus.custhelp.com/cgi-bin/abaqus.cfg/php/enduser/prnt_adp.php?p_faqid=2668&p_created=...

Answer ID Configuring the environment on a Windows machine to use the correct compiler when running both ABAQUS
2668 Versions 6.5 and 6.6
Last Updated Question
04/07/2006 09:40 PM
Access Level I am using ABAQUS Versions 6.5 and 6.6 on the same Windows machine. Is there a way to configure the environment so that it automatically uses
Customers w support the correct compiler for the respective ABAQUS version?
Answer

(The following applies to ABAQUS Versions 6.5 and 6.6)

The supported compilers are different for ABAQUS Versions 6.5 and 6.6. This Answer outlines methods to configure separate compiler environments
for each 32-bit based ABAQUS version so that both compiler environments can co-exist, albeit separately.

In order for a compiler to function properly, it needs access to libraries and other required files. Proper configuration of the compiler's environment
ensures that the necessary files are accessible. Compiler manufacturers typically provide the option to configure the compiler's environment
'permanently' during installation of the compiler or 'temporarily' in a command window. .

A 'permanent' configuration involves updating the system environment parameters PATH, INCLUDE, and LIB such that the compiler environment will
be enabled for any new command window that is opened.

A 'temporary' configuration can be achieved in two ways. The first involves the use of initialization batch files. For example, Microsoft uses an
initialization batch file named vcvars32.bat to set the C++ compiler environment. Execution the vcvars32.bat batch file in a command window
creates a temporary environment that is active for that window only. The second involves manually setting the compiler's environment on the
command line using the Windows set command.

The dual configuration types can be used together so that, depending on the version of ABAQUS being launched, the correct compiler is used.
Particularly, Version 6.5 of ABAQUS will use a 'permanent' compiler configuration, while Version 6.6 will use a 'temporary' configuration.

To allow both versions of ABAQUS to use the correct compiler, complete the following steps:

1. Confirm that your compiler environment is configured to support ABAQUS Version 6.5.
If you have already installed ABAQUS Version 6.5 and can run ABAQUS with user subroutines, your compiler environment is already configured
using the 'permanent' option discussed above. If not, please see:

Proper setting of environment variables to compile and link user-subroutines on Windows


Correctly setting environment variables to allow ABAQUS to detect compilers
If you are using the Intel Fortran compiler with ABAQUS 6.5, please see the links at the bottom of this answer.

2. To configure the environment for ABAQUS Version 6.6, ABAQUS can utilize the initialization batch file ifortvars.bat created by Intel for the
Intel Fortran Compiler. This batch file will configure the environment for both the Intel Fortran Compiler and the Microsoft C++ compiler. To
locate the batch file, navigate to the root directory of the drive where the compiler is installed and issue the dir command, as in the following
example for the 32-bit version of Intel's Fortran Compiler:
c:\> dir /S ifortvars.bat

A typical location for the file will be the C:\Program Files\Intel\Fortran\compiler80\IA32\BIN\ directory.

1 of 4 08/11/2006 11:30 AM
Configuring the environment on a Windows machine to use the correct compiler when running both... http://abaqus.custhelp.com/cgi-bin/abaqus.cfg/php/enduser/prnt_adp.php?p_faqid=2668&p_created=...

There are three ways to execute the initialization batch file to set the compiler environment in advance of running your ABAQUS job.

Modifying the ABAQUS Command shortcut from the Start Menu

With this approach, the initialization batch file will be automatically executed each time ABAQUS is launched from the shortcut. Add the
ifortvars.bat initialization batch file path to the ABAQUS 6.6 ABAQUS Command shortcut by doing the following:

Navigate to the ABAQUS Command prompt shortcut on the Start menu, right click on the shortcut and choose Properties.

Append the full path to the ifortvars.bat file, adding quotes if necessary, to the Target field on the Shortcut tab. There must be a
space between the "/k" option and the batch file's path as in the following example:

C:\WINNT\system32\CMD.EXE /k "C:\Program
Files\Intel\Fortran\compiler80\IA32\BIN\ifortvars.bat"

Using the compiler in the above example, the following message will appear each time the ABAQUS Command prompt shortcut is

2 of 4 08/11/2006 11:30 AM
Configuring the environment on a Windows machine to use the correct compiler when running both... http://abaqus.custhelp.com/cgi-bin/abaqus.cfg/php/enduser/prnt_adp.php?p_faqid=2668&p_created=...

executed:

"Intel(R) Visual Fortran Compiler 8.1 Build Environment for 32-bit applications Copyright
(C) 1985-2005 Intel Corporation. All rights reserved.

Setting environment for using Microsoft Visual Studio .NET 2003 tools.
(If you have another version of Visual Studio or Visual C++ installed and wish to use its tools from the command line, run
vcvars32.bat for that version.)"

This is the recommended method if you do not want to manually execute the batch file each time you execute ABAQUS from the
ABAQUS Command prompt. However, you would need to perform the above for each ABAQUS Command shortcut in subsequent
maintenance releases.

From the Windows Start Menu

To set the environment from the Start menu, choose the "Build Environment" shortcut as in the following example for Intel Fortran
Compiler version 8.1:

Start ® Programs ® Intel(R) Software Development Tools ® Intel Fortran Compiler 8.1 ® Build Environment for
Fortran IA-32 applications

After completing the above command sequence, a command window with the correct compiler environment will open.

From the Command Prompt

Open a Windows command prompt and run the ifortvars.bat for your version before running ABAQUS, as in the following example:

D:\temp> "C:\Program Files\Intel\Fortran\compiler80\IA32\BIN\ifortvars.bat"

Other notes:
Ensure that the correct environment has been setup by executing abaqus info=support in the command prompt window before
running your job.
As noted in the above example's output, if you wish to change the associated Microsoft C++ compiler, run the initialization batch file for
your desired version.
The Intel Fortran Compiler initialization batch file will fail if the compilers are not installed properly.

For more information:

3 of 4 08/11/2006 11:30 AM
Configuring the environment on a Windows machine to use the correct compiler when running both... http://abaqus.custhelp.com/cgi-bin/abaqus.cfg/php/enduser/prnt_adp.php?p_faqid=2668&p_created=...

See the ABAQUS web pages for the supported compiler versions at ABAQUS Systems Information
Support for Intel Visual Fortran compilers on Windows
Compatibility of newer Intel Compiler Versions with ABAQUS
Using ABAQUS with Intel Fortran Compilers for Windows

4 of 4 08/11/2006 11:30 AM

Potrebbero piacerti anche