Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.

help with include path

rooster55555
Beginner
1,470 Views
I'm attempting to compile a program that calls a subroutine from a group of lapack95 programs in the math kernel library. I get an error message that says 'Error in opening the compiled module file. Check INCLUDE paths.' I have seen some other questions related to this problem, but I guess I need someone to hold my hand and make the solution simple for my little brain.
0 Kudos
6 Replies
barragan_villanueva_
Valued Contributor I
1,470 Views
Quoting - rooster55555
I'm attempting to compile a program that calls a subroutine from a group of lapack95 programs in the math kernel library. I get an error message that says 'Error in opening the compiled module file. Check INCLUDE paths.' I have seen some other questions related to this problem, but I guess I need someone to hold my hand and make the solution simple for my little brain.

Hi,

Based on your description, your problem is unclear. Could you please send more details andshowyour small test-case to reproduce the problem?

Thanks in advance

-- Victor
0 Kudos
rooster55555
Beginner
1,470 Views

Hi,

Based on your description, your problem is unclear. Could you please send more details andshowyour small test-case to reproduce the problem?

Thanks in advance

-- Victor
Hi Victor,

I am running Intel Fortran Compiler version 11.1 on 64 bit Windows Vista, and am attempting to run a program that is supposed to test whether I have the LAPACK routines in the Intel MKL linked correctly. The program is:


use lapack95
use mkl95_precision

DOUBLE PRECISION A(5,5),w(5)

a=0
a(1,1)=2; a(1,2)=1; a(2,1)=1;a(2,2)=2
call syev(a, w ,'V')
write(*,*) a, w
pause
end

when I attempt to compile this with the ifort command, I get the following error message:

error #7002: Error in opening the compiled module file. Check INCLUDE paths.

I suspect I don't have something properly defined or included in an environment variable, but I am very inexperienced with these sorts of things.

Any assistance would be greatly appreciated.
0 Kudos
Ying_H_Intel
Employee
1,470 Views

Hello rooster,

Starting version 10.2, Intel Math Kernel Library contains the precompiled Fortran 95 interface libraries for BLAS and LAPACK for Intel Fortran compiler as well as the corresponding precompiled interface modules for BLAS95 and LAPACK95.

Could you please first
1) check if your have the mkl95_lapack.modmkl95_precision.mod in your MKL install forlder?

For example, in my machine, they are in C:Program FilesIntelMKL10.2.2.025includeia32.( em64t if 64bit application)

2) Then add the path C:Program FilesIntelMKL10.2.2.025includeia32 to your project
for example,
click > Properties > Configuration Properties > Fortran> General >Additional Include Directories , add C:Program FilesIntelMKL10.2.2.025includeia32 in box.
3) Then rebuild your project

There is ready visual Fortran project sample athttp://software.intel.com/en-us/articles/blas-and-lapack-fortran95-mod-files/ and a similiar discussion at http://software.intel.com/en-us/forums/showthread.php?t=67711
for your reference

Hope it helps
Ying

0 Kudos
rooster55555
Beginner
1,470 Views
Quoting - Ying H (Intel)

Hello rooster,

Starting version 10.2, Intel Math Kernel Library contains the precompiled Fortran 95 interface libraries for BLAS and LAPACK for Intel Fortran compiler as well as the corresponding precompiled interface modules for BLAS95 and LAPACK95.

Could you please first
1) check if your have the mkl95_lapack.modmkl95_precision.mod in your MKL install forlder?

For example, in my machine, they are in C:Program FilesIntelMKL10.2.2.025includeia32.( em64t if 64bit application)

2) Then add the path C:Program FilesIntelMKL10.2.2.025includeia32 to your project
for example,
click > Properties > Configuration Properties > Fortran> General >Additional Include Directories , add C:Program FilesIntelMKL10.2.2.025includeia32 in box.
3) Then rebuild your project

