MKL BLAS95 and LAPACK95 interface build

MKL BLAS95 and LAPACK95 interface build

Hi,

I'm trying to run the following MKL interface make files in RHEL MRG (3.10.33-rt32.34.el6rt.x86_64) in order to interface to MKL using the BLAS and LAPACK interface (using the mkl_ prefixed header files):

/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95/makefile
and
/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/blas95/makefile

However, both build fail because I do not have the ifort compiler:
make libintel64 INSTALL_DIR=../../lib95
make PLAT=lnx32e build interface= MKLROOT=../.. INSTALL_DIR=../../lib95 FC=ifort
make[1]: Entering directory `/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95'
mkdir -p ../../lib95/lib/intel64/obj_lapack95_intel64_/obj77
ifort -auto -module ../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c -o ../../lib95/lib/intel64/obj_lapack95_intel64_/obj77/lapack_interfaces.obj source/lapack_interfaces.f90
make[1]: ifort: Command not found
make[1]: *** [../../lib95/lib/intel64/libmkl_lapack95_lp64.a] Error 127
make[1]: Leaving directory `/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95'
make: *** [libintel64] Error 2

which ifort
/usr/bin/which: no ifort in (/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/tester/bin)

I also don't have a bin directory in the /composer_xe_2013_sp1.1.106/mkl directory, which a few forums suggested would have an ifort installer.

I tried using gfortran in the make command (FC=gfortran), but the build fails towards the end for one of the files.

Could you provide ifort installation instructions, or an alternative method for making these interface files?

Thanks,

Jay

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

Quote:

Jason S. wrote:
I tried using gfortran in the make command (FC=gfortran), but the build fails towards the end for one of the files.

Please provide details of the failure. When using Gfortran, you may need to modify the Fortran compiler options that are provided for IFort. Are you able to build applications using Gfortran that use the MKL libraries on this system ?

A license for Intel Fortran is available at no cost for non-commercial use. See if you qualify.

Hi Jason, 

what is the error message when build with gfortran? 

I just try 

1) copy the folder to /home/me/.

2) make libintel64 FC=gfortran INSTALL_DIR=gf

The build seem run smoothly and product lapack95.a in gf directory. 

Best Regards,

Ying 

[yhu5@prc-mic01 intel64]$ gfortran --v
Using built-in specs.
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre --enable-libgcj-multifile --enable-java-maintainer-mode --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib --with-ppl --with-cloog --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux
Thread model: posix
gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)
[yhu5@prc-mic01 lapack95]$ make libintel64 FC=gfortran INSTALL_DIR=gf

gfortran  -fautomatic -Jgf/lib/intel64/obj_lapack95_intel64_/obj77 -c -fPIC -o gf/lib/intel64/obj_lapack95_intel64_/zupmtr.o source/zupmtr.f90
make[2]: Leaving directory `/home/yhu5/lapack95/lapack95'
cd gf/lib/intel64/obj_lapack95_intel64_ ; ar -rs libmkl_lapack95_lp64.a *.o
ar: creating libmkl_lapack95_lp64.a
mv gf/lib/intel64/obj_lapack95_intel64_/libmkl_lapack95_lp64.a gf/lib/intel64
mkdir -p gf/lib/intel64/obj_lapack95_intel64_/obj77
mkdir -p gf/include/intel64/lp64
gfortran  -fautomatic -Jgf/include/intel64/lp64 -c -fPIC -o gf/lib/intel64/obj_lapack95_intel64_/obj77/mkl_lapack.o /opt/intel/composer_xe_2013_sp1.2.144/mkl/include/lapack.f90
rm -rf gf/lib/intel64/obj_lapack95_intel64_
make[1]: Leaving directory `/home/yhu5/lapack95/lapack95'

[yhu5@prc-mic01 intel64]$ ls
libmkl_lapack95_lp64.a

 

Hi.

Sorry, I should have included the gfortran build error. Here it is (below). I get the same exit error when I try to make the BLAS95 interface too.

-Jay

*******************************************

# pwd

/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95

# make libintel64 FC=gfortran INSTALL_DIR=../../lib95

..... several lines of built files like those below

gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmhr.o source/zunmhr.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmlq.o source/zunmlq.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmql.o source/zunmql.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmqr.o source/zunmqr.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmrq.o source/zunmrq.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmrz.o source/zunmrz.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zunmtr.o source/zunmtr.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zupgtr.o source/zupgtr.f90
gfortran  -fautomatic -J../../lib95/lib/intel64/obj_lapack95_intel64_/obj77 -c  -o ../../lib95/lib/intel64/obj_lapack95_intel64_/zupmtr.o source/zupmtr.f90
make[2]: Leaving directory `/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95'
cd ../../lib95/lib/intel64/obj_lapack95_intel64_ ; ar -rs libmkl_lapack95_lp64.a *.o
ar: creating libmkl_lapack95_lp64.a
mv ../../lib95/lib/intel64/obj_lapack95_intel64_/libmkl_lapack95_lp64.a ../../lib95/lib/intel64
make[1]: *** No rule to make target `../../include/lapack.f90', needed by `../../lib95/include/intel64/lp64/mkl95_lapack.mod'.  Stop.
make[1]: Leaving directory `/opt/intel/composer_xe_2013_sp1.1.106/mkl/interfaces/lapack95'
make: *** [libintel64] Error 2

# gfortran -v
Using built-in specs.
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre --enable-libgcj-multifile --enable-java-maintainer-mode --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib --with-ppl --with-cloog --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux
Thread model: posix
gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC)

 

The files lapack.f90 and blas.f90 (from which you can build the module files in question) are provided in the .../mkl/include directory. You may need to copy these files to the appropriate sub-directory of the location where you are building libraries and modules with Gfortran.

Login to leave a comment.