There is ready visual Fortran project sample athttp://software.intel.com/en-us/articles/blas-and-lapack-fortran95-mod-files/ and a similiar discussion at http://software.intel.com/en-us/forums/showthread.php?t=67711
for your reference

Hope it helps
Ying

Hello Ying,

Below you can see what I entered into the FORTRAN command line, and the resulting error message. Any suggestions?

C:FORTRANprogram test>ifort Test_mkl.f90 mkl_lapack95.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib /I"C:Program FilesIntelMKL10.2.2.025include" /I"C:Program FilesIntelMKL10.2.2.025includeem64tlp64" /L"C:Program FilesIntelMKL10.2.2.025em64tlib"
Intel Visual Fortran Intel 64 Compiler Professional for applications running on Intel(64), Version 11.0 Build 20081105 Package ID: w_cprof_p_11.0.066
Copyright (C) 1985-2008 Intel Corporation. All rights reserved.
ifort: command line warning #10006: ignoring unknown option '/LC:Program FilesIntelMKL10.2.2.025em64tlib"'

C:FORTRANprogram testTest_mkl.f90(10): (col. 1) remark: LOOP WAS VECTORIZED Microsoft Incremental Linker Version 8.00.50727.42 Copyright (C) Microsoft Corporation. All rights reserved.

-out:Test_mkl.exe
-subsystem:console
Test_mkl.obj
mkl_lapack95.lib
mkl_intel_c.lib
mkl_intel_thread.lib
mkl_core.lib
libiomp5md.lib
LINK : fatal error LNK1181: cannot open input file 'mkl_lapack95.lib'

0 Kudos
Evgueni_P_Intel
Employee
1,470 Views
Quoting - rooster55555
Hello Ying,

Below you can see what I entered into the FORTRAN command line, and the resulting error message. Any suggestions?

C:FORTRANprogram test>ifort Test_mkl.f90 mkl_lapack95.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib /I"C:Program FilesIntelMKL10.2.2.025include" /I"C:Program FilesIntelMKL10.2.2.025includeem64tlp64" /L"C:Program FilesIntelMKL10.2.2.025em64tlib"
Intel Visual Fortran Intel 64 Compiler Professional for applications running on Intel(64), Version 11.0 Build 20081105 Package ID: w_cprof_p_11.0.066
Copyright (C) 1985-2008 Intel Corporation. All rights reserved.
ifort: command line warning #10006: ignoring unknown option '/LC:Program FilesIntelMKL10.2.2.025em64tlib"'

C:FORTRANprogram testTest_mkl.f90(10): (col. 1) remark: LOOP WAS VECTORIZED Microsoft Incremental Linker Version 8.00.50727.42 Copyright (C) Microsoft Corporation. All rights reserved.

-out:Test_mkl.exe
-subsystem:console
Test_mkl.obj
mkl_lapack95.lib
mkl_intel_c.lib
mkl_intel_thread.lib
mkl_core.lib
libiomp5md.lib
LINK : fatal error LNK1181: cannot open input file 'mkl_lapack95.lib'


1. The interface library mkl_intel_lp64.lib shouldn't be omitted
2. Under Windows the library path is passed to the linker as follows: /link /libpath:m:ylibpath
3. The correct name of the Lapack libibrary is mkl_lapack95_lp64.lib

Your correct build line would be
ifort Test_mkl.f90 mkl_intel_lp64.lib mkl_lapack95_lp64.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib /I C:Program FilesIntelMKL10.2.2.025include /I C:Program FilesIntelMKL10.2.2.025includeem64tlp64 /link /libpath:C:Program FilesIntelMKL10.2.2.025em64tlib

Evgueni.
0 Kudos
Gennady_F_Intel
Moderator
1,470 Views

as an additionally to the Evgeny's post - for more info, please refer to the mkl's userguide doc,Chapter 5 Linking with Fortran 95 Interface Libraries.
--Gennady


0 Kudos
Reply